constraining objects movement

I know that you can constrain an object’s rotation by pressing x,y or z one or two times… Is there any way to achieve the same effect but with respect to movement (‘g’ key) instead of rotation?

Start moving along the axis of your choice and then cick the middle button to limit the tranformation to that axis. Works with scale also. Need some practice but I’m not even concious of using it anymore.

Yes, I am familliar with that. Perhaps I was not clear.

I want to constrain the movement not to the global axis, but the local axis of the object itself. In other words, if the object is tilted, it will move diagonally accross the global scene, but strait along its local x,y or z axis.

Perhaps I wished for something with a solution ?

No, I don’t think it’s possible.
I’ll be glad if somebody correct me.

As usual, answer is ‘It depends’

You can rotata a thingie aroud the axis perpendiculat to your 3D view, right?

So if you can have a look at the object from the axis of rotation you desire you would be happi :slight_smile:

Trick is that any thing can act as a camera, the object itself too!

So if you select the object, press CTRL + NUM 0 and then NUM 5 twice to get off perpective view you will be able to rotate the object arount its Z axis

For the other axis is less simple.

You can do this if you plan in advance.

Once your object is in an unrotated view place 3 empties, one along X axis, one along Y axis and one along Z axis at a distance with Z axis of each empty pointing to the object.

Then you have a view to the object from which you can rotate it.

(Is this helpful?)


Wow !
Almost devious.
Tend to proove that one can do just about anything in Blender.
It’s another matter altogether to want to do it sometimes.

Thanks Stefano.

P.S. How’s the workload with Elysiun now that you inherited of its maintenance ? Still have time to play with Blender ?

Well, it is certainly an interesting work around a potential rotation problem, and I like your creativity.

Trouble is, I want to constrain the objects movement.

Imagine a slide trombone for example. No matter what direction the horn faces, you always want the slide to move along one and only one relative axis. Easy if the trombone is pointing straight along the x,y or z, but difficult if it is not.

The only work around I can think of is to move the object and then go to the IPO window and delete the IPO’s for the unwanted directions. It would be much easier (and intuative) if you could just grab the object and have it’s movement in certain directions inhibited.

I used to use 3D Studio a long time ago (before it was “MAX” - does that say something about my age?) It had a feature where you could select which directions (local to the object) were available for movement. It was very handy indeed and saved a lot of hassle. I would love to see such a feature in Blender.

Oh good! That may proove to be much easier.

Make your animation of the sliding movement. Once satisfied, parent every object that have a part in it to the same empty and rotate/move/scale that parent as you as you need it : the animation will occur in reference to the local coordinates of the parent, not the global ones anymore.
With experience this is even more useful and time saving than the Max algorithm.

Yes, that would work very well. Problem is, I need to set the animation of the slide (not a trombone in this case) while the object is moving around. I think I’m just going to have to do it the hard way…

Thanks just the same for all your help people.

In this exemple,
all the animation has been set after the parts were parented to the empty.

Really, can you make me understand why you should go through any unnecessary trouble ? Besides, I can’t imagine how you find your way through a complex animation if you don’t use hierarchies… There has to be something I’m missing there…

OK, a blender file speaks a thousand words.

Your link is a nice example of parenting movement. Perhaps this file will help explain the kind of motion I am going for.

It is a less more random motion that needs to be restrained to the local “y” direction.

As far as we agree that this is not simply a case of moving the parent to animate the child but that it is animating the child directly with reference to the local coordinates of the parent, which itself may move or not : thank you.

Perhaps this file will help explain the kind of motion I am going for.

It is a less more random motion that needs to be restrained to the local “y” direction.

The motion in my example is less random than it may seem. the rod is “constrained” to pass through the center of the ring along its axis.

In short : no function, no button. I offered you a mean to create one that is many times more powerful : you might want to keep it in your bag of tricks when the going will get really complex.

I have a feeling that we work in ways that are not quite compatible. Myself, I’d rather create the IPO directly and manipulate it directly

Too bad.

I had to solve a problem like that for a rig of mine some time ago, and here’s what I did.

create two Empties
position one of the empty at the center of the object that you want to move (Empty 1)
position the other empty near the first one, but give it a little position offset along the line that you want the object to move, but in the oppisite direction (Empty 2)
parent Empty 1 to Empty 2
add a Copy Loc and Copy Rot contraints to the object you want to move pointing to Empty 1

now, you just have to scale Empty 2 to move the object.


theeth, you’re the man! You always seem to have creative solutions to problems.

I tried your set up and it works great: piston_02.blend

My goal remains to be able to grab the head of the “piston” and have the rest of the machine turn and rotate to keep everything lined up. I think the answer lies in using armatures so I’m trying that avenue. In the mean time, your solution is letting me get my work done much faster!


Theeth : do you think that you could explain the blenderian psychology to me?
You go trhough a complicated construction to achieve what can be done by adding one point to one IPO that will exist anyway ; fine tuning is a simple question of moving that point on the IPO with immediate feedback in the 3D window. Plus, not having any real constraints, one is free to expand the design without adapting the contraption.

What determines the choice for the more complicated solution ?

Don’t get me wrong : this is not a pissing contest. I was quite desperate for an answer that would agree with bob_dog ways and can only rejoice that he’s found what he was after. My motivation is that, as a tutorial author, I need to offer answers that a majority can use. So if you could only give me a clue to what make you choose one way rather than another it may proove to be of great service to many.


The IPO solution only works if the IPO curves are created when the object’s axis are aligned with the global axis. If you create the IPOs after the object is rotated, the Loc X, Y, Z curves will no correspond to the local axis.

So, it’s merely a matter of forethought. If you plan in advance, yes, the IPO solution works great, but personnally, I prefer to work with control objects rather than with IPOs (ie, the empties can be replaced by bones if that solution needs to be applied to armatures, which makes it NLA compatible).


Thanks Theeth.