From 4a23d949a315375159daa033bff439e1aaebf661 Mon Sep 17 00:00:00 2001 From: Jonathan Wilkes <jon.w.wilkes@gmail.com> Date: Wed, 15 Jun 2016 20:46:12 -0400 Subject: [PATCH] port b64e49c8af118dc953e56967b83cd5fe65f4ebd3 from Pd-l2ork: made cleaner and likely more universal implementation of the bendin fix --- pd/src/x_midi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pd/src/x_midi.c b/pd/src/x_midi.c index 3046c51e1..84c9e06bb 100644 --- a/pd/src/x_midi.c +++ b/pd/src/x_midi.c @@ -329,12 +329,12 @@ static void bendin_list(t_bendin *x, t_symbol *s, int argc, t_atom *argv) if (x->x_channel != 0) { if (channel != x->x_channel) return; - outlet_float(x->x_outlet1, value - 8192); + outlet_float(x->x_outlet1, value); } else { outlet_float(x->x_outlet2, channel); - outlet_float(x->x_outlet1, value - 8192); + outlet_float(x->x_outlet1, value); } } @@ -356,7 +356,7 @@ void inmidi_pitchbend(int portno, int channel, int value) if (pd_this->pd_bendin_sym->s_thing) { t_atom at[2]; - SETFLOAT(at, value); + SETFLOAT(at, value-8192); // Ico fix the offset of the incoming pitchbend SETFLOAT(at+1, (channel + (portno << 4) + 1)); pd_list(pd_this->pd_bendin_sym->s_thing, &s_list, 2, at); } -- GitLab