Forums > Jitter

rotatexyz attribute incompatible with previous max versions?

April 14, 2013 | 9:24 pm

Hi list,

This subject MUST have been discussed extensively but I can’t seem to find the discussion.

When one adds a rotatexyz attribute to a jit.gl.gridshape for instance, the rotations applied to the shape are very different when one uses max 6.0.1 (or earlier), as opposed to when one uses one of the latest versions of max.

This example patch will show a vertically oriented cylinder in an older version of max, while it is horizontally oriented in a newer version. Where can i find info about this and how do i convert my older patches using rotatexyz in the old way to also work with newer versions of max?

thanks!

tarik

– Pasted Max Patch, click to expand. –

April 15, 2013 | 7:14 pm

hi tarik.
this is the result of changes in how gl objects handle transforms in max 6 vs max 5, and has to do the the order the euler rotations are applied. unfortunately, max 6 handles this differently than max 5. believe it or not, this is the first post i’ve seen catching this discrepancy, although is somewhat related to this post, which explains the details more:

http://cycling74.com/forums/topic.php?id=42318

the feature request for a rotation order attribute is still pending.

in the meantime, your best bet may be to do a find and replace using a text editor or command line on your relevant max patches.
the correct values to mimic the behavior you see in max 5 is "rotatexyz 90 -90 180"

apologies for the inconvenience.


April 16, 2013 | 11:36 am

Amazing! I’d think this change would significantly alter the behaviour of many many jitter patches and would have complaints flooding in.

Well, I figured some stuff out and I now went the route of writing my own rotatexyz to quaternion converter as a Java external, so I can apply the rotations in any order I’d like. Rotation used to be in the order XYZ and now is done in the order ZYX.

If you’re interested, do let me know!

..and thanks



dtr
April 16, 2013 | 2:18 pm

I’d be interested in that!


April 16, 2013 | 8:26 pm

I’d be interested as well.


April 20, 2013 | 1:12 pm

Cool, I’ll make it somewhat presentable to the public and available then… keep you posted


June 19, 2013 | 12:38 pm

hi guys.
6.1.3 introduces a new attribute for jit.gl.render, called @rotate_order.
this will set the rotation order for all objects bound to that context.
hopefully this will alleviate some of the problems when porting from max 5.


Viewing 7 posts - 1 through 7 (of 7 total)