2 Bullet Continuous Collision Detection and Physics Library
3 Copyright (c) 2003-2006 Erwin Coumans http://continuousphysics.com/Bullet/
5 This software is provided 'as-is', without any express or implied warranty.
6 In no event will the authors be held liable for any damages arising from the use of this software.
7 Permission is granted to anyone to use this software for any purpose,
8 including commercial applications, and to alter it and redistribute it freely,
9 subject to the following restrictions:
11 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.
12 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
13 3. This notice may not be removed or altered from any source distribution.
18 #ifdef _WIN32//for glut.h
23 #if defined(__APPLE__) && !defined (VMDMESA)
24 #include <OpenGL/OpenGL.h>
25 #include <OpenGL/gl.h>
26 #include <OpenGL/glu.h>
27 #include <GLUT/glut.h>
42 #define BT_ACTIVE_ALT VK_LMENU
46 #define BT_KEY_LEFT GLUT_KEY_LEFT
47 #define BT_KEY_RIGHT GLUT_KEY_RIGHT
48 #define BT_KEY_UP GLUT_KEY_UP
49 #define BT_KEY_DOWN GLUT_KEY_DOWN
50 #define BT_KEY_F1 GLUT_KEY_F1
51 #define BT_KEY_F2 GLUT_KEY_F2
52 #define BT_KEY_F3 GLUT_KEY_F3
53 #define BT_KEY_F4 GLUT_KEY_F4
54 #define BT_KEY_F5 GLUT_KEY_F5
55 #define BT_KEY_PAGEUP GLUT_KEY_PAGE_UP
56 #define BT_KEY_PAGEDOWN GLUT_KEY_PAGE_DOWN
57 #define BT_KEY_END GLUT_KEY_END
58 #define BT_KEY_HOME GLUT_KEY_HOME
59 #define BT_ACTIVE_ALT GLUT_ACTIVE_ALT
60 #define BT_ACTIVE_CTRL GLUT_ACTIVE_ALT
61 #define BT_ACTIVE_SHIFT GLUT_ACTIVE_SHIFT
65 #include "GL/freeglut_ext.h" //to be able to return from glutMainLoop()
70 class DemoApplication;
72 int glutmain(int argc, char **argv,int width,int height,const char* title,DemoApplication* demoApp);
74 #if defined(BT_USE_DOUBLE_PRECISION)
75 #define btglLoadMatrix glLoadMatrixd
76 #define btglMultMatrix glMultMatrixd
77 #define btglColor3 glColor3d
78 #define btglVertex3 glVertex3d
80 #define btglLoadMatrix glLoadMatrixf
81 #define btglMultMatrix glMultMatrixf
82 #define btglColor3 glColor3f
83 #define btglVertex3 glVertex3d