XM Magdalena 3D print, GGeorgy (3D)
LC #42 Pipers Alley

View Full Version : Query the normal of a vertex

01-24-2011, 09:48 PM
I know you can easily query the position of a vertex using the pointPosition command.

Is there an easy way to query the normal of a vertex?

01-24-2011, 09:57 PM
use the polyNormalPerVertex command. e.g:

polyNormalPerVertex -q -xyz pcube1.vtx[0];bear in mind that a single vertex can have multiple different normals. you can query the .vtxFace if you need a more specific normal.

01-24-2011, 10:05 PM
ok awesome. Is there a way to then snap align an object to this normal?

i guess i should clarify what im trying to do.

Id like to be able to select a vert or verts. and have it create a nurbs plane aligned to the normal and the position of the object.

pointOnPolyConstraint wont work for me because it needs to be UV'less,

01-25-2011, 12:37 PM
there is possibly a way to do this using a node network so it's dynamic, but the way I would tackle this is to get your normal vector and a position (whether this is the vertex postion or the object center or whatever, some position should be easy to get) and then simply construct an object matrix from these two things, using xform to apply it to your NURBS plane or whatever.

do you know how to construct a matrix from a single vector? just shout if you need more info on this.

01-25-2011, 05:29 PM
yes, i am very newbie at these things, but am reading as much as i can to learn. Any info you could send my way would be much appreciated.

CGTalk Moderation
01-25-2011, 05:29 PM
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.