From 3095cbc4f96fc7bf4fe4f4e1ee966738face9206 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Mon, 23 Nov 2015 12:25:59 -0500 Subject: [PATCH] more corrections for libmidi++ (N)RPN API --- libs/midi++2/channel.cc | 8 ++++---- libs/midi++2/midi++/parser.h | 10 ++++------ 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/libs/midi++2/channel.cc b/libs/midi++2/channel.cc index ffe65c6df9..f29673722d 100644 --- a/libs/midi++2/channel.cc +++ b/libs/midi++2/channel.cc @@ -174,12 +174,12 @@ Channel::maybe_process_rpns (Parser& parser, EventTwoBytes *tb) case 0x60: /* data increment */ _nrpn_state = RPNState (_nrpn_state|HaveValue); - parser.channel_nrpn_increment[_channel_number] (parser, rpn_id, 1); /* EMIT SIGNAL */ + parser.channel_nrpn_change[_channel_number] (parser, rpn_id, 1); /* EMIT SIGNAL */ return true; case 0x61: /* data decrement */ _nrpn_state = RPNState (_nrpn_state|HaveValue); - parser.channel_nrpn_decrement[_channel_number] (parser, rpn_id, -1); /* EMIT SIGNAL */ + parser.channel_nrpn_change[_channel_number] (parser, rpn_id, -1); /* EMIT SIGNAL */ return true; case 0x06: /* data entry MSB */ @@ -214,12 +214,12 @@ Channel::maybe_process_rpns (Parser& parser, EventTwoBytes *tb) case 0x60: /* data increment */ _rpn_state = RPNState (_rpn_state|HaveValue); - parser.channel_rpn_increment[_channel_number] (parser, rpn_id, 1); /* EMIT SIGNAL */ + parser.channel_rpn_change[_channel_number] (parser, rpn_id, 1); /* EMIT SIGNAL */ return true; case 0x61: /* data decrement */ _rpn_state = RPNState (_rpn_state|HaveValue); - parser.channel_rpn_decrement[_channel_number] (parser, rpn_id, -1); /* EMIT SIGNAL */ + parser.channel_rpn_change[_channel_number] (parser, rpn_id, -1); /* EMIT SIGNAL */ return true; case 0x06: /* data entry MSB */ diff --git a/libs/midi++2/midi++/parser.h b/libs/midi++2/midi++/parser.h index 40ba8209b0..7040e9b522 100644 --- a/libs/midi++2/midi++/parser.h +++ b/libs/midi++2/midi++/parser.h @@ -77,12 +77,10 @@ class LIBMIDIPP_API Parser { TwoByteSignal channel_controller[16]; ZeroByteSignal channel_active_preparse[16]; ZeroByteSignal channel_active_postparse[16]; - RPNSignal channel_rpn[16]; - RPNSignal channel_nrpn[16]; - RPNValueSignal channel_rpn_increment[16]; - RPNValueSignal channel_rpn_decrement[16]; - RPNValueSignal channel_nrpn_increment[16]; - RPNValueSignal channel_nrpn_decrement[16]; + RPNValueSignal channel_rpn[16]; + RPNValueSignal channel_nrpn[16]; + RPNSignal channel_rpn_change[16]; + RPNSignal channel_nrpn_change[16]; OneByteSignal mtc_quarter_frame; /* see below for more useful signals */ Signal mtc;