add basic legacy OpenGL2 rendering

This commit is contained in:
erwin coumans
2015-04-20 15:28:52 -07:00
parent 482deb1fca
commit 13396d32bf
14 changed files with 1080 additions and 100 deletions

View File

@@ -1,6 +1,6 @@
#ifndef OPENGL_GUI_HELPER_H
#define OPENGL_GUI_HELPER_H
#include "GUIHelperInterface.h"
#include "../CommonInterfaces/CommonGUIHelperInterface.h"
class btCollisionShape;
class btTransform;
@@ -10,7 +10,7 @@ struct OpenGLGuiHelper : public GUIHelperInterface
{
struct OpenGLGuiHelperInternalData* m_data;
OpenGLGuiHelper(struct CommonGraphicsApp* glApp);
OpenGLGuiHelper(struct CommonGraphicsApp* glApp, bool useOpenGL2);
virtual ~OpenGLGuiHelper();
@@ -30,6 +30,10 @@ struct OpenGLGuiHelper : public GUIHelperInterface
virtual void syncPhysicsToGraphics(const btDiscreteDynamicsWorld* rbWorld);
virtual void render(const btDiscreteDynamicsWorld* rbWorld);
virtual void createPhysicsDebugDrawer(btDiscreteDynamicsWorld* rbWorld);
virtual struct Common2dCanvasInterface* get2dCanvasInterface();
@@ -46,6 +50,8 @@ struct OpenGLGuiHelper : public GUIHelperInterface
virtual void autogenerateGraphicsObjects(btDiscreteDynamicsWorld* rbWorld) ;
virtual void drawText3D( const char* txt, float posX, float posY, float posZ, float size);
void renderInternalGl2(int pass, const btDiscreteDynamicsWorld* dynamicsWorld);
};
#endif //OPENGL_GUI_HELPER_H