Bad OSC values
  • User avatar
    The Midi Thief
    master
    Posts: 483
    Joined: Thu Sep 29, 2005 7:19 pm
    Location: Stockholm, Sweden
    Contact:

    Bad OSC values

    by The Midi Thief » Mon Jan 24, 2011 1:00 pm

    This is not a specific Modul8 question really but since my main use for OSC is for controlling Modul8, I thought I'd start here. I'm having problem with my OSC input where the values are jittering. Probably just some bad settings somewhere but I need some pointers on where to look.

    This happens in a few different setups but I think TouchOSC might be the culprit, but I'm not sure. First I thought it was because of a bad network setup. My computer shows up twice in TouchOSCs settings on the iPad. But I tested it on my other MBP and set up a computer-computer network to reduce interference. However - I also tested running TouchOSC from my iPhone with the same jittering result.

    I have experienced the same jittering when sending TUIO data from the Kinect to Modul8 via OSCulator. I thought the jittering was due to that I hadn't done my depth map properly but it looks exactly the same as when using TouchOSC.

    I tought it was easiest to show the behavior in Quartz Composer. Any ideas about how to fix this? http://yfrog.com/5vjk3z

    [Edit: I uploaded a new movie with rounded decimals to show that there is something intercepting - a long float value gets thrown in there once in a while, but where the heck is it coming from?! And this is NOT specific to this Quartz composition. This is just to prove what is happening. I have the same problem when using OSC in Modul8.]
  • anomad
    master
    Posts: 412
    Joined: Sun Oct 21, 2007 10:07 pm
    Location: north cakalacky, usa
    Contact:

    by anomad » Mon Jan 24, 2011 3:56 pm

    . i've been using TUIOKinect and the OSC module w/o any major jumps like that. mapping x/y (using variable[2][4] and variable[2][5] ) to effects has been pretty smooth overall. the other values variable[2][6,7,8] are very jumpy.


    -james
    (a nomad. )
  • User avatar
    The Midi Thief
    master
    Posts: 483
    Joined: Thu Sep 29, 2005 7:19 pm
    Location: Stockholm, Sweden
    Contact:

    by The Midi Thief » Mon Jan 24, 2011 4:08 pm

    Yeah, I've been using x/y too for TuioKinect. So I think it's pretty obvioust that I have somehting else interfering with my OSC signals. But what the heck could it be?! I have a tech talk on Thursday where I've been planning to use OSC for some stuff so it would be really sweet to solve this before then.

    - I've tested on two different devices running TouchOSC
    - I've tested on two diffrent computers
    - I've tested on two different networks
    - I've tested with different OSC abled software: TouchOSC, OSCulator (+TuioKinect), Modul8, Quartz Composer

    I think however that I haven't had any disturbance while sending OSC from Ableton Live to Module8 over OSC and that is surprising. Yep - proof that Live-OSC-M8 is working just fine: http://www.vimeo.com/18938743
  • User avatar
    The Midi Thief
    master
    Posts: 483
    Joined: Thu Sep 29, 2005 7:19 pm
    Location: Stockholm, Sweden
    Contact:

    by The Midi Thief » Mon Jan 24, 2011 5:51 pm

    I got a reply straight from Hexler, the maker of TouchOSC. This sovles it on the QC side: http://hexler.net/software/qcosc

    I'll have to see later tonight if my problems with TuioKinect was due to a bad depth mask and maybe a fat error in my concept. Projecting on myself using the depth map as a mask might be a problem. Illuminating myself with the projector makes it harder or the Kinect to detect me. A catch 22 I believe. We'll see.
  • User avatar
    The Midi Thief
    master
    Posts: 483
    Joined: Thu Sep 29, 2005 7:19 pm
    Location: Stockholm, Sweden
    Contact:

    by The Midi Thief » Tue Jan 25, 2011 10:30 am

    Anomad, would you mind charing your OSC routing values if your are using OSCulator? Or tell me if there is a another software I should use? It just seems like I'm not doing it the best way at the moment. But wouldn't the reliable values depend on the scene and the the settings of your depth map?

    Anyhow, I've been using these values in OSCulator:
    /tuio/2D/cur/1
    0: x position -> /md8key/ctrl_layer_position_x/1/ arg[5]
    1: y position -> /md8key/ctrl_layer_position_y/1/ arg[5]

    I don't know if these are the best but they have constantly been feeding me data when I'm moving my hands.
  • anomad
    master
    Posts: 412
    Joined: Sun Oct 21, 2007 10:07 pm
    Location: north cakalacky, usa
    Contact:

    by anomad » Wed Jan 26, 2011 6:37 am

    . i just modified the OSC to listen on port 3333 (which is what TUIOKinect sends on)

    . i'm using X,Y for effect position (and keep meaning to get off my lazy ass and make a how-to video) - i don't think TUIOKinect is sending depth - or if it is, it's totally out of whack and is never consistent.

    . the OSC module pulls the packets in as dataDecList - i sort of cheat the data coming in, if there's a single point, then dataDecList[2][1] - the data type - will be ",sifffff", if no points are present, then it will be ",si" (same for all other points, dataDecList[3][1], etc) - and there will always be a final dataDecList[n][..] so the variables will always exist (until one of them == ",si" - which is the last packet


    if dataDecList[2][1] == ',si' :
    modul8.setFilters({},fxLayer,False)
    else :
    xname = useFx['XYMOVE']['xDef']['name']
    useFx['FX']['PARAMETERS'][xname] = dataDecList[2][4]
    module.setValue('grid', 'x', dataDecList[2][4] )

    yname = useFx['XYMOVE']['yDef']['name']
    useFx['FX']['PARAMETERS'][yname] = dataDecList[2][5]
    module.setValue('grid', 'y', 1- dataDecList[2][5] ) ## need to invert 'y' for grid

    . for what it's worth, useFx is an FX definition, a parameter to mod (w/high+low values - from the 120avFX module) and X,Y coordinate names :

    useFx = { 'FX' : {'FILTER': '(CI) Circle Splash Distortion', 'PARAMETERS': {'Center Y': 0.5, 'Center X': 0.5, 'Radius': 0.145}} , 'FXMOD' : {'NAME' : 'Radius', 'PARAMS': {'low' : 0.03, 'high' : 0.5 , 'default': 0.145, 'type': 'real'} }, 'XYMOVE' : { 'xDef' : {'name' : 'Center X', 'low' : 0.0, 'high': 1.0, 'type' : 'real'} , 'yDef' : {'name' : 'Center Y', 'low' : 0.0, 'high': 1.0, 'type' : 'real'} } }

    . let me know if that makes any sense.. :)

    -james
    (a nomad. )

Who is online

Users browsing this forum: No registered users and 5 guests