Getothersparameter( id, param ), Sendosc( address, path [, format ] [, values ] ), Requestallnoteon( function ) – Expert Sleepers MIDI & OSC Scripting v1.1.0 User Manual

Page 8: Requestallnoteoff( function )

Advertising
background image

The ‘id’ is matched against the OSC Port Offset of the plug-ins. Any plug-in that matches
the id will have its parameter set.

Note that all the plug-ins must be loaded by the same host application. For controlling in-
stances of the plug-in loaded by other hosts, or running on other computers, use the
‘sendOSC’ command (below).

E.g.

setOthersParameter( 2, paramID_Pitch, 12.0 )

getOthersParameter( id, param )

As getParameter(), but gets the parameter from another instance of the plug-in. See
setOthersParameter() for a fuller explanation. E.g.

pitch = getOthersParameter( 2, paramID_Pitch )

sendOSC( address, path [, format ] [, values ] )

Sends an OSC message. ‘values’ is an optional array of data items to be sent with the mes-
sage. If ‘values’ is used, then ‘format’ is an optional string that indicates how the items in
the values array should be interpreted. This is required because Lua treats all numbers as
being of the same type, whereas OSC differentiates between integers and floating point
values. The number of characters in ‘format’ should be the same as the number of values.
Each character may be one of ‘i’ (integer), ‘f’ (float) or ‘s’ (string).

E.g.

sendOSC( "osc.udp://localhost:7001", "/foo" )
sendOSC( "osc.udp://localhost:7001", "/foo", { 3, 5.2, "hello" } )
sendOSC( "osc.udp://localhost:7001", "/foo", "ifs", { 3, 5.2, "hello" } )

Note that the second example sends two floats and a string; the third sends an integer, a
float and a string.

requestAllNoteOn( function )

Request that the given function be called in response to any MIDI note on event. E.g.

local function handleNoteOn( channel, noteNumber, velocity )

-- do stuff

end
requestAllNoteOn( handleNoteOn )

requestAllNoteOff( function )

Request that the given function be called in response to any MIDI note off event. E.g.

local function handleNoteOff( channel, noteNumber, velocity )

-- do stuff

end
requestAllNoteOff( handleNoteOff )

Advertising