cleaned up, removed warning under MSVC2005 (Level 4)

Mostly related to alignment and unused variables
This commit is contained in:
ejcoumans
2007-04-13 01:37:21 +00:00
parent 2cf026aae3
commit bc3f9535ad
71 changed files with 348 additions and 125 deletions

View File

@@ -55,6 +55,7 @@ public:
pointer address ( reference ref ) const { return &ref; }
const_pointer address ( const_reference ref ) const { return &ref; }
pointer allocate ( size_type n , const_pointer * hint = 0 ) {
(void)hint;
return reinterpret_cast< pointer >(btAlignedAlloc( sizeof(value_type) * n , Alignment ));
}
void construct ( pointer ptr , const value_type & value ) { new (ptr) value_type( value ); }

View File

@@ -26,12 +26,12 @@ template <typename T>
//template <class T>
class btAlignedObjectArray
{
btAlignedAllocator<T , 16> m_allocator;
int m_size;
int m_capacity;
T* m_data;
btAlignedAllocator<T , 16> m_allocator;
protected:
SIMD_FORCE_INLINE int allocSize(int size)
{

View File

@@ -31,12 +31,7 @@ struct btDefaultMotionState : public btMotionState
m_graphicsWorldTrans = centerOfMassWorldTrans * m_centerOfMassOffset ;
}
///Bullet gives a callback for objects that are about to be deactivated (put asleep)
/// You can intercept this callback for your own bookkeeping.
///Also you can return false to disable deactivation for this object this frame.
virtual bool deactivationCallback(void* userPointer) {
return true;
}
};

View File

@@ -176,7 +176,7 @@ class btMatrix3x3 {
void getRotation(btQuaternion& q) const
{
btScalar trace = m_el[0].x() + m_el[1].y() + m_el[2].z();
float temp[4];
btScalar temp[4];
if (trace > btScalar(0.0))
{

View File

@@ -34,10 +34,7 @@ class btMotionState
//Bullet only calls the update of worldtransform for active objects
virtual void setWorldTransform(const btTransform& worldTrans)=0;
//future: when Bullet makes attempt to deactivate object, you can intercept this callback (return false to disable deactivation for this object this frame)
virtual bool deactivationCallback(void* userPointer) {
return true;
}
};
#endif //BT_MOTIONSTATE_H