Jump to content

Inverse Of Copy's Rotate To Normals In Vex How?


lisux

Recommended Posts

Hi all.

I want to make a VEX SOP that make the inverse of the Rotate to Normals option in the Copy SOP.

So after the Copy (with Rotate to Normals enabled) I can transform every geometry point in the copied geo like if the Copy had disabled the Rotate to Normals option.

I have tried several transformation methods but I heven't the correct result.

Can anyone help me?

Thanks

Link to comment
Share on other sites

Just to understand the problem a little more why does just leaving rotate to normal off not work?

Because I need the original geometry copied to the points in shading.

I am using some 3d textures that have been created in world origin, using the fluffy clouds shaders, I want to use these to shade some spheres copied to a particle system.

So prior to scan in the 3d texture I have to move the points to the origin, I have done this saving the particles position in an attribute and using this to move every point in the shader to their original position.

But now the problem comes with rotation, the rotate to normal option is useful because it orient your spheres to the velocity (normal) direction of the particles, very useful to get a correct motion blur, but again, if the copy SOP rotates the incoming geometry to orient it to the template point normal, I need to do the oposite in shading to get the original geometry.

I have saved the normals of the particles in an attribute to use it in the shader.

My problem is how to get the invert transformation made by Copy SOP when you enable the Rotate to Normal option, with this I can move points to their original position and viceversa.

So to conclude, I am rendering geometry copied to a particle system, but every piece of geometry copied to the particles are shaded like if it hasn't been copied to a particle, are shaded in the world origin like it have been just created, so I invert the transformation made by the copy SOP to shade my geometry.

Hope now it is a little more clear.

Link to comment
Share on other sites

  • 4 weeks later...

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.

Guest
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...