38 namespace interfaces {
49 node2->
pos = node1.
rot.inverse() * (node2->
pos-node1.
pos);
50 node2->
rot = node1.
rot.inverse()*node2->
rot;
69 std::cerr <<
"getJointTypeString(JointType id): invalid joint type id " << (int)type << std::endl;
74 return sJointTypeStrings[type];
84 if (text == sJointTypeStrings[i])
91 std::istringstream iss(text);
93 if ( !(iss >> numberFromString).fail() )
96 if (numberFromString > 0 && numberFromString < NUMBER_OF_JOINT_TYPES)
104 std::cerr << __FILE__
": Could not get joint type from string \"" 105 << text <<
"\"." << std::endl;
const char * getJointTypeString(JointType type)
Return a string for the joint-type.
utils::Vector pos
The position of the node.
utils::Quaternion rot
This quaternion describes the orientation of the node.
NodeData is a struct to exchange node information between the GUI and the simulation.
void getAbsFromRel(const NodeData &node1, NodeData *node2)
get the absolute position of a new node by its relative position
void getRelFromAbs(const NodeData &node1, NodeData *node2)
Copyright 2012, DFKI GmbH Robotics Innovation Center.
JointType getJointType(const std::string &text)
Helper function to get type-id from string in scene file.
static const char * sJointTypeStrings[NUMBER_OF_JOINT_TYPES]