btDiscreteDynamicsWorld 16 aligned
Posted: Wed Jan 07, 2015 2:40 pm
I'm using bullet physics for a longer time. I always used it in MS Visual Studio 2010. For a while i downloaded MS Visual Studio 2013. It took a while to set it up, but now i can use bullet in 2013 as well. But now, when i build my project i get warning:
warning C4316: 'btCollisionDispatcher' : object allocated on the heap may not be aligned 16
warning C4316: 'btDiscreteDynamicsWorld' : object allocated on the heap may not be aligned 16
Why haven't i got this warning in 2010? Do i really have to align them? I tried to put:
inside btDiscreteDynamicsWorld and btCollisionDispatcher but then my application crashed with assertion _BLOCK_TYPE_IS_VALID(pHead->nBlockUse).
warning C4316: 'btCollisionDispatcher' : object allocated on the heap may not be aligned 16
warning C4316: 'btDiscreteDynamicsWorld' : object allocated on the heap may not be aligned 16
Why haven't i got this warning in 2010? Do i really have to align them? I tried to put:
Code: Select all
void* operator new(size_t i)
{
return _mm_malloc(i, 16);
}
void operator delete(void* p)
{
_mm_free(p);
}