Merge pull request #1736 from erwincoumans/master

remove some warnings
This commit is contained in:
erwincoumans 2018-06-06 19:22:19 -07:00 committed by GitHub
commit 8a70afa4f6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 10 additions and 11 deletions

View File

@ -96,7 +96,6 @@ bool b3RobotSimulatorClientAPI::connect(int mode, const std::string& hostName, i
int udpPort = 1234;
int tcpPort = 6667;
int key = SHARED_MEMORY_KEY;
bool connected = false;
switch (mode)
{

View File

@ -242,7 +242,6 @@ void PhysicsClientSharedMemory::resetData()
BodyJointInfoCache** bodyJointsPtr = m_data->m_bodyJointMap.getAtIndex(i);
if (bodyJointsPtr && *bodyJointsPtr)
{
BodyJointInfoCache* bodyJoints = *bodyJointsPtr;
delete (*bodyJointsPtr);
}
}

View File

@ -444,7 +444,7 @@ void b3RobotSimulatorClientAPI_NoDirect::setRealTimeSimulation(bool enableRealTi
b3SharedMemoryCommandHandle command = b3InitPhysicsParamCommand(m_data->m_physicsClientHandle);
b3SharedMemoryStatusHandle statusHandle;
int ret = b3PhysicsParamSetRealTimeSimulation(command, enableRealTimeSimulation);
b3PhysicsParamSetRealTimeSimulation(command, enableRealTimeSimulation);
statusHandle = b3SubmitClientCommandAndWaitStatus(m_data->m_physicsClientHandle, command);
@ -531,7 +531,7 @@ void b3RobotSimulatorClientAPI_NoDirect::removeConstraint(int constraintId)
}
b3SharedMemoryCommandHandle commandHandle = b3InitRemoveUserConstraintCommand(m_data->m_physicsClientHandle, constraintId);
b3SharedMemoryStatusHandle statusHandle = b3SubmitClientCommandAndWaitStatus(m_data->m_physicsClientHandle, commandHandle);
int statusType = b3GetStatusType(statusHandle);
b3GetStatusType(statusHandle);
}
@ -1094,7 +1094,7 @@ bool b3RobotSimulatorClientAPI_NoDirect::calculateInverseDynamics(int bodyUnique
return false;
}
int numJoints = b3GetNumJoints(m_data->m_physicsClientHandle, bodyUniqueId);
b3GetNumJoints(m_data->m_physicsClientHandle, bodyUniqueId);
b3SharedMemoryStatusHandle statusHandle;
int statusType;
b3SharedMemoryCommandHandle commandHandle = b3CalculateInverseDynamicsCommandInit(m_data->m_physicsClientHandle, bodyUniqueId, jointPositions,
@ -1404,7 +1404,7 @@ bool b3RobotSimulatorClientAPI_NoDirect::setJointMotorControlArray(int bodyUniqu
b3Warning("Not connected to physics server.");
return false;
}
int numJoints = b3GetNumJoints(sm, bodyUniqueId);
b3GetNumJoints(sm, bodyUniqueId);
b3SharedMemoryCommandHandle commandHandle;
b3SharedMemoryStatusHandle statusHandle;

View File

@ -388,9 +388,10 @@ struct b3RobotSimulatorCreateMultiBodyArgs
int m_useMaximalCoordinates;
b3RobotSimulatorCreateMultiBodyArgs()
: m_numLinks(0), m_baseMass(0), m_baseCollisionShapeIndex(-1), m_baseVisualShapeIndex(-1), m_useMaximalCoordinates(0),
m_linkMasses(NULL),
m_linkCollisionShapeIndices(NULL),
: m_baseMass(0), m_baseCollisionShapeIndex(-1), m_baseVisualShapeIndex(-1),
m_numLinks(0),
m_linkMasses(NULL),
m_linkCollisionShapeIndices(NULL),
m_linkVisualShapeIndices(NULL),
m_linkPositions(NULL),
m_linkOrientations(NULL),
@ -398,7 +399,8 @@ struct b3RobotSimulatorCreateMultiBodyArgs
m_linkInertialFrameOrientations(NULL),
m_linkParentIndices(NULL),
m_linkJointTypes(NULL),
m_linkJointAxes(NULL)
m_linkJointAxes(NULL),
m_useMaximalCoordinates(0)
{
m_basePosition.setValue(0,0,0);
m_baseOrientation.setValue(0,0,0,1);

View File

@ -40,7 +40,6 @@ bool b3RobotSimulatorClientAPI_NoGUI::connect(int mode, const std::string& hostN
int udpPort = 1234;
int tcpPort = 6667;
int key = SHARED_MEMORY_KEY;
bool connected = false;
switch (mode)
{