Jump to content

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 ?

Link to comment
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.


I'm just making a wild guess here :D  


Link to comment
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 :) 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...