mirror of
https://github.com/bulletphysics/bullet3.git
synced 2026-10-06 08:55:36 +00:00
Merge pull request #3066 from erwincoumans/master
allow alternative deformable indexing (internal use/testing)
This commit is contained in:
@@ -1710,6 +1710,7 @@ struct PhysicsServerCommandProcessorInternalData
|
||||
|
||||
double m_remoteSyncTransformTime;
|
||||
double m_remoteSyncTransformInterval;
|
||||
bool m_useAlternativeDeformableIndexing;
|
||||
|
||||
PhysicsServerCommandProcessorInternalData(PhysicsCommandProcessorInterface* proc)
|
||||
: m_pluginManager(proc),
|
||||
@@ -1752,7 +1753,8 @@ struct PhysicsServerCommandProcessorInternalData
|
||||
m_threadPool(0),
|
||||
m_defaultCollisionMargin(0.001),
|
||||
m_remoteSyncTransformTime(1. / 30.),
|
||||
m_remoteSyncTransformInterval(1. / 30.)
|
||||
m_remoteSyncTransformInterval(1. / 30.),
|
||||
m_useAlternativeDeformableIndexing(false)
|
||||
{
|
||||
{
|
||||
//register static plugins:
|
||||
@@ -8684,7 +8686,7 @@ bool PhysicsServerCommandProcessor::processDeformable(const UrdfDeformable& defo
|
||||
if ((out_found_sim_filename != out_found_filename) || ((out_sim_type == UrdfGeometry::FILE_OBJ)))
|
||||
{
|
||||
// load render mesh
|
||||
if (1)
|
||||
if (!m_data->m_useAlternativeDeformableIndexing)
|
||||
{
|
||||
|
||||
float rgbaColor[4] = { 1,1,1,1 };
|
||||
@@ -10182,6 +10184,8 @@ bool PhysicsServerCommandProcessor::processSendPhysicsParametersCommand(const st
|
||||
{
|
||||
//these flags are for internal/temporary/easter-egg/experimental demo purposes, use at own risk
|
||||
gInternalSimFlags = clientCmd.m_physSimParamArgs.m_internalSimFlags;
|
||||
m_data->m_useAlternativeDeformableIndexing =
|
||||
(clientCmd.m_physSimParamArgs.m_internalSimFlags & eDeformableAlternativeIndexing) != 0;
|
||||
}
|
||||
|
||||
if (clientCmd.m_updateFlags & SIM_PARAM_UPDATE_GRAVITY)
|
||||
|
||||
@@ -996,6 +996,12 @@ struct b3PluginArguments
|
||||
double m_floats[B3_MAX_PLUGIN_ARG_SIZE];
|
||||
};
|
||||
|
||||
enum eInternalSimFlags
|
||||
{
|
||||
eVRTinyGUI = 1<<1,
|
||||
eDeformableAlternativeIndexing = 1<<2,
|
||||
};
|
||||
|
||||
struct b3PhysicsSimulationParameters
|
||||
{
|
||||
double m_deltaTime;
|
||||
|
||||
Reference in New Issue
Block a user