View Full Version : Set Translate Pivot to Rotation Script???


JellyFire
09 September 2007, 04:26 PM
Hey guys/girls...
I have a problem. Grab a camera, enter component mode, click the question mark to see the rotation axis, move it and exit component mode...
The rotation axis is set fine, but the translation is still at world...

Is there a script to rotate the translation axis so you can point it in a new direction...
(I know you can just parent it to a group node that has the correct rotation, but just wondering if you could do it without.) Say you'd animated a camera for half of the scene, but wanted to then just quickly change the direction of translation without rotating it. Thats what I need....

Any guesses?
Christian

harmless
09 September 2007, 04:46 PM
Please double click the translate tool. The option box that pops up has a number of options including setting the translate axis to object, world, along rotation axis, or a custom axis orientation which accepts 3 floats.

the mel to access this is as follows:

// modes 0 - 6 are available, 6 is the custom axis orientation
manipMoveContext -e -mode 6 Move;

//set the custom axis orientation
manipMoveContext -e -orientAxes 0.0 10.0 0.0 Move;


rock it out my friend.
rock it out.

JellyFire
09 September 2007, 08:55 AM
Cheers mate, that was simple enough :D
Cause I use the hotbox to access translation methods I ended up not realising the align along rotation axis was there (even though it's in a sub menu of the translate hotbox)...

Thanks for saving me a lot of time :D I was looking into xform and all sorts of stuff to force the translation down the rotation axis...

Christian

CGTalk Moderation
09 September 2007, 08:55 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.


1