Hi,
I am a new bie in the world of Bullet Physics. I have applied Internal Edge Utility in my project as per the bullet physics example demo "AppInternalEdgeDemo".
When I quit my project,I am getting memory leak error in following part of the code:
btTriangleInfoMap* triangleInfoMap = new btTriangleInfoMap();
btGenerateInternalEdgeInfo(trimeshShape,triangleInfoMap);
I don't have any idea how to delete( i.e. free memory) this triangleInfoMap object.
Please give your valuable suggestions...
Regards
huRRc@ne
Memory leak problem after applying "Internal Edge Utility"
-
- Posts: 3
- Joined: Fri Nov 25, 2011 6:15 am
-
- Posts: 10
- Joined: Sun Apr 29, 2012 3:22 pm
Re: Memory leak problem after applying "Internal Edge Utilit
I do this, before I delete my btBvhTriangleMeshShape collision shape
pTriangleInfoMap= static_cast<btBvhTriangleMeshShape*>(pShape)->getTriangleInfoMap();
delete pTriangleInfoMap;
and after this I delete my collision shape
pTriangleInfoMap= static_cast<btBvhTriangleMeshShape*>(pShape)->getTriangleInfoMap();
delete pTriangleInfoMap;
and after this I delete my collision shape