[PD] Converting list to message, was: OSCprepend to message; input to sendOSC?

Urs Liska pd at ursliska.de
Thu Sep 22 23:15:01 CEST 2005


[list] was introduced in 0.39.

Martin Peach schrieb:
> 
> I don't have a 'list' object so I used the following methods:
> e.g. for "/synth/voices/*/stop" you would do:
> [symbol /synth/voices/*/stop]
> |
> [send $1(
> |
> [sendOSC]
> 
> For "/synth/preset 11" this works:
> [symbol /synth/preset] [11\
> |                       |
> [pack s f                ]
> |
> [send $1 $2(
> |
> [sendOSC]
> 
> For "/synth/VCF/689 1.5" you could do:
> [689\
> |
> [sprintf /synth/VCF/%d]
> |
> [symbol $1] [1.5\
> |           |
> [pack s f    ]
> |
> [send $1 $2(
> |
> [sendOSC]
> 
This would require me to count the arguments and route to the compatible 
method.
> 
> ...but if you already have the list and don't need to construct it just 
> a [prepend send] should work:
> [OSCroute]
> |
> [prepend send]
> |
> [sendOSC]
That's what I thought. But [prepend send] results in [list send ...(
That's why the [list trim] is necessary.

Anyway, thanks for your continuing efforts
Urs
-- 
Urs Liska
Glümerstr. 5
D-79102 Freiburg

www.graft-music.com
www.suonomobile.de

[Pd 0.39.0, WinXP]




More information about the Pd-list mailing list