All Classes Namespaces Functions Variables Enumerations Enumerator Modules Pages
Public Member Functions | List of all members
ScriptingApi::Message Class Reference
Inheritance diagram for ScriptingApi::Message:
ScriptingObject ApiClass

Public Member Functions

int getNoteNumber () const
void delayEvent (int samplesToDelay)
var getControllerNumber () const
var getControllerValue () const
int getChannel () const
void setChannel (int newChannel)
void setNoteNumber (int newNoteNumber)
void setVelocity (int newVelocity)
void setControllerNumber (int newControllerNumber)
void setControllerValue (int newControllerValue)
int getVelocity () const
void ignoreEvent (bool shouldBeIgnored=true)
int getEventId () const
void setTransposeAmount (int tranposeValue)
int getTransposeAmount () const
void setCoarseDetune (int semiToneDetune)
int getCoarseDetune () const
void setFineDetune (int cents)
int getFineDetune () const
void setGain (int gainInDecibels)
int getGain () const
int getTimestamp () const
void store (var messageEventHolder) const
int makeArtificial ()
bool isArtificial () const
- Public Member Functions inherited from ApiClass
 ApiClass (int numConstants_)
void addConstant (String constantName, var value)
const var getConstantValue (int index) const
int getConstantIndex (const Identifier &id) const
Identifier getConstantName (int index) const
void addFunction (const Identifier &id, call0 newFunction)
void addFunction1 (const Identifier &id, call1 newFunction)
void addFunction2 (const Identifier &id, call2 newFunction)
void addFunction3 (const Identifier &id, call3 newFunction)
void addFunction4 (const Identifier &id, call4 newFunction)
void addFunction5 (const Identifier &id, call5 newFunction)
void getIndexAndNumArgsForFunction (const Identifier &id, int &index, int &numArgs) const
var callFunction (int index, var *args, int numArgs)
void getAllFunctionNames (Array< Identifier > &ids) const
void getAllConstants (Array< Identifier > &ids) const

Detailed Description

All scripting methods related to the midi message that triggered the callback.

Every method must be called on the message like this:


Member Function Documentation

void delayEvent ( int  samplesToDelay)

Delays the event by the sampleAmount.

int getChannel ( ) const

Returns the MIDI Channel from 1 to 16.

int getCoarseDetune ( ) const

Returns the coarse detune amount in semitones.

var getControllerNumber ( ) const

returns the controller number or 'undefined', if the message is neither controller nor pitch wheel nor aftertouch.

You can also check for pitch wheel values and aftertouch messages. Pitchwheel has number 128, Aftertouch has number 129.

var getControllerValue ( ) const

Returns the value of the controller.

int getEventId ( ) const

Returns the event id of the current message.

int getFineDetune ( ) const

Returns the fine detune amount int cents.

int getGain ( ) const

Returns the volume of the note.

int getNoteNumber ( ) const

Return the note number. This can be called only on midi event callbacks.

int getTimestamp ( ) const

Returns the timestamp of the message.

int getTransposeAmount ( ) const

Gets the tranpose value.

int getVelocity ( ) const

Returns the Velocity.

void ignoreEvent ( bool  shouldBeIgnored = true)

Ignores the event.

bool isArtificial ( ) const

Checks if the event was created by a script earlier.

int makeArtificial ( )

Creates a artificial copy of this event and returns the new event ID.

void setChannel ( int  newChannel)

Changes the MIDI channel from 1 to 16.

void setCoarseDetune ( int  semiToneDetune)

Sets the coarse detune amount in semitones.

void setControllerNumber ( int  newControllerNumber)

Changes the ControllerNumber.

void setControllerValue ( int  newControllerValue)

Changes the controller value (range 0 - 127).

void setFineDetune ( int  cents)

Sets the fine detune amount in cents.

void setGain ( int  gainInDecibels)

Sets the volume of the note (-100 = silence).

void setNoteNumber ( int  newNoteNumber)

Changes the note number.

void setTransposeAmount ( int  tranposeValue)

Transposes the note on.

void setVelocity ( int  newVelocity)

Changes the velocity (range 1 - 127).

void store ( var  messageEventHolder) const

Stores a copy of the current event into the given holder object.

©2017 HISE. This documentation is autogenerated from the HISE source code using Doxygen.