updated demos -> ALT + mouse uses Maya-style controls, replaced BMF_Fonts by GLDebugFont

fix debug drawing of btMultiSphereShape
added box2d demo
added experimental gpu 2d demo
This commit is contained in:
erwin.coumans
2009-05-09 19:27:14 +00:00
parent 7a210546cf
commit 33029ad996
129 changed files with 8576 additions and 2184 deletions

View File

@@ -32,16 +32,16 @@ subject to the following restrictions:
#include "../ConstraintDemo/ConstraintDemo.h"
#include "../Benchmarks/BenchmarkDemo.h"
#include "../SoftDemo/SoftDemo.h"
#include "GLDebugFont.h"
#include "GlutStuff.h"//OpenGL stuff
#include "BMF_Api.h"//font stuff
extern int gNumAlignedAllocs;
extern int gNumAlignedFree;
extern int gTotalBytesAlignedAllocs;
class btEmptyDebugDemo : public DemoApplication
class btEmptyDebugDemo : public GlutDemoApplication
{
public:
btEmptyDebugDemo()
@@ -66,22 +66,22 @@ public:
glRasterPos3f(xOffset,yStart,0);
sprintf(buf,"gNumAlignedAllocs= %d",gNumAlignedAllocs);
BMF_DrawString(BMF_GetFont(BMF_kHelvetica10),buf);
GLDebugDrawString(xOffset,yStart,buf);
yStart += yIncr;
glRasterPos3f(xOffset,yStart,0);
sprintf(buf,"gNumAlignedFree= %d",gNumAlignedFree);
BMF_DrawString(BMF_GetFont(BMF_kHelvetica10),buf);
GLDebugDrawString(xOffset,yStart,buf);
yStart += yIncr;
glRasterPos3f(xOffset,yStart,0);
sprintf(buf,"# alloc-free = %d",gNumAlignedAllocs-gNumAlignedFree);
BMF_DrawString(BMF_GetFont(BMF_kHelvetica10),buf);
GLDebugDrawString(xOffset,yStart,buf);
yStart += yIncr;
#ifdef BT_DEBUG_MEMORY_ALLOCATIONS
glRasterPos3f(xOffset,yStart,0);
sprintf(buf,"gTotalBytesAlignedAllocs = %d",gTotalBytesAlignedAllocs);
BMF_DrawString(BMF_GetFont(BMF_kHelvetica10),buf);
GLDebugDrawString(xOffset,yStart,buf);
yStart += yIncr;
#endif //BT_DEBUG_MEMORY_ALLOCATIONS
@@ -90,6 +90,8 @@ public:
}
virtual void initPhysics() {}
static DemoApplication* Create()
{
btEmptyDebugDemo* demo = new btEmptyDebugDemo();