Selecting primitives

   1797   2   0
User Avatar
Member
28 posts
Joined: Sept. 2018
Offline
Hi guy's!

Probably a super easy solution to this, but I'm a bit stuck.

I'm looking for a node or a method to select an entire “mesh island” - just like double clicking on a mesh with the select tool. (just within a bounding box)


Here's an example, I don't want the “floating blob” to be selected, but I want the rest of the island to be selected.

if the image preview doesn't work click here [www.dropbox.com]


Thanks!
Edited by johanbogeberg - May 29, 2019 03:20:57
User Avatar
Member
899 posts
Joined: Feb. 2016
Offline
hello you want to use the connectivity node, that creates an int attribute with the same value for connected primitives.
Then you can loop through the connected pieces with a for loop and measure their area.

There is the “delete small parts” tool in the gamedev toolset that does exactly that:
Delete Small Parts
Utility SOP to remove small disconnected parts based on a size threshold

cheers
User Avatar
Member
28 posts
Joined: Sept. 2018
Offline
Thanks! That fixes my problem. But it would also be nice to know how to select all the primitives that share the same name - and one or more of those are within a bounding box/selection mask. Would I need to wrangle this, or is there any existing nodes that's useful?

Thanks!
  • Quick Links