The MidiMapper maintains a table mapping logical port destinations with where MidiEvents should /really/ be sent.
This is used by the Transport class prior to sending an event to a MIDI interface.
This interface allows you to establish arbitrary mappings. For ports that aren't mapped, the mapper will let the event through unchanged.
| MidiMapper ()
The default MidiMapper object performs no mapping whatsoever.
| ~MidiMapper ()
|const int map (int fromPort)
Returns the mapping for a particular port.
If no mapping has been set for the specified port, the return
value will be the same as
|fromPort||port to read mapping for|
Returns: Port number this maps to
See also: setMap
|void setMap (int fromPort, int toPort)
Set the mapping for a particular channel and port
fromPort, you cannot specify MidiCommand::NoPorts
To reset a mapping rule, you can just set
|fromPort||port to set mapping for (MidiCommand::AllPorts to match all)|
|toPort||port to map to|
See also: map
|int maximumMap ()
The MidiMapper holds lists of port mappings. This method returns the maximum port a mapping has been made for.
Returns: Maximum port number a mapping has been made for
| MidiEvent filter (const MidiEvent &me)
Reimplemented from Filter for internal purposes..
|void reset ()
Reset the MidiMapper to a default state (i.e. no mappings).