From 1d10ce0a46a0c971199355eeb3648ff6a65c7073 Mon Sep 17 00:00:00 2001 From: Francois Best Date: Sat, 6 Jul 2013 15:53:40 +0200 Subject: [PATCH] No need for channel info when parsing. --- src/MIDI.h | 2 +- src/MIDI.hpp | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/MIDI.h b/src/MIDI.h index f1356b9..0e54745 100644 --- a/src/MIDI.h +++ b/src/MIDI.h @@ -118,7 +118,7 @@ public: private: bool inputFilter(Channel inChannel); - bool parse(Channel inChannel); + bool parse(); void resetInput(); private: diff --git a/src/MIDI.hpp b/src/MIDI.hpp index 774624f..f6b02b4 100644 --- a/src/MIDI.hpp +++ b/src/MIDI.hpp @@ -470,7 +470,7 @@ bool MidiInterface::read(Channel inChannel) if (inChannel >= MIDI_CHANNEL_OFF) return false; // MIDI Input disabled. - if (parse(inChannel)) + if (parse()) { if (inputFilter(inChannel)) { @@ -493,8 +493,8 @@ bool MidiInterface::read(Channel inChannel) // Private method: MIDI parser template -bool MidiInterface::parse(Channel inChannel) -{ +bool MidiInterface::parse() +{ const byte bytes_available = mSerial.available(); if (bytes_available == 0) @@ -624,7 +624,7 @@ bool MidiInterface::parse(Channel inChannel) #else // Call the parser recursively // to parse the rest of the message. - return parse(inChannel); + return parse(); #endif } @@ -762,7 +762,7 @@ bool MidiInterface::parse(Channel inChannel) #else // Call the parser recursively // to parse the rest of the message. - return parse(inChannel); + return parse(); #endif } }