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

@@ -20,7 +20,7 @@ subject to the following restrictions:
///with gears etc.
#include "btBulletDynamicsCommon.h"
#include "BulletCollision/CollisionShapes/btHeightfieldTerrainShape.h"
#include "GLDebugFont.h"
#ifndef M_PI
#define M_PI 3.14159265358979323846
@@ -62,7 +62,7 @@ subject to the following restrictions:
#include "GlutStuff.h"
#include "ForkLiftDemo.h"
#include "BMF_Api.h"
const int maxProxies = 32766;
const int maxOverlap = 65535;
@@ -439,7 +439,7 @@ void ForkLiftDemo::renderme()
int lineWidth=250;
int xStart = m_glutScreenWidth - lineWidth;
int yStart = 20;
if((getDebugMode() & btIDebugDraw::DBG_NoHelpText)==0)
{
@@ -447,18 +447,23 @@ void ForkLiftDemo::renderme()
glDisable(GL_LIGHTING);
glColor3f(0, 0, 0);
char buf[124];
glRasterPos3f(xStart, 20, 0);
glRasterPos3f(xStart, yStart, 0);
sprintf(buf,"SHIFT+Cursor Left/Right - rotate lift");
BMF_DrawString(BMF_GetFont(BMF_kHelvetica10),buf);
glRasterPos3f(xStart, 40, 0);
GLDebugDrawString(xStart,20,buf);
yStart+=20;
glRasterPos3f(xStart, yStart, 0);
sprintf(buf,"SHIFT+Cursor UP/Down - move fork up/down");
BMF_DrawString(BMF_GetFont(BMF_kHelvetica10),buf);
glRasterPos3f(xStart, 60, 0);
yStart+=20;
GLDebugDrawString(xStart,yStart,buf);
glRasterPos3f(xStart, yStart, 0);
sprintf(buf,"F5 - toggle camera mode");
BMF_DrawString(BMF_GetFont(BMF_kHelvetica10),buf);
glRasterPos3f(xStart, 80, 0);
sprintf(buf,"Click inside this window for keyboard focus");
BMF_DrawString(BMF_GetFont(BMF_kHelvetica10),buf);
yStart+=20;
GLDebugDrawString(xStart,yStart,buf);
glRasterPos3f(xStart, yStart, 0);
sprintf(buf,"Click inside this window for keyboard focus");
yStart+=20;
GLDebugDrawString(xStart,yStart,buf);
resetPerspectiveProjection();

View File

@@ -23,10 +23,10 @@ class btCollisionShape;
#include "BulletDynamics/ConstraintSolver/btHingeConstraint.h"
#include "BulletDynamics/ConstraintSolver/btSliderConstraint.h"
#include "DemoApplication.h"
#include "GlutDemoApplication.h"
///VehicleDemo shows how to setup and use the built-in raycast vehicle
class ForkLiftDemo : public DemoApplication
class ForkLiftDemo : public GlutDemoApplication
{
public: