Message 1 of 2
Error in SubDMesh.GetObjectMesh()

Not applicable
04-16-2016
11:09 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi
I have the following code to extract the geometry for Nurbs surfaces...
double size = nurbSurface.Bounds.Value.MaxPoint.DistanceTo(nurbSurface.Bounds.Value.MinPoint); MeshFaceterData mfd = new MeshFaceterData(); mfd.FaceterMeshType = 2; // triangle mfd.FaceterMaxEdgeLength = size * m_FaceterMaxEdgeLength; MeshDataCollection md = SubDMesh.GetObjectMesh(nurbSurface, mfd);
The scene at https://www.dropbox.com/s/3d7dfed45yc1t2g/nurbs%20surface.dwg?dl=0 contains a Nurbs Surface, which when using the above code in AutoCAD2014 results in 52 vertices, and you can see the exported result on the left is correct.
However, in AutoCAD 2015, 2016 and 2017 the GetObjectMesh() call appears to be returning corrupted geometry - with only 46 vertices, and you can see the vertex indexes appear to be wrong.
This appears to be a serious bug in the GetObjectMesh() function. As there a way around this pls?
Thanks
Paul