Returning vertical surfaces which face my building



As a way to simplify some of my site context surfaces - i want to be able to just list out the surfaces which directly facing my building.
in the screenshot attached, i want return the surfaces within the red areas as these are all i need. Any suggestions - i tried geometry intersect by creating lines out from the building but this is quite limiting as it only return true or false.


That true/false could be used to filter the selection set with a filter by booo mask node. It would also grab bays pointing perpendicular to your building as well though - IE the face of the building looking towards the building across the street and roof planes. Extruding the surfaces may be a better option.

Get your property lines or building perimeter, offset them by your chosen level of tollerance, create a polycurve from them, and extrude them to a height greater than the context. I would go with property lines if you can as they will usually be simpler and therefore faster - you are about to do a lot of tests and simpler shapes will make life better here.

Break the context down into faces and extrude the faces by the maximum distance from the site you are interested in - could be street width times two as one method. Use a geometry.intersects node on the site extrusion and the list of extruded context surfaces. Then use the resulting list of true/false to filter your original list of context surfaces and you will have the correct faces.


Thanks for that. Extruding the surfaces was a good shout. Depending on the tolerance i get various amount of surfaces returned.
Is there a way to only return the first surface which intersects with the building extrusion? or perhaps a different way to accomplish this?


I think if you solve it by line | context intersection it will be faster. Here is how I would do it.

  1. Find the bounding box of your building and scale it in Z to be higher than the context.
  2. From the center of each face in the context find the closest point on the bounding box.
  3. Draw the line between the two and scale it back a little bit not to intersect with the building itself.
  4. Intersect the line with the context, if there is no intersection keep the face, otherwise it’s blocked with another surface.

This will not work for complex geometries but should work fine for your case. The center of the surface is not the best representation of the face. You can evaluate the surface and generate more points if you want to get a more accurate results.


@Mostapha’s method works well too. And I’m some cases is much faster, but I avoid it as I feel it can be inconsistent. A single ray center point hasn’t worked for me more often than it has in my previous project applications, and producing the right number of points for frustrating real quick, so I typically use ALL points (extruded surface) and called it a day.

Atkins can you post a screenshot of what you have and/or your source or test files so we can see the issue you’re talking about?


i am currently exploring @Mostapha’s solution - i have got the bounding box / points generated. i am struggling to implement finding the closest points and then the doesintersect.
i am just cleaning up the revit model and dynamo file so i will be able to share that shortly.


You might also be able to use the same logic as found here:

You can get a surface that maps the closest intersection from your building and use the perimeter to intersect with vertical surfaces.

Just an Idea.