How to keyframe the position of a pivot?
I'm trying to animate a cube rolling on a floor. The problem is the pivot of the cube should change very 90 degree but I don't know how to key it . Can someone give me a hand please. Thanks.
http://server5.uploadit.org/files2/2...ivot122203.jpg |
I am not sure you can.
But why not put locators in the corners and key using the 4 locators. |
You can't keyframe a pivot point. However, you could play with a variety of constraint-based options (I'm thinking a parent constraint would work well here).
Or, just keyframe the animation. It's much faster that way. :) |
You CAN key the pivot point. ;) Kinda hokey, but it can be done. I'll try to describe it:
1) First, open the cube's attribute editor. Assuming your cube is named pCube1, click the pCube1 tab. Open the Pivots folder and check "Display Rotate Pivot." You can also open the World Space folder. 2) Move your pivot point to the edge of the cube where you want the first rotation to happen. 3) Open Window > General Editors > Channel Control. Move the following from Unkeyable to Keyable: rotatePivotX rotatePivotY rotatePivotZ rotatePivotTranslateX rotatePivotTranslateY rotatePivotTranslateZ These will appear in your Channel Box. 4) Go ahead and key the first rotation of the cube at the edge where your pivot point currently is. When it rotates 90 degrees and it comes to the point where it will need to then change pivot location in order to roll on the next edge, go forward one frame and in the World Space folder of your cube, change the World Rotate Pivot X, Y, or Z. In my case, my cube was 16 units large, so I moved it 16 units in the X direction. You'll notice a few of the channels that you added change to indicate this movement of the pivot. Key them in the Channel Box. Now, go back one frame, put the pivot back to it's original position, and key those same channels again. 5)Step and repeat. Image - http://www.mtmckinley.net/SimplyMaya/pivot.jpg Video - http://www.mtmckinley.net/SimplyMaya/cubeRotate.avi (100k) Maya 5.0 file - http://www.mtmckinley.net/SimplyMaya/rotate.mb (45k) |
damn Mike I will have to remember that.
Good tip. I would have done it with locators.:p |
wow, thanks everyone! :D
|
Well, you learn something new everyday. :D
I still like keyframing by hand. Zero setup time. ;) |
:bow: :headbang: :D
|
it goes to show you there is 110 ways to get something done in maya:p
|
Glad to help. ;)
|
This is all really cool...... but how does a REAL cube roll on the floor in the first place? I mean, for a cube to "roll" it bounces from edge to edge or corner to corner - the faces don't all touch the ground one after the other. Either that or it slides instead of "rolling". I guess it could be acheived using trickery with moving internal weights.
|
|
All times are GMT. The time now is 11:01 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Simply Maya 2018