Jump to content
CinnamonMetal

Loop over primitives based on their position etc ?

Recommended Posts

How can I loop over primitives based on their Translate,Rotate,Scale,Shear position ?

In other words, suppose you have numerous meshes you can return their Translate,Rotation,Scale,Shear but you can't explicitly loop over the primitives of the mesh as you only have their Translate,Rotate,Scale,Shear ?

Share this post


Link to post
Share on other sites

Hey man,

Assuming you have access to all the meshes, could you construct a transformation matrix from the values of Translate, Rotate etc that you have and compare with the transformation matrix of all your meshes and get the ones that match and loop over the prims then ?

You could use the maketransform function to construct the matrix from the Translate, Rotate values you have.

http://www.sidefx.com/docs/houdini/vex/functions/maketransform.html

I'm just making a wild guess here :D  

-J

Share this post


Link to post
Share on other sites

@animknight That is an idea.  I only have float values to work with, returned from the Translate,Rotation,Scale,Shear & pivot position of the mesh.   The makeTransform() function requires vectors for it's arguments; how would I work with float values within the function ?

I think it's a doable plan, getting the pieces together is what I hope to get some help on :) 

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

×