add some micro-sleep to prevent 100% CPU/memory bus hogging, preventing the graphics thread from making progress.

debug draw color black for contact normal
move debug draw option for constraint frames into 'k' key.
This commit is contained in:
YunfeiBai
2016-08-19 13:58:53 -07:00
parent 94161246d9
commit 6751648bce
3 changed files with 17 additions and 4 deletions

View File

@@ -194,7 +194,6 @@ void MyKeyboardCallback(int key, int state)
}
if (key=='c' && state)
{
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawConstraints;
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawContactPoints;
}
if (key == 'd' && state)
@@ -202,6 +201,11 @@ void MyKeyboardCallback(int key, int state)
gDebugDrawFlags ^= btIDebugDraw::DBG_NoDeactivation;
gDisableDeactivation = ((gDebugDrawFlags & btIDebugDraw::DBG_NoDeactivation) != 0);
}
if (key == 'k' && state)
{
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawConstraints;
}
if (key=='l' && state)
{
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawConstraintLimits;