add btFileUtils::toLower to convert a string (char*) to lower case
URDF import demo: add COLLADA .dae file support add FiniteElementMethod demo, extracted from the OpenTissue library (under the zlib license) don't crash if loading an invalid STL file add comparison with Assimp for COLLADA file loading (disabled by default, to avoid library dependency) Gwen: disable some flags that make the build incompatible
This commit is contained in:
@@ -41,7 +41,15 @@ static GLInstanceGraphicsShape* LoadMeshFromSTL(const char* relativeFileName)
|
||||
|
||||
if (numTriangles)
|
||||
{
|
||||
|
||||
{
|
||||
//perform a sanity check instead of crashing on invalid triangles/STL files
|
||||
int expectedBinaryFileSize = numTriangles* 50 + 84;
|
||||
if (expectedBinaryFileSize != size)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
}
|
||||
shape = new GLInstanceGraphicsShape;
|
||||
// b3AlignedObjectArray<GLInstanceVertex>* m_vertices;
|
||||
// int m_numvertices;
|
||||
|
||||
Reference in New Issue
Block a user