Extracting only rows of edges from a mesh

   1564   2   0
User Avatar
Member
30 posts
Joined: April 2015
Offline
Hi everyone!
I am trying to extract all "long" lines from this alembic mesh



My first assumption was to somehow use the fact that they go along the U coordinate.



I used a simple expression to store the original position and convert this mesh to a "UV grid"
v@PStore = @P;
@P = @uv;



This made things look easier but I still couldn't figure out how to keep only the horizontal lines.
So I wrote a script that would delete the vertical ones based on their length since I was lucky that all of them had a larger @restlength.



In the end after restoring the @P to the one I stored earlier I achieved the result but I am sure that there is a more elegant way to select only the "U" prims.


I would appreciate any pointers on a more logical way to achieve that result.

Thank you
Edited by Robot_and_Robot - Dec. 6, 2022 06:44:20

Attachments:
h_SPS_05.png (2.7 MB)
h_SPS_01_Edges_Manually.jpg (456.8 KB)
h_SPS_02.png (3.2 MB)
h_SPS_03.png (3.1 MB)
h_SPS_04.png (2.9 MB)

User Avatar
Staff
327 posts
Joined: July 2005
Offline
Take a look at the Group Find Path SOP. It can likely simplify this task. Attached is an example of a mode that may be helpful for this task.

Attachments:
groupfindpath-example.hip (107.9 KB)

User Avatar
Member
30 posts
Joined: April 2015
Offline
derrick
Take a look at the Group Find Path SOP. It can likely simplify this task. Attached is an example of a mode that may be helpful for this task.

Great! Thank you so much!
  • Quick Links