next up previous contents index
Next: 13.2.5 OSC address variables Up: 13.2 Variables Previous: 13.2.3 Miscellaneous variables   Contents   Index


13.2.4 Message based variables

A message based variable is a variable containing an OSC message which will be evaluated at the time of the event. They are supported by all kind of events. Like the variables above, a message based variable starts with a '$' sign followed by a valid 'get' message enclosed in parenthesis:
\begin{rail}
msgVar : '(' oscaddress 'get' (\vert params) ')'
\end{rail}

The evaluation of a 'get' message produces a message or a list of messages. The message based variable will be replaced by the parameters of the messages resulting from the evaluation of the 'get' message. Note that all the 'get' messages attached to an event are evaluated at the same time.

EXAMPLE
An object that takes the x position of another object on mouse down:

/ITL/scene/myObject watch mouseDown
(/ITL/scene/myObject x '$(/ITL/scene/obj get x)')




Grame - INScore project