Find Element near given point

Hello everyone. I want to create a script that find every geometry near a given point. Any suggestion?
Thanks :slight_smile:

Hello. Can you be more specific, are you saying you want to search through every single element in a project to see if it is near a point?

What have you tried so far? What works or doesn’t work?

Thanks for the answer. I want to find all elements of a particular category closest one point with specific coordinates. I’ve tried to create a sphere with a fixed diameter near my point and then intersect the geometry with it but the script doesn’t work.

You can use bounding box for that. Check the following screenshot.

In the end you can either use “bounding box intersect elements” (from bimorph nodes package), and select your pipe elements to find intersecting. Or you can use “bounding box contains” and feed it the points you already extracted from your pipe elements.



After the “All Elements of Category” node, add “Element.Geometry” and try again.
Please share the results with us.


1 Like


In the above suggestion, the bounding box isn’t a sphere so you might get odd outcomes.

The nice thing about bounding box is that it’s very robust. Element geometry gave me some fails here (admittedly ductwork but still :slight_smile: )

So I’d use a mix of the 2 suggestions… I would make a lot of use of the geometry preview when testing…

Hope that’s of interest.


The script is working perfectly! I have used BoundingBox.GetElementsIntersect node.
This is the result:


Through this I can identify the family connected to my Start/End point of pipe.
Thanks to everyone!

Glad it worked out for you! Don’t forget to mark the solution so that the thread is closed, and future readers can find it quickly.