Community
Civil 3D Customization
Welcome to Autodesk’s AutoCAD Civil 3D Forums. Share your knowledge, ask questions, and explore popular AutoCAD Civil 3D Customization topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Selection by contours elevation

15 REPLIES 15
SOLVED
Reply
Message 1 of 16
F.Camargo
3604 Views, 15 Replies

Selection by contours elevation

Hi guys,

 

How are you?

 

I was trying to select a specific contour elevation at my surface.

And I finally learned a way to do that. Very nice!!

 

contours elevation.JPG

 

I was wordering if there is a faster way to do that.

Just like like a polyline, you can select a single contour.

 

contours elevation-polyline.JPG

 

I'd like to do that just for analyse my surface.

 

Thanks 

Fabricio

15 REPLIES 15
Message 2 of 16

If you select the surface the there is an option to extract objects from the surface. You can then use the drop down in the dialog box that shows up to select a particular contour to extract.

Civil Reminders
http://blog.civil3dreminders.com/
http://www.CivilReminders.com/
Alumni
Message 3 of 16


@Civil3DReminders_com wrote:

If you select the surface the there is an option to extract objects from the surface. You can then use the drop down in the dialog box that shows up to select a particular contour to extract.


Thanks for replay.

I'm looking for a better way to show the specific contours elevation by selecting the surface.
Maybe a code to do that. It will help me a lot!

 

Although I've never used any code for C3D yet. I don't know if is just like autolisp code.

 

Thanks
Fabricio

Message 4 of 16

I think you are looking for this: 

http://docs.autodesk.com/CIV3D/2016/ENU/API_Reference_Guide/html/6a085cdc-95d2-bab7-0a9b-a551f5ce606...

 

I don't know how to do this in Lisp, if you want to do this in .NET I like using the SincPac Source Code as a starting point. I haven't updated it in a while, but it would require updating the references.

http://quuxsoft.com/SincpacC3D_source.aspx

Civil Reminders
http://blog.civil3dreminders.com/
http://www.CivilReminders.com/
Alumni
Message 5 of 16


@Civil3DReminders_com wrote:

I think you are looking for this: 

http://docs.autodesk.com/CIV3D/2016/ENU/API_Reference_Guide/html/6a085cdc-95d2-bab7-0a9b-a551f5ce606...

 

I don't know how to do this in Lisp, if you want to do this in .NET I like using the SincPac Source Code as a starting point. I haven't updated it in a while, but it would require updating the references.

http://quuxsoft.com/SincpacC3D_source.aspx


Thank you!

@Civil3DReminders_com 

How Can I load that code?

 

Fabricio

Message 6 of 16

You will need Visual Studio. Information on how to load it into Visual Studio is located here:

http://blog.civil3dreminders.com/2010/05/sincpac-c3d-source-code.html

 

Once you compile the code you run NETLOAD at the command line and select the dll file that is in the bin folder. You can also create an App that will automagically load the dll for you:

http://through-the-interface.typepad.com/through_the_interface/2011/09/autodesk-exchange-preparing-y...

Civil Reminders
http://blog.civil3dreminders.com/
http://www.CivilReminders.com/
Alumni
Message 7 of 16

@Civil3DReminders_com, as far as I know that method is used to extract any contours that were used to build the surface. The OP is after contours that are generated by the surface after you have fed in the points, break lines etc. These contours are dynamically generated based on your design parameters for the surface and are not part of your surface itself. In other words, if you look under toolspace, surfaces, surfacename, definition, contours hold the data that the method will retrieve. However, this data is not populated based on your generated surface but this is the definition contour data.

@F.Camargo, see attached application. Minimal testing done. Hope it helps.

Message 8 of 16

The link above gets the contours from the built surface as the OP requires.

This is the property that describes what you indicate I provided
http://docs.autodesk.com/CIV3D/2016/ENU/API_Reference_Guide/html/985e148c-e5aa-eebd-6be0-80449768a72...
Civil Reminders
http://blog.civil3dreminders.com/
http://www.CivilReminders.com/
Alumni
Message 9 of 16


@Civil3DReminders_com wrote:
The link above gets the contours from the built surface as the OP requires.

This is the property that describes what you indicate I provided
http://docs.autodesk.com/CIV3D/2016/ENU/API_Reference_Guide/html/985e148c-e5aa-eebd-6be0-80449768a72...

You are correct. The above provided API Reference link will get the OP definition contours. Extcont.vlx will get him the resulting contours from the TIN definition irrespective of how the TIN was defined (with or without definition contours). 

Message 10 of 16

The call to ExtractContoursAt gets the contours of the built surface. It does not require any contours being added to the surface as a part of the surface definition.

http://docs.autodesk.com/CIV3D/2016/ENU/API_Reference_Guide/html/6a085cdc-95d2-bab7-0a9b-a551f5ce606...

 

Unfortunately you didn't provide the lisp code so I could modify it to show you how you can directly get the contour instead of looping through all of the contours of the built surface that I think you are doing. 

Civil Reminders
http://blog.civil3dreminders.com/
http://www.CivilReminders.com/
Alumni
Message 11 of 16
F.Camargo
in reply to: Ranjit_Singh1


@Ranjit_Singh1 wrote:

@Civil3DReminders_com, as far as I know that method is used to extract any contours that were used to build the surface. The OP is after contours that are generated by the surface after you have fed in the points, break lines etc. These contours are dynamically generated based on your design parameters for the surface and are not part of your surface itself. In other words, if you look under toolspace, surfaces, surfacename, definition, contours hold the data that the method will retrieve. However, this data is not populated based on your generated surface but this is the definition contour data.

@F.Camargo, see attached application. Minimal testing done. Hope it helps.


@Ranjit_Singh1

 

Thank you very much!!

 

Worked perfect, just like a charm. Smiley Happy

 

Fabricio

Message 12 of 16


@Civil3DReminders_com wrote:

The call to ExtractContoursAt gets the contours of the built surface. It does not require any contours being added to the surface as a part of the surface definition.

http://docs.autodesk.com/CIV3D/2016/ENU/API_Reference_Guide/html/6a085cdc-95d2-bab7-0a9b-a551f5ce606...

 

Unfortunately you didn't provide the lisp code so I could modify it to show you how you can directly get the contour instead of looping through all of the contours of the built surface that I think you are doing. 


@Civil3DReminders_com

 

I've installed Visual Studio 2017 and I'm trying to compile the code.

My english is not good and I don't understand how to paste the code into the visual studio.

 

But I don't give up.

 

 

I'm keeping trying and I let you if it worked.

 

Fabricio

 

 

 

 

Message 13 of 16
DisturbedCorner
in reply to: F.Camargo

This is exactly what I'm looking to do as well. I need to focus on a few contour lines of a generated and dynamic surface defined from field ties and break lines. I did not know about this method until I came upon this post, so this is my first time bringing up this interface. Here are the results:

DisturbedCorner_0-1716565106552.png

DisturbedCorner_1-1716565141765.png

As you can see, the default settings just hide the contour line instead of highlighting it. Quite the opposite of what I need.

I am running Civil 3D 2019.

Do I really need to run custom code and/or install Visual Studio to get this to do what I need it to do?

Was this built in to a later version of Civil 3D?

Message 14 of 16
hippe013
in reply to: DisturbedCorner

@DisturbedCorner  Are you looking to extract specific contours from your surface? 

Message 15 of 16
DisturbedCorner
in reply to: hippe013

I'm not sure what "extract" would be in this context. If it can pull a specified contour line or lines at an elevation and let me save that line(s) as a separate drawing, that would be good. Otherwise, if it would just let me change the color of a specific elevation of interest, that would work too.

Message 16 of 16
Jeff_M
in reply to: DisturbedCorner

@DisturbedCorner When you use the User-Defined Contours in the Surface properties, make sure the style you are using has the User Contours set to display:

2024-05-24_13-04-18.png

And if you want to see only those contours, turn off the Major and Minor contours.

Jeff_M, also a frequent Swamper
EESignature

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


 

Autodesk Design & Make Report