Added some improvements on Bullet serialization:
Introduced generated unique id's, instead of the pointer address to avoid 64bit->32bit truncation issues Use serializer->getUniquePointer instead of directly using a pointer moved ChunkUtils::getNextBlock to bFile::getNextBlock. Moved 'TEST_BACKWARD_FORWARD_COMPATIBILITY' to bDNA.cpp. Enable the define for further testing of .bullet format Removed duplicate definitions and use the one in LinearMath/btSerialization.h
This commit is contained in:
@@ -34,7 +34,10 @@ namespace bParse {
|
||||
bChunkPtr4(){}
|
||||
int code;
|
||||
int len;
|
||||
int old;
|
||||
union
|
||||
{
|
||||
int m_uniqueInt;
|
||||
};
|
||||
int dna_nr;
|
||||
int nr;
|
||||
};
|
||||
@@ -45,7 +48,11 @@ namespace bParse {
|
||||
public:
|
||||
bChunkPtr8(){}
|
||||
int code, len;
|
||||
long64 old;
|
||||
union
|
||||
{
|
||||
long64 oldPrev;
|
||||
int m_uniqueInts[2];
|
||||
};
|
||||
int dna_nr, nr;
|
||||
};
|
||||
|
||||
@@ -64,8 +71,6 @@ namespace bParse {
|
||||
class ChunkUtils
|
||||
{
|
||||
public:
|
||||
// buffer offset util
|
||||
static int getNextBlock(bChunkInd *dataChunk, const char *dataPtr, const int flags);
|
||||
|
||||
// file chunk offset
|
||||
static int getOffset(int flags);
|
||||
|
||||
Reference in New Issue
Block a user