Calling layer information from AutoCAD import

Hello,

We have a project where the topography changes constantly through design iteration and I’m trying to find a way to streamline the topography process by directly using polylines from CAD that a consultant gives to us to generate topography instead of having to remake or edit topography points manually one by one.

However, I’ve run into an issue with some limited functionality on CAD imports into Revit. Please see a screenshot of the definition below for clarification:

topo

 

 

 

 

So basically I’m taking a CAD import, extracting polylines, and breaking them up into points to create a topo from that. While I could make the autocad import file a 3D file (i.e. move the polylines into their desired z locations and then import into Revit), I’d rather place them into separate layers named for their height (i.e. polyline for topo height 5 is on a layer named “5”) and then call this to use as a z-coordinate as I think this would be easier to understand for future users.

For the purposes of this example, what I’ve done is instead substituted a simple translate in the z direction for the polylines to simulate the functionality I’d like to achieve.

My question is, is there any way to call identity information for CAD imports (such as layer names of objects) into a dynamo definition? Would I have to use Python for this?

Thanks!

As far as I know, the layer information is not exposed in the Revit API. What you could do is import the DWG (not link it). Although importing is generally a bad idea, in this case it would allow you to explode the DWG. Once you’ve done that, layers should have become line styles - great way to clutter up your project, but now you can identify the lines by their line style names.

My personal opinion: Don’t do this. Let an intern change the Z coordinates of the polylines in AutoCAD (at least it’s more exciting than making coffee) or have someone AutoLISP this problem away. And keep your Revit file clean…

I agree with Andreas. Importing CAD into Revit is bad, but exploding it is REALLY BAD.

Andreas, this is America. Intern is just a code name for cheap labor. They are expected get shit done. :slight_smile: Besides, its probably more reasonable to expect them to adjust some Z values then to get my Latte right. :slight_smile:

Jerry,

Have a look at that: http://archi-lab.net/topo-tools-for-dynamo/

If you can get lines, maybe you can get points as well? Maybe you can get a list of points and then just create a Topography from it. That will be a far more viable solution that what is being discussed above.