Go to the documentation of this file.
   24 #include <VirtualRobot/RobotNodeSet.h> 
   25 #include <VirtualRobot/VirtualRobot.h> 
   29 #include <ArmarXCore/interface/core/BasicTypes.h> 
   40     using namespace Eigen;
 
   45         switch (node->getType())
 
   60         return RobotNodePtr();
 
   69         remoteNode->jointRotationAxis =
 
   71             Vector3Ptr::dynamicCast(remoteNode->
_node->getJointRotationAxis())->toEigen();
 
   80         remoteNode->jointTranslationDirection =
 
   82             Vector3Ptr::dynamicCast(remoteNode->
_node->getJointTranslationDirection())->toEigen();
 
   93     template <
class RobotNodeType>
 
  100         catch (std::exception& e)
 
  102             ARMARX_DEBUG_S << 
"Unref of SharedRobotNode failed: " << e.what();
 
  106             ARMARX_DEBUG_S << 
"Unref of SharedRobotNode failed: reason unknown";
 
  110     template <
class RobotNodeType>
 
  114         return _node->getJointValue();
 
  117     template <
class RobotNodeType>
 
  121         return _node->getJointLimitHigh();
 
  124     template <
class RobotNodeType>
 
  128         return _node->getJointLimitLow();
 
  137     template <
class RobotNodeType>
 
  141         return PosePtr::dynamicCast(_node->getLocalTransformation())->toEigen();
 
  144     template <
class RobotNodeType>
 
  148         return FramedPosePtr::dynamicCast(_node->getGlobalPose())->toEigen();
 
  151     template <
class RobotNodeType>
 
  155         return FramedPosePtr::dynamicCast(_node->getPoseInRootFrame())->toEigen();
 
  158     template <
class RobotNodeType>
 
  162         Vector3Ptr pos = Vector3Ptr::dynamicCast(_node->getPoseInRootFrame()->position);
 
  164         return pos->toEigen();
 
  167     template <
class RobotNodeType>
 
  174     template <
class RobotNodeType>
 
  178         return _node->hasChild(child, recursive);
 
  181     template <
class RobotNodeType>
 
  187     template <
class RobotNodeType>
 
  191         NameList nodes = _node->getAllParents(rns->getName());
 
  192         vector<RobotNodePtr> result;
 
  193         RobotPtr robot = this->robot.lock();
 
  195         for (std::string 
const& name : nodes)
 
  197             result.push_back(robot->getRobotNode(name));
 
  202     template <
class RobotNodeType>
 
  206         return this->robot.lock()->getRobotNode(_node->getParent());
 
  213     template <
class RobotNodeType>
 
  219     template <
class RobotNodeType>
 
  220     std::vector<std::string>
 
  223         return _node->getChildren();
 
  226     template <
class RobotNodeType>
 
  230         return _node->getParent();
 
  233     template <
class RobotNodeType>
 
  234     std::vector<SceneObjectPtr>
 
  237         NameList nodes = _node->getChildren();
 
  238         vector<SceneObjectPtr> result;
 
  239         for (
string const& name : nodes)
 
  241             result.push_back(this->robot.lock()->getRobotNode(name));
 
  246     template <
class RobotNodeType>
 
  252     template <
class RobotNodeType>
 
  258     template <
class RobotNodeType>
 
  264     template <
class RobotNodeType>
 
  271     template <
class RobotNodeType>
 
  277     template <
class RobotNodeType>
 
  283     template <
class RobotNodeType>
 
  286                                                   bool updateTransformations,
 
  
 
virtual float getJointLimitLo() const
static VirtualRobot::RobotNodePtr createRemoteRobotNode(SharedRobotNodeInterfacePrx, VirtualRobot::RobotPtr)
virtual bool hasChildNode(const std::string &child, bool recursive=false) const
MatrixXX< 4, 4, float > Matrix4f
static void initialize(RemoteRobotNode< VirtualRobotNodeType > *remoteNode)
virtual float getJointLimitHi() const
virtual void setLocalTransformation(const Eigen::Matrix4f &trafo)
float getJointValue() const override
Eigen::Matrix4f getGlobalPose() const override
std::vector< VirtualRobot::SceneObjectPtr > getChildren() const override
Eigen::Matrix4f getPoseInRootFrame() const override
SharedRobotNodeInterfacePrx _node
void setJointLimits(float lo, float hi) override
void setGlobalPose(const Eigen::Matrix4f &pose) override
std::vector< VirtualRobot::RobotNodePtr > getAllParents(VirtualRobot::RobotNodeSetPtr rns) override
void updateTransformationMatrices() override
virtual void addChildNode(VirtualRobot::RobotNodePtr child)
Eigen::Matrix4f getLocalTransformation() override
virtual VirtualRobot::SceneObjectPtr getParent()
Mimics the behaviour of robot nodes while redirecting everything to Ice proxies.
#define ARMARX_CHECK_EXPRESSION(expression)
This macro evaluates the expression and if it turns out to be false it will throw an ExpressionExcept...
boost::intrusive_ptr< SceneObject > SceneObjectPtr
virtual std::string getParentName() const
virtual std::vector< std::string > getChildrenNames() const
virtual bool initialize(VirtualRobot::RobotNodePtr parent, bool initializeChildren=false)
~RemoteRobotNode() override
virtual void setJointValue(float q, bool updateTransformations=true, bool clampToLimits=true)
Eigen::Vector3f getPositionInRootFrame() const override
This file offers overloads of toIce() and fromIce() functions for STL container types.
std::shared_ptr< class Robot > RobotPtr