Orient Pivot points between two objects on an axis.

Orient Pivot points between two objects on an axis.

deven.saxenaP7BD5
Enthusiast Enthusiast
93 Views
4 Replies
Message 1 of 5

Orient Pivot points between two objects on an axis.

deven.saxenaP7BD5
Enthusiast
Enthusiast

Hello,

Edit: Need to get this done via code. Maxscript or python.

Whats the best way to orient an axis of a selected object in a scene with that of another object. 

So for example, Match the x-axis orientation between a source and a target object. Keeping the other axis untouched. 

 

0 Likes
94 Views
4 Replies
Replies (4)
Message 2 of 5

A娘
Advocate
Advocate

set axis should reset all axes , if not , you will get an non-orthogonal matrix , your model become stretched

0 Likes
Message 3 of 5

miauuuu
Collaborator
Collaborator

Check out this script: https://miauu-maxscript.com/portfolio-item/miauus-align-pivot-to-direction/

It is open source, so you can see how the direction between two points can be used to orient any axes of the pivot. You can adapt it to work with any vector(direction).

https://miauu-maxscript.com/
0 Likes
Message 4 of 5

casey_hawley
Advocate
Advocate

I think I understand what you need. One object needs to have the same pivot orientation as another object.

 

Use the 'Align' tool casey_hawley_0-1758036025519.png , or Tools > Align, or ALT + A.

 

To use, select the object that has wrong axis, activate the Align tool and click the object to match it to. A set of options for the function opens. The options are straightforward. It can match several things at once, or just one. It can match Move, Rotation, and Scale, or just match up the pivots. There is a small limitation when the two pivots are mismatched in Local (e.g. the "back" of one is on the Y while the back of the other is on the X) but is easily overcome with an extra manual step or two.

 

The Insert key (or INS) will access pivot only mode for manual adjustments. Sometimes I simply note the numerical orientation from one object, then manually type in the matching number in pivot mode.

0 Likes
Message 5 of 5

denisT.MaxDoctor
Advisor
Advisor

The task does not make sense as it is formulated. There is no practical sense in aligning a single axis. The coordinates of the node must remain orthogonal, which means that when one axis is rotated, it must affect the others.
Try to explain more clearly what you need, draw a picture if it helps.

0 Likes