This commit is contained in:
you2xie
2018-11-27 11:06:44 +01:00
parent 43628b8f74
commit 2fb9a6be67
4 changed files with 152 additions and 94 deletions

View File

@@ -20,10 +20,10 @@ using namespace GamePhysics;
//#define ADAPTIVESTEP
#define TEMPLATE_DEMO
//#define TEMPLATE_DEMO
//#define MASS_SPRING_SYSTEM
//#define RIGID_BODY_SYSTEM
//#define SPH_SYSTEM
#define SPHERE_SYSTEM
#ifdef TEMPLATE_DEMO
#include "TemplateSimulator.h"
@@ -32,10 +32,10 @@ using namespace GamePhysics;
#include "MassSpringSystemSimulator.h"
#endif
#ifdef RIGID_BODY_SYSTEM
//#include "RigidBodySystemSimulator.h"
#include "RigidBodySystemSimulator.h"
#endif
#ifdef SPH_SYSTEM
//#include "SPHSystemSimulator.h"
#ifdef SPHERE_SYSTEM
#include "SphereSystemSimulator.h"
#endif
DrawingUtilitiesClass * g_pDUC;
@@ -204,9 +204,7 @@ void CALLBACK OnMouse( bool bLeftButtonDown, bool bRightButtonDown, bool bMiddle
g_pSimulator->onClick(xPos,yPos);
}
else
{
g_pSimulator->onMouse(xPos, yPos);
}
}
@@ -365,10 +363,10 @@ int main(int argc, char* argv[])
g_pSimulator= new MassSpringSystemSimulator();
#endif
#ifdef RIGID_BODY_SYSTEM
//g_pSimulator= new RigidBodySystemSimulator();
g_pSimulator= new RigidBodySystemSimulator();
#endif
#ifdef SPH_SYSTEM
//g_pSimulator= new SPHSystemSimulator();
#ifdef SPHERE_SYSTEM
g_pSimulator= new SphereSystemSimulator();
#endif
g_pSimulator->reset();