Re: OSClisten Issue
| Date | 2015-05-20 14:02 |
| From | Russell Pinkston |
| Subject | Re: OSClisten Issue |
| Attachments | None None |
The point of having the result variables be on the right (input) side of OSClisten is because OSC messages can have multiple arguments. And the "kans" variable on the left side is a trigger, so you can do this: kans OSClisten gichan, "/1/slider1", "f", kamp if (kans == 1) then kamp = kamp * 12000 endif Sent via the Samsung Galaxy Tab® 4, an AT&T 4G LTE tablet -------- Original message -------- From: Art Hunkins <abhunkin@uncg.edu> Date:05/19/2015 6:10 PM (GMT-06:00) To: csound-users@lists.sourceforge.net Subject: [Csnd] OSClisten Issue I've been working intensively on Android with OSClisten, receiving OSC data from TouchOSC GUIs (Layouts). I've no idea whether or not this issue pertains to other situations or platforms, though I suspect it does. It is this: The following code works: kamp init 0 kans OSClisten gichan, "/1/slider1", "f", kamp aout lfo kamp * 12000, 440, 1 outs aout, aout So does this: kamp init 0 kans OSClisten gichan, "/1/slider1", "f", kamp kamp2 = kamp * 12000 aout lfo kamp2, 440, 1 outs aout, aout But this (which I use all the time, and which works fine in the context of chnget and MIDI input) does not: kamp init 0 kans OSClisten gichan, "/1/slider1", "f", kamp kamp = kamp * 12000 aout lfo kamp, 440, 1 outs aout, aout The problem seems to be that an OSC k-time variable (here kamp) cannot be redefined. I feel sure this has something to do with the special way that OSC data are stored/handled that is different from how MIDI and chnget variables are treated. Is there any possibility that an alternative to the convoluted OSClisten opcode could be written that: 1) would more ressemble other control inputs - and have its output variable(s) on the left; 2) have its output stored in such a way as to allow it to be redefined at k-time? For those of us who'd like to offer OSC realtime control as an option to both MIDI and frontends (etc.) that use chnget, such an alternative would be welcome indeed. (I've had to do extensive editing of .csds to work around #2 above.) Art Hunkins ------------------------------------------------------------------------------ One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ applications Performance metrics, stats and reports that give you Actionable Insights Deep dive visibility with transaction tracing using APM Insight. http://ad.doubleclick.net/ddm/clk/290420510;117567292;y _______________________________________________ Csound-users mailing list Csound-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/csound-users Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here |