From 745b3d4e05ba144f5ad3ab7323062a798d073df5 Mon Sep 17 00:00:00 2001 From: "erwin.coumans" Date: Tue, 20 Jul 2010 01:09:34 +0000 Subject: [PATCH] fix some warnings, see Issue 400 --- .../BulletWorldImporter/btBulletWorldImporter.cpp | 2 +- src/BulletCollision/CollisionDispatch/btGhostObject.h | 2 +- .../ConstraintSolver/btSolverConstraint.h | 4 ++-- .../ConstraintSolver/btTypedConstraint.h | 2 +- src/BulletMultiThreaded/MiniCL.cpp | 2 +- src/BulletMultiThreaded/PlatformDefinitions.h | 2 +- src/BulletMultiThreaded/btParallelConstraintSolver.cpp | 10 +++++----- src/LinearMath/btHashMap.h | 2 +- 8 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Extras/Serialize/BulletWorldImporter/btBulletWorldImporter.cpp b/Extras/Serialize/BulletWorldImporter/btBulletWorldImporter.cpp index cc33b5db0..07a20eeff 100644 --- a/Extras/Serialize/BulletWorldImporter/btBulletWorldImporter.cpp +++ b/Extras/Serialize/BulletWorldImporter/btBulletWorldImporter.cpp @@ -446,7 +446,7 @@ char* btBulletWorldImporter::duplicateName(const char* name) { if (name) { - int l = strlen(name); + int l = (int)strlen(name); char* newName = new char[l+1]; memcpy(newName,name,l); newName[l] = 0; diff --git a/src/BulletCollision/CollisionDispatch/btGhostObject.h b/src/BulletCollision/CollisionDispatch/btGhostObject.h index 61910d9b3..8ec861385 100644 --- a/src/BulletCollision/CollisionDispatch/btGhostObject.h +++ b/src/BulletCollision/CollisionDispatch/btGhostObject.h @@ -160,7 +160,7 @@ public: return 0; } - virtual void removeOverlappingPairsContainingProxy(btBroadphaseProxy* proxy0,btDispatcher* dispatcher) + virtual void removeOverlappingPairsContainingProxy(btBroadphaseProxy* /*proxy0*/,btDispatcher* /*dispatcher*/) { btAssert(0); //need to keep track of all ghost objects and call them here diff --git a/src/BulletDynamics/ConstraintSolver/btSolverConstraint.h b/src/BulletDynamics/ConstraintSolver/btSolverConstraint.h index 0ce25e783..79e45a438 100644 --- a/src/BulletDynamics/ConstraintSolver/btSolverConstraint.h +++ b/src/BulletDynamics/ConstraintSolver/btSolverConstraint.h @@ -59,12 +59,12 @@ ATTRIBUTE_ALIGNED64 (struct) btSolverConstraint union { btRigidBody* m_solverBodyA; - btScalar m_companionIdA; + int m_companionIdA; }; union { btRigidBody* m_solverBodyB; - btScalar m_companionIdB; + int m_companionIdB; }; union diff --git a/src/BulletDynamics/ConstraintSolver/btTypedConstraint.h b/src/BulletDynamics/ConstraintSolver/btTypedConstraint.h index b24dc4a40..0972090bf 100644 --- a/src/BulletDynamics/ConstraintSolver/btTypedConstraint.h +++ b/src/BulletDynamics/ConstraintSolver/btTypedConstraint.h @@ -151,7 +151,7 @@ public: } ///internal method used by the constraint solver, don't use them directly - virtual void solveConstraintObsolete(btRigidBody& bodyA,btRigidBody& bodyB,btScalar timeStep) {}; + virtual void solveConstraintObsolete(btRigidBody& /*bodyA*/,btRigidBody& /*bodyB*/,btScalar /*timeStep*/) {}; const btRigidBody& getRigidBodyA() const diff --git a/src/BulletMultiThreaded/MiniCL.cpp b/src/BulletMultiThreaded/MiniCL.cpp index 203722f93..9cb1ca331 100644 --- a/src/BulletMultiThreaded/MiniCL.cpp +++ b/src/BulletMultiThreaded/MiniCL.cpp @@ -100,7 +100,7 @@ CL_API_ENTRY cl_int CL_API_CALL clGetDeviceInfo( { char deviceName[] = "CPU"; unsigned int nameLen = strlen(deviceName)+1; - assert(param_value_size>strlen(deviceName)); + btAssert(param_value_size>strlen(deviceName)); if (nameLen < param_value_size) { const char* cpuName = "CPU"; diff --git a/src/BulletMultiThreaded/PlatformDefinitions.h b/src/BulletMultiThreaded/PlatformDefinitions.h index 68c16e15e..db4e2eebd 100644 --- a/src/BulletMultiThreaded/PlatformDefinitions.h +++ b/src/BulletMultiThreaded/PlatformDefinitions.h @@ -5,7 +5,7 @@ #include "LinearMath/btScalar.h" #include "LinearMath/btMinMax.h" -#include +#include "vectormath_aos.h" typedef Vectormath::Aos::Vector3 vmVector3; typedef Vectormath::Aos::Quat vmQuat; typedef Vectormath::Aos::Matrix3 vmMatrix3; diff --git a/src/BulletMultiThreaded/btParallelConstraintSolver.cpp b/src/BulletMultiThreaded/btParallelConstraintSolver.cpp index b979398e9..c215e49b4 100644 --- a/src/BulletMultiThreaded/btParallelConstraintSolver.cpp +++ b/src/BulletMultiThreaded/btParallelConstraintSolver.cpp @@ -173,7 +173,7 @@ void CustomSolveConstraintsTaskParallel( uint32_t numPairs = jointParallelGroup->numPairs[phaseId*PFX_MAX_SOLVER_BATCHES+batchId]; if(batchId%numTasks == taskId && numPairs > 0) { const PfxParallelBatch &batch = jointParallelBatches[phaseId*PFX_MAX_SOLVER_BATCHES+batchId]; - for(int i=0;inumPairs[phaseId*PFX_MAX_SOLVER_BATCHES+batchId]; if(batchId%numTasks == taskId && numPairs > 0) { const PfxParallelBatch &batch = contactParallelBatches[phaseId*PFX_MAX_SOLVER_BATCHES+batchId]; - for(int i=0;i m_valueArray; btAlignedObjectArray m_keyArray; - void growTables(const Key& key) + void growTables(const Key& /*key*/) { int newCapacity = m_valueArray.capacity();