Rotating with jit.phys.mulitple

Apr 1, 2013 at 10:01pm

Rotating with jit.phys.mulitple

I have a patch in which a is being spread into ring of objects using Using jit.phys.multiple I am creating physics bodies for each object in the multiple spread so that we can register the collision of these objects with another.
I can send a rotatexyz attribute to the to rotate the entire group together.
However, the jit.phys.multiple bodies do not rotate along with this and are left hanging.
jit.phys.multiple does not have a rotatexyz attribute and I’m not sure how to get this information to it.

Attached is an example of this situation, snagged form the help patch.

– Pasted Max Patch, click to expand. –
Apr 2, 2013 at 5:21pm

you can do this with the jit.gen qrot operator, which rotates a vector (the individual body positions) by a quaternion (your rotation value).
jit.euler2quat will convert your euler xyz values to a quaternion.

– Pasted Max Patch, click to expand. –
Apr 2, 2013 at 10:38pm

Awesome! Thanks Rob.


You must be logged in to reply to this topic.