From a92c4fde3c1b91a81a70ded26675fa8ded7e3160 Mon Sep 17 00:00:00 2001 From: Jean Pierre Cimalando Date: Tue, 6 Apr 2021 00:18:25 +0200 Subject: [PATCH] Fix an error where controller is wrongly addressed --- plugins/lv2/sfizz.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/plugins/lv2/sfizz.cpp b/plugins/lv2/sfizz.cpp index 85f6917c..e5afaa05 100644 --- a/plugins/lv2/sfizz.cpp +++ b/plugins/lv2/sfizz.cpp @@ -847,10 +847,8 @@ run(LV2_Handle instance, uint32_t sample_count) sfizz_lv2_send_file_path(self, self->sfizz_sfz_file_uri, self->sfz_file_path); sfizz_lv2_send_file_path(self, self->sfizz_scala_file_uri, self->scala_file_path); - for (unsigned cc = 0; cc < sfz::config::numCCs; ++cc) { - LV2_URID urid = sfizz_lv2_ccmap_map(self->ccmap, int(cc)); - sfizz_lv2_send_controller(self, urid, self->cc_current[cc]); - } + for (unsigned cc = 0; cc < sfz::config::numCCs; ++cc) + sfizz_lv2_send_controller(self, cc, self->cc_current[cc]); } else if (property->body == self->sfizz_sfz_file_uri) { @@ -864,7 +862,7 @@ run(LV2_Handle instance, uint32_t sample_count) { int cc = sfizz_lv2_ccmap_unmap(self->ccmap, property->body); if (cc != -1) - sfizz_lv2_send_controller(self, property->body, self->cc_current[cc]); + sfizz_lv2_send_controller(self, unsigned(cc), self->cc_current[cc]); } } else if (obj->body.otype == self->time_position_uri)