Jump to content

Center and align object on primitive

Recommended Posts

I'm looking for a way to to this with fewer nodes

Right now the right branch creates a point a the "center" ( approximation with primitive / scale=0) of the primitive blast1, and ensures that the resulting point has its normal set to the average normal of the primitive

Then I copytopoint the tube to this point and it's ready to be boolean subtracted to make the hole.

Is there a simpler setup that I could use, or some SOP that I could abuse in a way. MatchSize can almost do it but it would have to work in transformed space to match the primitive remaining in blast1,










Edited by AntoineSfx

Share this post

Link to post
Share on other sites

Do this in a prim wrangle to create the point:

int newpt = addpoint(0, @P); //create point in the center
setpointattrib(0, "N", newpt, @N); //Prim normal to N
removeprim(0, @primnum, 1); //Remove the original geo


  • Like 1

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now