About the Author

May 2014

Sun Mon Tue Wed Thu Fri Sat
        1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31

Autodesk Blogs

« RSS Feed Problems | Main | Lunch Break: Translating Source Code »



Feed You can follow this conversation by subscribing to the comment feed for this post.



I try to find .net functions similar to IAeccSurface.ExtractBorder and IAeccSurface.ExtractContour, but without success. I see in Demo you use SurfaceDisplayStyleType class wich also contains components that can be extracted http://docs.autodesk.com/CIV3D/2012/ENU/filesCUG/GUID-8CEA1A8B-4433-4B18-9185-1EE3D5E29BA-886.htm
But SurfaceDisplayStyleType is for styles, is there any class for extracted objects?

Isaac Rodriguez

Hi quiz,

There were some issues that prevented us from implementing that functionality in .NET. We are working on resolving those issues, so we can provide that functionality.

As it is right now, you will still have to use the COM interfaces to access the functionality. You can still use .NET for that through the interops, and the 'Surface' object should have an 'AcadObject' property that returns a COM instance of the object that can be casted to an IAeccSurface from which you can access the methods you need.


I spent the time converting our existing Civil 3D surface code from COM to NET. The one missing method I use a lot is SampleElevations on the COM surface object. I asked ADN if I missed something and I ask you as well. Is this functionality there but different?


Thank you for you answer, Isaac!
I recently discovered a strange behavior of IAeccSurface.ExtractContour function. I'm trying to find intersection of two surfaces, for this I'm building volume surface and extract contour from 0 level. When set first surface for 'base' and second for 'comparison' I have for example 2 contours, when set second surface for 'base' and first for 'comparison' I have only 1 contour. Is this connected with your issue?

Isaac Rodriguez


The SampleElevations functionality was also taken out of scope because of change in the requirements. Basically, we wanted to provide a new interface that solved the issues we had with the COM API. In reality, the current interface exposes the necessary functionality to implement the feature, but I think that if it is a widely used feature, it should be provided by the API.

Isaac Rodriguez


The results should be the same no matter what base you are using. If you can send me your data set, I can take a look at it to see why you are getting different results. Send me a direct e-mail with your drawing attached and the subject prefixed with 'BLOG:', and we will research this issue if we can reproduce it.

It may take a while though.



I send you email with example drawing, source code with IAeccSurface.ExtractContour usage, compiled bundle and output files (BlackSurface-RedSurface.txt and RedSurface-BlackSurface.txt).

The comments to this entry are closed.