Animating a random axis rotation

Hello everyone. I must say I don’t know how to start since this is my first post here and I don’t really know the community. I did a brief search of my problem but found only partial answers that did not solve it, so I hope I’m doing the right thing creating a new thread and asking about it here. Also, I must add the standard line: I’m new to Blender, I find it pretty cool but I don’t know everything it holds.

The problem I’m talking about is the animation of a custom rotation of an object. I’ll try and explain all the details. I have an object which is rotated in space (its bounding box walls are not parallel to any of the reference planes). Also, I’m trying to rotate this object around a random axis in space (meaning that the axis is not parallel to any of the global or local axis Ox, Oy or Oz). I do this rotation by adding a custom orientation based on an edge in the mesh and placing the cursor on one of the end vertices of this edge. The rotation goes as planned and everything is fine.

Here comes the tricky part: I also need to animate this rotation. And because it’s for another project, I can’t use bones and such (frankly I don’t even know how they work yet). So using the Animation Datablock (viewstyle), I set the keyframes and rotate my object as I usually do in the 3D View.

The animation resulting is nothing like I want it to be. Even if I set the object’s center on the rotation axis (Editing panel - Mesh - Center cursor) and even if I use only Rot keys, the object still wobbles in a way I don’t want it to. This happens because the RotX,Y,Z IPO curves are an interpolation between the initial and final state of the object’s angles to the respective axes (the way I understood it). Together with the fact that both object bounding box and rotation axis are not parallel to any of the global axes, it’s practicly impossible for me to determine the functions on which those angles vary. But I know they aren’t linear (or simmilar/close to linear).

Is there any way around it? All I want is the same movement the object has when I move it in the 3D window. Animating frame by frame is stil not going to work I believe, because between 2 frames there is still gonna be that interpolation and the end result migt be a less powerfull but more repetitive wobbling. Thanks in advance.

One solution could be:
animate your object around the z axis for example, then add an empty in the center of the rotaxis and make the empty the parent of the object.
Now you can control the rotation axis with the empty how you like.


One solution could be:
animate your object around the z axis for example, then add an empty in the center of the rotaxis and make the empty the parent of the object.
Now you can control the rotation axis with the empty how you like.


Edit: I don’t know why, but the forum software posted this twice?

I’m sorry, but I couldn’t follow. I don’t understand what you mean with the first sentence: “animate your object around the z axis”.
What I did: I tried to place a parent empty on my desired “random” (not arthogonal) rotation axis, but I get the same result. Rotating the empty around its local axis results in an undesirable variation function of the IPO Rot curves (which are global). Meaning: the empty rotates fine localy, he drags the object fine, but in the animation, all global angles relative to Ox, Oy and Oz vary, resulting in a different movement.

Is it possible to describe IPO curves for local axes (or even custom transform orientations) or am I stuck with global RotX, RotY, RotZ IPOs? :frowning:


You can use IPO curves for local rotation. You can set these up in the IPO window, but I can’t remember if they are accessible through the I-KEY.


Sorry if I was not clear. Or perhaps I misunderstood you

Again in smaller steps:

1.Match the rotation axis of your object to one of the global axis(lets say z)
2. Apply scale and rotation to your object. (Ctrl+A, 1)
3. Animate the Rotation of your object around this axis (Now z).
By setting Keyframes at 0 degrees and 360 degrees, you get 1 turn.
4. In the Ipo editor you can select the RotZ Ipo and switch to linear interpolation and extend Mode to cyclic.
5. Now you have an endless rotation around z.
6. Add an empty in the center of the z axis in top view(to make shure the empty is not rotated).
7. Make the empty the parent of the rotationobject.
8. You can now rotate the axis of your object with the empty and the rotation will keep clean around the empty (no wobbling).

Here is a test file, hope this helps:


rotate_axis.blend (161 KB)

Ah yes, now I understand, very clever, animating the object and afterwards applying the empty and rotating it as needed. Thanks a lot Patel, I’ll try it out this week-end and post if I encounter any more problems, but I have a feeling I won’t. :o Thanks again!