jit.gl.gridshape movement

    Jun 21 2013 | 11:32 am
    Anybody know how to change the size of a jit.gl.gridshape ? I am sure the answer is right under my nose, but I am having one of those days I think.
    Also, I am able to monitor the velocity of the shape, however is it possible to set this velocity rather than monitor it?

    • Jun 21 2013 | 1:32 pm
      To add to this, I have managed to get the y coordinates from my cv.jit.grab which I aim to control the jitter jit.phys.body. However, similarly with the previous problem I am having difficulty finding a method of doing this.
      I have the y coordinates in a yplace $1 message but how can I use this to control the jit.phys.body ?
    • Jun 21 2013 | 6:21 pm
      Just an update, I have attached two attrui's to a jit.phys.6dof and they move the object which is a great. However I can not understand what the values are making the object do. Changing of numbers does not seem to fit the movements of the object. Does anyone at all have any idea how to control an object simply up and down?
    • Jun 21 2013 | 6:25 pm
      please post a patch, with some comments indicating what you are having trouble with.
    • Jun 21 2013 | 6:45 pm
      Definitely post a patch, that will help.
      Regarding jit.gl.gridshape resizing, most (all?) GL objects will respond to "scale f f f" to resize, "position f f f" to translate/move, and "rotatexyz f f f" to rotate in the three axes. "f" are floats. There's also "rotate f f f f" which uses quaternions to do the rotation and is harder to wrap your brain around in some ways, but has some nice advantages over rotatexyz.
    • Jun 21 2013 | 7:12 pm
      Okay, will have a go at implementing what you recommend
      Here is the current patch with comments
    • Jun 22 2013 | 1:04 pm
      thanks for the heads up about the scale and position etc, these have now been implemented. However if I want to control the position of the object (up/down only) what is the correct method of doing so? Do I just bang a number into the message containing position f f f? Or will this method not work as I already have floats in the position method.
      I will post what an example of what I mean if it helps
    • Jun 24 2013 | 4:55 am
      Try this:
      (copy and choose "New from Clipboard" in Max):
    • Jun 24 2013 | 12:20 pm
      Okay I have tried implementing into the patch but all it does it is not controlling the object. The object is just spazzing about in the top left corner.
      I will attach the file so you can see.
      One positive thing to note that it is staying in its x-coordinates, just need to get some accurate control over the objects y-coordinates
      When I start the webcam interface tracking of the left blob, it sends the red object all over the place.
    • Jun 24 2013 | 4:29 pm
      Also, you stated in the patch that @collisions is not a valid attribute to jit.phys.body as it does not appear in the drop down box. I think you are mistaken here as it is second on the drop down menu.
      All the best,
    • Jun 25 2013 | 1:05 pm
      Sorted now! The problem was I had not scaled the y-coordinates to the worldbox... School boy error
      Cheers anyway