From 001234daeb43b4c54b49ffca527cc92cd4d9b718 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sat, 25 Jul 2020 11:06:47 +0200 Subject: Revert "Use LV2_ATOM_BODY macros in examples instead of pointer arithmetic" This reverts commit 3aad5eb1b08ed5c27e60aa36021c4a85ce90c08f, which broke the example plugins. --- plugins/eg-sampler.lv2/sampler.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plugins/eg-sampler.lv2') diff --git a/plugins/eg-sampler.lv2/sampler.c b/plugins/eg-sampler.lv2/sampler.c index 646da2d..17f62a8 100644 --- a/plugins/eg-sampler.lv2/sampler.c +++ b/plugins/eg-sampler.lv2/sampler.c @@ -322,7 +322,7 @@ handle_event(Sampler* self, LV2_Atom_Event* ev) PeaksURIs* peaks_uris = &self->psend.uris; if (ev->body.type == uris->midi_Event) { - const uint8_t* const msg = (const uint8_t*)LV2_ATOM_BODY_CONST(ev); + const uint8_t* const msg = (const uint8_t*)(ev + 1); switch (lv2_midi_message_type(msg)) { case LV2_MIDI_MSG_NOTE_ON: self->frame = 0; -- cgit v1.2.1