Skip to content
Snippets Groups Projects
Commit 586de6f5 authored by Mirko Wächter's avatar Mirko Wächter
Browse files

fixed setting of object pose for kinematic objects in physics simulation

parent 5f66b777
No related branches found
No related tags found
No related merge requests found
......@@ -31,14 +31,17 @@ namespace SimDynamics
void DynamicsObject::setPose(const Eigen::Matrix4f& pose)
{
MutexLockPtr lock = getScopedLock();
if (sceneObject->getSimulationType() == VirtualRobot::SceneObject::Physics::eDynamic)
{
// moving dynamic objects is not allowed
return;
}
if (sceneObject->getSimulationType() == VirtualRobot::SceneObject::Physics::eStatic)
{
VR_ERROR << "Could not move static object, aborting..." << endl;
VR_ERROR << "Could not move static object, use kinematic instead, aborting..." << endl;
return;
}
//sceneObject->setGlobalPose(pose);
sceneObject->setGlobalPose(pose);
}
void DynamicsObject::setPosition(const Eigen::Vector3f& posMM)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment