allow the Bullet world importer to save a copy with swapped endianness

See http://bulletphysics.org/Bullet/phpBB3/viewtopic.php?f=9&t=8191
This commit is contained in:
erwin.coumans
2012-10-31 07:25:54 +00:00
parent ff38230704
commit 595dab2337
5 changed files with 315 additions and 21 deletions

View File

@@ -37,12 +37,18 @@ btBulletWorldImporter::~btBulletWorldImporter()
}
bool btBulletWorldImporter::loadFile( const char* fileName)
bool btBulletWorldImporter::loadFile( const char* fileName, const char* preSwapFilenameOut)
{
bParse::btBulletFile* bulletFile2 = new bParse::btBulletFile(fileName);
bool result = loadFileFromMemory(bulletFile2);
if (preSwapFilenameOut)
bulletFile2->preSwap(preSwapFilenameOut);
delete bulletFile2;
return result;