fix Mac OSX build

This commit is contained in:
erwin.coumans
2010-02-11 21:41:05 +00:00
parent 10c300c7a0
commit 065a56ee4b
6 changed files with 13 additions and 3 deletions

View File

@@ -1257,7 +1257,7 @@ btRigidBody* DemoApplication::localCreateRigidBody(float mass, const btTransform
btRigidBody* body = new btRigidBody(mass,0,shape,localInertia);
body->setWorldTransform(startTransform);
body->setContactProcessingThreshold(m_defaultContactProcessingThreshold);
m_dynamicsWorld->addRigidBody(body);
return body;

View File

@@ -40,7 +40,13 @@ class DemoApplication
protected:
btDynamicsWorld* m_dynamicsWorld;
btScalar m_defaultContactProcessingThreshold;
public:
DemoApplication()
:m_defaultContactProcessingThreshold(BT_LARGE_FLOAT)
{
}
virtual void myinit() {}
virtual btDynamicsWorld* getDynamicsWorld()
{

View File

@@ -51,7 +51,9 @@ int main(int argc,char** argv)
benchmarkDemo.initPhysics();
benchmarkDemo.getDynamicsWorld()->setDebugDrawer(&gDebugDrawer);
benchmarkDemo.setDebugMode(benchmarkDemo.getDebugMode() | btIDebugDraw::DBG_NoDeactivation);
setDefaultContactProcessingThreshold(0.f);
return glutmain(argc, argv,640,480,"Bullet Physics Demo. http://bulletphysics.com",&benchmarkDemo);
#else //USE_GRAPHICAL_BENCHMARK
int d;

View File

@@ -260,4 +260,6 @@ static uint4 operator-(const uint4& a,const uint4& b)
#define as_int(a) (*((int*)&(a)))
extern "C" int gMiniCLNumOutstandingTasks;
// extern "C" void __kernel_func(); \
// extern "C" void __kernel_func();

View File

@@ -31,7 +31,7 @@ struct MiniCLKernelDesc
MiniCLKernelDesc(void* pCode, char* pName);
};
#define MINICL_REGISTER(__kernel_func) static MiniCLKernelDesc __kernel_func##Desc(__kernel_func, #__kernel_func);
#define MINICL_REGISTER(__kernel_func) static MiniCLKernelDesc __kernel_func##Desc((void*)__kernel_func, #__kernel_func);
#ifdef __APPLE__