X
Table Of Contents
- Logic Pro X Effects
- Contents
- Chapter 1: Amps and pedals
- Chapter 2: Delay effects
- Chapter 3: Distortion effects
- Chapter 4: Dynamics processors
- Chapter 5: Equalizers
- Chapter 6: Filter effects
- Filter effects overview
- AutoFilter
- EVOC 20 Filterbank
- EVOC 20 TrackOscillator
- EVOC 20 TrackOscillator overview
- Vocoder overview
- EVOC 20 TrackOscillator interface
- EVOC 20 TrackOscillator analysis in parameters
- Use EVOC 20 TrackOscillator analysis in
- EVOC 20 TrackOscillator U/V detection parameters
- EVOC 20 TrackOscillator synthesis in parameters
- EVOC 20 TrackOscillator oscillators
- EVOC 20 TrackOscillator formant filter
- EVOC 20 TrackOscillator modulation
- EVOC 20 TrackOscillator output parameters
- Fuzz-Wah
- Spectral Gate
- Chapter 7: Imaging processors
- Chapter 8: Metering tools
- Chapter 9: MIDI plug-ins
- Chapter 10: Modulation effects
- Chapter 11: Pitch effects
- Chapter 12: Reverb effects
- Chapter 13: Space Designer convolution reverb
- Chapter 14: Specialized effects and utilities
- Chapter 15: Utilities and tools
- Appendix: Legacy effects
Chapter 9 MIDI plug-ins 19 0
JavaScript objects
JavaScript objects overview
The Scripter plug-in provides JavaScript objects that describe or represent MIDI information
and information about the host application, in addition to performing MIDI processing-related
functions. See the following sections for details about dierent object types:
•
Use the JavaScript Event object
•
Use the JavaScript TimingInfo object
•
Use the JavaScript MIDI object
Use the JavaScript Event object
When the HandleMIDI function is called, an Event object represents one MIDI event and
implements the following methods you can call in your script:
Event methods
•
Event.send(): Send the event.
•
Event.sendAfterMilliseconds(number ms): Send the event after the specied value has elapsed
(can be an integer or a oating point number).
•
Event.sendAtBeat(number beat): Send the event at a specic beat (oating point number) in the
host’s timeline.
•
Event.sendAfterBeats(number beat): As above, but uses the beat value as a delay in beats from
the current position.
•
Event.trace(): Print the event to the plug-in console.
•
Event.toString(): Returns a String representation of the event.
•
Event.channel(number): Sets MIDI channel 1 to 16.
Note: Event.channel is an event property, rather than a method.
The Event object is not instantiated directly but is a prototype for the following event-
specic object types. All of the following types inherit the methods described above and the
channel property.
Event types
The event types and their properties are passed to HandleMIDI as follows:
•
NoteOn.pitch(integer number): Pitch from 1–127.
•
NoteOn.velocity(integer number): Velocity from 0–127. A velocity value of 0 is interpreted as a
note o event, not a note on.
•
NoteO.pitch(integer number): Pitch from 1–127.
•
NoteO.velocity(integer number): Velocity from 0–127.
•
PolyPressure.pitch(integer number): Pitch from 1–127. Polyphonic aftertouch is uncommon
on synthesizers.
•
PolyPressure.value(integer number): Pressure value from 0–127.
•
ControlChange.number(integer number): Controller number from 0–127.
•
ControlChange.value(integer number): Controller value from 0–127.
Tip: Use MIDI.controllerName(number) to look up the name of the controller.
•
ProgramChange.number(integer number): Program change number from 0–127.
•
ChannelPressure.value(integer number): Aftertouch value from 0–127.
•
PitchBend.value(integer number): 14-bit pitch bend value from -8192–8191. A value of 0 is center.