Masoud Posted February 13 Share Posted February 13 Hi everyone, I'm working with a point cloud and trying to select the boundary (or inverse boundary) points using VEX, similar to the image below. My code works well when the points are not too close to each other, but I encounter issues when the points are very close, like in the image shown. int handle = pcopen(0, "P", @P, chf("Max_Radius"), chi("Max_Points")); v@getPositions = pcfilter(handle, "P"); float var = length(v@P - v@getPositions); if(f@density = var > chf('threshold')) { i@group_boundry = 1; } Does anyone have suggestions on how to address this? Thanks for helping. Select Boundary Points 02.hip Quote Link to comment Share on other sites More sharing options...
AntoineSfx Posted Sunday at 09:17 AM Share Posted Sunday at 09:17 AM Forget about pccloud, pcopen, pcfilter Triangulate the whole thing, convert to lines, remove the largest primitives according to length, triangulate2d again, this time with: Edges: * and Flood from Convex Hull Boundary. At that point you have a clean surface to work with. Then you just throw a group points / unshared edges + groupExpand OR Labs distance from border + group by distance Remember that in term of rebuilding the outer edge of the point cloud, every surface is basically correct, because the information is lost. Generally speaking, how do you know that the outer edge is not jagged (zig zag, made of lots a spikes) ? You can explore this concept here, https://doc.cgal.org/latest/Alpha_wrap_3/index.html Maybe one day it will be implemented in Houdini. 1 Quote Link to comment Share on other sites More sharing options...
Masoud Posted 22 hours ago Author Share Posted 22 hours ago Hi Antoine, Thank you for the tips and the link. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.