Login | Register 
FEATURES
APPLICATIONS
DOWNLOADS
EDUCATION
BLOG
WIKI
FORUM
STORE

point cloud to osc

Still a little green? Ask your beginner's questions here

Re: point cloud to osc

Postby leolodreamland » Wed Feb 08, 2017 5:53 pm

here's the link to code that works... the leap motion for processing
http://www.wekinator.org/examples/
___________________
about.me/chromatouch
User avatar
leolodreamland
 
Posts: 16
Joined: Tue Sep 23, 2008 10:24 am

Re: point cloud to osc

Postby leolodreamland » Wed Feb 08, 2017 5:53 pm

i'll try and break open the code and read it into something useful like puredata when i get a chance...
___________________
about.me/chromatouch
User avatar
leolodreamland
 
Posts: 16
Joined: Tue Sep 23, 2008 10:24 am

Re: point cloud to osc

Postby exsstas » Sat May 13, 2017 7:07 pm

I'm also have same problem: Wekinator doesn't recive OSC from TD, but recive from some of the other apps.
So, to discover more, I've used a OSCIn DAT unstead of CHOP and recieve dat both from OSCOut CHOP and from app that works, and here it is:
0.jpg
0.jpg (133.69 KiB) Viewed 2314 times


So, Wekkinator understands OSC in format like this:
Code: Select all
/wek/inputs ,ff 186 472

where all values goes in one row, while TouchDesigner sends every channel in new row:
Code: Select all
/wek/inputs1 ,f 186
/wek/inputs2 ,f 472


I didn't figure out yet how to make TD sends OSC in single-row format. Can anyone help?
exsstas
 
Posts: 33
Joined: Sun Dec 22, 2013 3:48 pm

Re: point cloud to osc

Postby Ivan » Sun May 14, 2017 1:45 pm

How are you sending? Python should allow you to do that...

op(<outOSCop>).sendOSC('/wek/inputs',[186,472])
User avatar
Ivan
Staff
 
Posts: 169
Joined: Fri Mar 18, 2016 7:12 pm

Re: point cloud to osc

Postby exsstas » Sun May 14, 2017 7:11 pm

Ivan wrote:How are you sending? Python should allow you to do that...

op(<outOSCop>).sendOSC('/wek/inputs',[186,472])


I'm not good with Python. I've tried ChopExec with
Code: Select all
def valueChange(channel, sampleIndex, val, prev):
   chans = op('chans')[0,0]
   fs = op('fs')[0,0]
   vals = [',', fs, chans]
   op('oscout1').sendOSC('/wek/inputs', vals)
   return

And result is like /wek/inputs "," "fff" "0.19109 -0.09557334 -0.05238229

What I need is /wek/inputs ,fff 0.19109 -0.09557334 -0.05238229 or
/wek/inputs ,letter "f" repeats as many time as number of channels values from all channels of CHOP as floats
exsstas
 
Posts: 33
Joined: Sun Dec 22, 2013 3:48 pm

Re: point cloud to osc

Postby Ivan » Mon May 15, 2017 12:20 am

sendOSC actually builds those data type tags (the 'f's) for you, so just sendOSC('/wek/inputs', chans) should do it, if chans is the list of data you want to send.

To see exactly what you're sending, set up an oscInDAT to listen to your out and be sure to have the Include Type Tag set to True.
User avatar
Ivan
Staff
 
Posts: 169
Joined: Fri Mar 18, 2016 7:12 pm

Re: point cloud to osc

Postby exsstas » Mon May 15, 2017 4:07 pm

Ivan wrote:sendOSC actually builds those data type tags (the 'f's) for you, so just sendOSC('/wek/inputs', chans) should do it, if chans is the list of data you want to send.

To see exactly what you're sending, set up an oscInDAT to listen to your out and be sure to have the Include Type Tag set to True.

Thank you. After some changes I finally made it works, so I end up with component adaptive to CHOP with any number of chanels.
In case if someone else need it, here it is:

WekinatorOSC.tox
(4.67 KiB) Downloaded 122 times



PS: Unfortunately, it works really slow if you have more than 50-100 chanels, don't know what to do with it
exsstas
 
Posts: 33
Joined: Sun Dec 22, 2013 3:48 pm

Re: point cloud to osc

Postby whooki3 » Fri May 25, 2018 2:24 pm

This works brilliantly, thanks a lot!

Does anyone know how I can activate the dynamic time warping in Wekinator from within Touch?
If I got this figured out it would help me a lot with this project I'm working on!

Thanks in advance.
whooki3
 
Posts: 9
Joined: Wed Jan 25, 2017 8:00 am

Previous

Return to Beginners

Who is online

Users browsing this forum: Google [Bot] and 12 guests

cron