OpenShot Library | OpenShotAudio  0.2.2
juce::MidiRPNDetector Class Reference

Parses a stream of MIDI data to assemble RPN and NRPN messages from their constituent MIDI CC messages. More...

#include <juce_MidiRPN.h>

Public Member Functions

 MidiRPNDetector () noexcept
 Constructor. More...
 
 ~MidiRPNDetector () noexcept
 Destructor. More...
 
void reset () noexcept
 Resets the RPN detector's internal state, so that it forgets about previously received MIDI CC messages.
 
bool parseControllerMessage (int midiChannel, int controllerNumber, int controllerValue, MidiRPNMessage &result) noexcept
 Takes the next in a stream of incoming MIDI CC messages and returns true if it forms the last of a sequence that makes an RPN or NPRN. More...
 

Detailed Description

Parses a stream of MIDI data to assemble RPN and NRPN messages from their constituent MIDI CC messages.

The detector uses the following parsing rules: the parameter number LSB/MSB can be sent/received in either order and must both come before the parameter value; for the parameter value, LSB always has to be sent/received before the value MSB, otherwise it will be treated as 7-bit (MSB only).

Definition at line 71 of file juce_MidiRPN.h.

Constructor & Destructor Documentation

◆ MidiRPNDetector()

juce::MidiRPNDetector::MidiRPNDetector ( )
noexcept

Constructor.

Definition at line 26 of file juce_MidiRPN.cpp.

◆ ~MidiRPNDetector()

juce::MidiRPNDetector::~MidiRPNDetector ( )
noexcept

Destructor.

Definition at line 30 of file juce_MidiRPN.cpp.

Member Function Documentation

◆ parseControllerMessage()

bool juce::MidiRPNDetector::parseControllerMessage ( int  midiChannel,
int  controllerNumber,
int  controllerValue,
MidiRPNMessage result 
)
noexcept

Takes the next in a stream of incoming MIDI CC messages and returns true if it forms the last of a sequence that makes an RPN or NPRN.

If this returns true, then the RPNMessage object supplied will be filled-out with the message's details. (If it returns false then the RPNMessage object will be unchanged).

Definition at line 34 of file juce_MidiRPN.cpp.

Referenced by juce::MidiRPNGenerator::generate(), and juce::MPEZoneLayout::processNextMidiEvent().


The documentation for this class was generated from the following files: