Jump to content

How can line blend match surface?


aoisaki

Recommended Posts

You can do a couple things depending on how far away the lines are from the surface to begin with. Easiest way is to ray them to the surface.

First make sure the surface you want the lines to adhere to has normals. Then transfer the normals to the lines. Doesn't matter how you transfer them really, vops, wrangle or even just a attrib transfer is likely fine. Once you have them transferred, invert the normals so theyre pointing in the direction of your mesh. Then you can use a ray sop to move the lines along that normal direction. 

If the ray doesn't move the lines its because the normal length isn't long enough to reach the surface. You can just multiply your normals by a constant of 10 or whatever to get them long enough to reach the surface of your mesh.

If you have a really high frequency mesh with a lot of detail this solution is likely not going to give you what you want but try this first and if it needs to be more accurate there are other ways we can talk about.

Link to comment
Share on other sites

14 hours ago, BRZ32 said:

You can do a couple things depending on how far away the lines are from the surface to begin with. Easiest way is to ray them to the surface.

First make sure the surface you want the lines to adhere to has normals. Then transfer the normals to the lines. Doesn't matter how you transfer them really, vops, wrangle or even just a attrib transfer is likely fine. Once you have them transferred, invert the normals so theyre pointing in the direction of your mesh. Then you can use a ray sop to move the lines along that normal direction. 

If the ray doesn't move the lines its because the normal length isn't long enough to reach the surface. You can just multiply your normals by a constant of 10 or whatever to get them long enough to reach the surface of your mesh.

If you have a really high frequency mesh with a lot of detail this solution is likely not going to give you what you want but try this first and if it needs to be more accurate there are other ways we can talk about.

Thank you very much ! Ray is working great , but after let line match surface, I want to animate line to scale and rotation ,  It not work well......

So I try to use vop to compare point position to surface , But My lager problem is how to blend the line , Don't want the line it's straight,hope it will flow the surface and bending when line animation is happen.

Link to comment
Share on other sites

So unfortunately the ray sop is only looking for nearest points not for surface positions. Thus you get a lot of snapping and jumping when you animate the line. Your best bet for animating the line along the surface is to use the xyzdist function to find the actual surface position and blend to that.

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.

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