nicholasds Posted October 22, 2018 Share Posted October 22, 2018 Hi all Can anyone suggest a good way to loop over geo and group connected geo by a threshold of primitive count? For eg. - I have a mesh that has 140 000 000 prims. - I can do a connectivity sop and split out connected pieces. Many are smaller than my threshold of say 10 000 000. - I'd like to combine the smaller connected pieces into a group until it hits the 10 000 000 threshold and then move onto a new group etc. Right now it creates far too many individual meshes based purely on connectivity so I'm trying to combine the smaller pieces into a more manageable chunks. Thanks in advance! Quote Link to comment Share on other sites More sharing options...
konstantin magnus Posted October 22, 2018 Share Posted October 22, 2018 If you are dealing with that large amounts of data, you may want to look at packed primitives and possibly avoid grouping. http://www.sidefx.com/docs/houdini/model/packed.html Quote Link to comment Share on other sites More sharing options...
animatrix Posted October 22, 2018 Share Posted October 22, 2018 Hi, You can use Connectivity SOP to create a primitive attribute and then in an AttribWrangle in Primitive Run Over mode, use findattribvalcount function to count how many primitives belong to each connected piece of geometry and group them based on your threshold. Quote Link to comment Share on other sites More sharing options...
nicholasds Posted October 22, 2018 Author Share Posted October 22, 2018 Thanks guys. I ended up using packed prims and using a point cloud lookup to group them together. Worked well. 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.