App_SharedMemoryPhysics_VR: Add a command-line flag (--emptyworld) to disable the Samurai/KUKA robot creation in the VR demo, and use pybullet to populate the VR world. Note that either way, you can use pybullet to interact and control the world.

This commit is contained in:
erwincoumans
2016-10-08 18:40:09 -07:00
parent c5d4f7b3b3
commit bbb2fac940
4 changed files with 460 additions and 431 deletions

View File

@@ -7,7 +7,7 @@
#include "PhysicsServerSharedMemory.h"
#include "Bullet3Common/b3CommandLineArgs.h"
#include "SharedMemoryCommon.h"
#include "Bullet3Common/b3Matrix3x3.h"
#include "../Utils/b3Clock.h"
@@ -28,6 +28,7 @@ extern btScalar gVRGripperAnalog;
extern btScalar gVRGripper2Analog;
extern bool gCloseToKuka;
extern bool gEnableRealTimeSimVR;
extern bool gCreateSamuraiRobotAssets;
extern int gCreateObjectSimVR;
static int gGraspingController = -1;
extern btScalar simTimeScalingFactor;
@@ -656,6 +657,16 @@ public:
m_physicsServer.setSharedMemoryKey(key);
}
virtual void processCommandLineArgs(int argc, char* argv[])
{
b3CommandLineArgs args(argc,argv);
if (args.CheckCmdLineFlag("emptyworld"))
{
gCreateSamuraiRobotAssets = false;
}
}
};