Skip to content
Snippets Groups Projects
Commit 622fac31 authored by Mirko Wächter's avatar Mirko Wächter Committed by Mirko Wächter
Browse files

fixed setting of object pose for kinematic objects in physics simulation

parent ff86aa2c
No related branches found
No related tags found
Loading
......@@ -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