mirror of
https://github.com/bulletphysics/bullet3
synced 2025-01-11 01:40:10 +00:00
Set debug drawer for demo
Fixed issue with toggle of activation in the DemoApplication added hint/todo for Win32ThreadSupport
This commit is contained in:
parent
ec76f2e0a3
commit
550c500ca7
@ -15,7 +15,10 @@ subject to the following restrictions:
|
|||||||
|
|
||||||
#include "CcdPhysicsDemo.h"
|
#include "CcdPhysicsDemo.h"
|
||||||
#include "GlutStuff.h"
|
#include "GlutStuff.h"
|
||||||
|
#include "GLDebugDrawer.h"
|
||||||
|
#include "btBulletDynamicsCommon.h"
|
||||||
|
|
||||||
|
GLDebugDrawer gDebugDrawer;
|
||||||
|
|
||||||
int main(int argc,char** argv)
|
int main(int argc,char** argv)
|
||||||
{
|
{
|
||||||
@ -23,6 +26,7 @@ int main(int argc,char** argv)
|
|||||||
CcdPhysicsDemo* ccdDemo = new CcdPhysicsDemo();
|
CcdPhysicsDemo* ccdDemo = new CcdPhysicsDemo();
|
||||||
|
|
||||||
ccdDemo->initPhysics();
|
ccdDemo->initPhysics();
|
||||||
|
ccdDemo->getDynamicsWorld()->setDebugDrawer(&gDebugDrawer);
|
||||||
|
|
||||||
|
|
||||||
return glutmain(argc, argv,640,480,"Bullet Physics Demo. http://bullet.sf.net",ccdDemo);
|
return glutmain(argc, argv,640,480,"Bullet Physics Demo. http://bullet.sf.net",ccdDemo);
|
||||||
|
@ -312,7 +312,7 @@ void DemoApplication::keyboardCallback(unsigned char key, int x, int y)
|
|||||||
m_debugMode = m_debugMode & (~btIDebugDraw::DBG_NoDeactivation);
|
m_debugMode = m_debugMode & (~btIDebugDraw::DBG_NoDeactivation);
|
||||||
else
|
else
|
||||||
m_debugMode |= btIDebugDraw::DBG_NoDeactivation;
|
m_debugMode |= btIDebugDraw::DBG_NoDeactivation;
|
||||||
if (m_debugMode | btIDebugDraw::DBG_NoDeactivation)
|
if (m_debugMode & btIDebugDraw::DBG_NoDeactivation)
|
||||||
{
|
{
|
||||||
gDisableDeactivation = true;
|
gDisableDeactivation = true;
|
||||||
} else
|
} else
|
||||||
|
@ -22,6 +22,9 @@ subject to the following restrictions:
|
|||||||
|
|
||||||
#include <Windows.h>
|
#include <Windows.h>
|
||||||
|
|
||||||
|
///The number of threads should be equal to the number of available cores
|
||||||
|
///Todo: each worker should be linked to a single core, using SetThreadIdealProcessor.
|
||||||
|
|
||||||
///Win32ThreadSupport helps to initialize/shutdown libspe2, start/stop SPU tasks and communication
|
///Win32ThreadSupport helps to initialize/shutdown libspe2, start/stop SPU tasks and communication
|
||||||
///Setup and initialize SPU/CELL/Libspe2
|
///Setup and initialize SPU/CELL/Libspe2
|
||||||
Win32ThreadSupport::Win32ThreadSupport(Win32ThreadConstructionInfo& threadConstructionInfo)
|
Win32ThreadSupport::Win32ThreadSupport(Win32ThreadConstructionInfo& threadConstructionInfo)
|
||||||
|
Loading…
Reference in New Issue
Block a user