2D boundaries of a multiple 3D objects (solid)

Is there any dyanmo script that can extract the 2D boundaries (in XY plane) of a 3D Solids?

As an input in my case i have multiple solids coming from corridor (with road layers) and it is a huge pain that i have to extract feature lines from corridor and then correct them manually for each solid group (it takes ages).

Yep, here’s one way, its the sledge hammer approach but it will work:

  1. Extract all faces
  2. Filter by face normal and only retain the faces which are visible from plan view
  3. Extract the edges of each face and compare the mid point to the mid point of all other face edges. If you find a coincident point, that edge is an interior edge and can be omitted. If there is no coincident point, its has to be a perimeter edge.
  4. Once you have collected all edges which meet this condition - i.e. only perimeter edges, you can project them onto a plane.
  5. Join curves.

This is a quick but inefficient approach. You could optimise it quite easily but writing a method (using nodes - which ever is your preference) which finds the surrounding faces so you only do the brute-force part with a discreet set. If you code it, use a stack (in C# - if Python, its just a list) and pop the coincident edges so you don’t end up process coincident edges twice.

1 Like

I am not that advanced programmer, so i have to use nodes given within dynamo library. How to filter faces which are visible from plan view?

@Dmnick.pl have you considered using SOLPROF ? https://knowledge.autodesk.com/support/autocad/learn-explore/caas/CloudHelp/cloudhelp/2018/ENU/AutoCAD-Core/files/GUID-080247BF-BDAB-49F6-A0A5-966412CEDCE9-htm.html

Solids.dwg (679.7 KB)

1 Like

I didn’t know that tool. It works really good, but do you have any idea how can i clear the drawing afterwards to get rid of “internal” lines?

@Dmnick.pl did you remove the tangential edges during creation? this should clean the linework considerably. Then some manual cleanup might be necessary and at that point you might consider using Dynamo. Can you share the intermediate result you got?

I didn’t remove them, because i need that jagged curves (later on i use them to create one big trimming solid).

So from this one:

I’ve used Solprof and recieved 2D blocks.

Accuracy is spot on, which is very promising, but since i need only the very outline i need to get rid of all the internal lines. On the image below i have marked the brown polyline which i want to extract from those blocks.

I have tried to explode the blocks and remove unnecessary lines, but some of them are tiny and it is a really difficult job to do it manually.

As the result i want to have one boundary polyline for whole intersection.

@Dmnick.pl thanks for the clarification, I think you should do create a dedicated SOLPROF with no tangential edges for this purpose, you can use Dynamo then. In essence, extract th geometry from the block references (2d lines), create a PolyCurve by joined curves, create Surfaces by Patch, create a PolySurface by joined surfaces, extract the unconnected boundaries (a set of PolyCurves) and then send the PolyCurves to AutoCAD as Polylines.

1 Like

I will try this approach and report back.

So, if i use Solprof without tangential edges and in addition to it i split it into two layers (hidden lines) the result looks much better (below).

Another problems pops out when i try to do anything in Dynamo. As you can see on the screen it is one block reference which i think is the reason of further problems. I have exploded the block reference manually in Civil 3d and used Mapclear command to break the lines if they intersect with eachother.
So, as the result i have bunch of lines which are not usable :confused:

Create hatches, then you will get actionable objects with the workflow I previously suggested.

I’ve created hatches, but the are not processable aswell. I am using Civil 2020.2.

Should i explode it first?

you can use the Civil 3D Toolkit and extract the hatch boundaries


1 Like

Unfortunately my geometry is too complex i guess.

Here is an example input which i use:Solprof example.dwg (937.9 KB)