StlMesh: Bug in AddOnlyNewVertex


I have found a bug in ..

//function : AddOnlyNewVertex
//design : Adds the vertex only if X and Y and Z doesn`t already exists.
Standard_Integer StlMesh_MeshDomain::AddOnlyNewVertex(const Standard_Real X,
const Standard_Real Y,
const Standard_Real Z,
Standard_Boolean& IsNew)

The method *always* inserts a new vertex. IsNew returns constantly "true".

How can I fix this?


Forum supervisor's picture

Dear Thorsten,
I suggest you to register the specified issue in Mantis Bugtracker which is available via the Collaborative portal -
You are also welcome to develop a corresponding patch and make a contribution via the Collaborative portal -
Best regards

Thorsten H's picture

I searched Mantis Bugtracker...

"It seems that the AddOnlyNewVertex method in the StlMesh_MeshDomain class does
actually add the vertex each time. It does not check, if the vertex is already
included in the vertexCoords sequence. This produces models with a huge number
of vertices (number of triangles * 3)."

Date submitted: 2007-10-25 14:50
Status: New

Seems to be a hard-recoverable bug. I don't think I am able to fix this. :-/