|
|
This the a standard (and comprehensive) Filter object type that is used by the TSE3 library.
There is provision for the following features:
Use the following command classes to manipute this object in a undo/redo environment.
See also: Filter
MidiFilter ()
| MidiFilter |
Creates a MidiFilter with the default parameters which leave MidiEvents unchanged.
MidiFilter (const MidiFilter &)
| MidiFilter |
~MidiFilter ()
| ~MidiFilter |
[virtual]
MidiFilter & operator= (const MidiFilter &)
| operator= |
Reimplemented from Filter.
bool status ()
| status |
[const]
Returns the status value.
A value of false means the filter blocks all output, returning MidiCommand_Invalid instead of output
Returns: The status value
See also: setStatus
void setStatus (bool s)
| setStatus |
Set the status value.
Parameters:
s | The new status value to set |
See also: status
bool channelFilter (int c)
| channelFilter |
[const]
Returns the value of a MIDI channel filter.
If true then events on this MIDI channel are allowed to pass through filter. If false, events are not passed through filter.
Parameters:
c | MIDI channel to find channel filter status of |
Returns: The status of the MIDI channel's filter
See also: setChannelFilter
void setChannelFilter (int c, bool val)
| setChannelFilter |
Sets the value of a channel filter.
Parameters:
c | MIDI channel to set filter status of |
val | New MIDI channel filter status value |
See also: channelFilter
int channel ()
| channel |
[const]
Returns the MIDI channel value.
A value of MidiCommand::SameChannel means do not force to a particular channel.
Returns: MIDI channel events will be forced to
See also: setChannel
void setChannel (int c)
| setChannel |
Set the channel value.
Parameters:
c | New MIDI channel events will be forced to |
See also: channel
int port ()
| port |
[const]
Returns the MIDI port value.
A value of MidiCommand::SamePort means do not force to a particular port.
Returns: MIDI port number events will be forced to
See also: setPort
void setPort (int p)
| setPort |
Set the port value.
Parameters:
p | New MIDI port number events will be forced to |
See also: port
Clock offset ()
| offset |
[const]
Returns the time offset value.
Returns: Clock value added to each MidiEvent
See also: setOffset
void setOffset (Clock o)
| setOffset |
Sets the time offset value.
Parameters:
o | New Clock value added to each MidiEvent |
See also: offset
int timeScale ()
| timeScale |
[const]
Returns the time scale value.
A value of 100 will have no effect. The value is a percentage that ranges from 1 to 500.
Returns: The time scale value
See also: setTimeScale
void setTimeScale (int t)
| setTimeScale |
Set the time scale value.
Parameters:
t | New time scale value |
See also: timeScale
Clock quantise ()
| quantise |
[const]
Returns the quantise value. This is a linear quantise resolution that MidiEvent times will be 'snapped' to.
A value of zero means do not quantise.
Returns: The quantise resolution value
See also: setQuantise
void setQuantise (Clock q)
| setQuantise |
Set the quantise value.
Parameters:
q | New quantise resolution value |
See also: quantise
Clock minLength ()
| minLength |
[const]
Returns the minimum note length. This is applied to MidiCommand_NoteOn events to ensure that they are of at least a certain duration.
A value of 0 represents no minimum length.
Returns: The minimum note length
See also: setMinLength
void setMinLength (Clock ml)
| setMinLength |
Set the minimum length value.
Parameters:
q | New minimum length value |
See also: minLength
Clock maxLength ()
| maxLength |
[const]
Returns the minimum note length. This is applied to MidiCommand_NoteOn events to ensure that they are of at least a certain duration.
A value of -1 represents to maximum length.
Returns: The maximum note length
See also: setMaxLength
void setMaxLength (Clock ml)
| setMaxLength |
Set the maximum length value.
Parameters:
lm | New maximum length value |
See also: minLength
int transpose ()
| transpose |
[const]
Returns the transpose value. This is an integer number that is added to the value of notes in any note-related MidiEvent.
This can range between -127 to +127
Returns: The transpose value
See also: setTranspose
void setTranspose (int t)
| setTranspose |
Set the transport value.
Parameters:
t | New transport value |
See also: transpose
int minVelocity ()
| minVelocity |
[const]
Returns the minimum velocity window value. Note MidiEvents with veloicties below this value will have their velocity set to this value. This is useful to prevent quiet notes from not being heard, for example.
A value of 0 will have no effect, and is considered 'off'.
Returns: Minimum velocity window value
See also: setMinVelocity
void setMinVelocity (int v)
| setMinVelocity |
Set the minimum velocity window value.
Parameters:
v | New minimum velocity window value |
See also: minVelocity
int maxVelocity ()
| maxVelocity |
[const]
Returns the maximum velocity window value. Note MidiEvents with velocities above this value will have their veolcity set to this value. This is useful to prevent loud notes from drowning out other notes, for example.
A value of 127 will have no effect, and is considered 'off'.
Returns: Maximum velocity window value
See also: setMaxVelocity
void setMaxVelocity (int v)
| setMaxVelocity |
Set the maximum velocity window value.
Parameters:
v | New maximum velocity window value. |
See also: maxVelocity
Clock velocityScale ()
| velocityScale |
[const]
Returns the velocity scale value. This value scales the time value of a MidiEvent.
A value of 100 will have no effect. The value is a percentage that ranges from 1 to 200.
Returns: Velocity scale value
See also: setVelocityScale
void setVelocityScale (int v)
| setVelocityScale |
Set the velocity scale value.
Parameters:
v | New velocity scale value |
See also: velocityScale
MidiEvent filter (const MidiEvent &e)
| filter |
[const virtual]
Reimplemented from Filter for internal purposes..
void save (std::ostream &o, int i)
| save |
[const virtual]
Reimplemented from Serializable for internal purposes..
void load (std::istream &i, SerializableLoadInfo &info)
| load |
[virtual]
Reimplemented from Serializable for internal purposes..