Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #include "kinfam_io.hpp"
00023 #include "frames_io.hpp"
00024
00025 namespace KDL {
00026 std::ostream& operator <<(std::ostream& os, const Joint& joint) {
00027 return os << joint.getName()<<":["<<joint.getTypeName()
00028 <<", axis: "<<joint.JointAxis() << ", origin"<<joint.JointOrigin()<<"]";
00029 }
00030
00031 std::istream& operator >>(std::istream& is, Joint& joint) {
00032 return is;
00033 }
00034
00035 std::ostream& operator <<(std::ostream& os, const Segment& segment) {
00036 os << segment.getName()<<":[" << segment.getJoint() << ",\n tip: \n" << segment.getFrameToTip() << "]";
00037 return os;
00038 }
00039
00040 std::istream& operator >>(std::istream& is, Segment& segment) {
00041 return is;
00042 }
00043
00044 std::ostream& operator <<(std::ostream& os, const Chain& chain) {
00045 os << "[";
00046 for (unsigned int i = 0; i < chain.getNrOfSegments(); i++)
00047 os << chain.getSegment(i) << "\n";
00048 os << "]";
00049 return os;
00050 }
00051
00052 std::istream& operator >>(std::istream& is, Chain& chain) {
00053 return is;
00054 }
00055
00056 std::ostream& operator <<(std::ostream& os, const Tree& tree) {
00057 SegmentMap::const_iterator root = tree.getRootSegment();
00058 return os << root;
00059 }
00060
00061 std::ostream& operator <<(std::ostream& os, SegmentMap::const_iterator root) {
00062
00063 os << root->first<<"(q_nr: "<<root->second.q_nr<<")"<<"\n \t";
00064 for (unsigned int i = 0; i < root->second.children.size(); i++) {
00065 os <<(root->second.children[i])<<"\t";
00066 }
00067 return os << "\n";
00068 }
00069
00070 std::istream& operator >>(std::istream& is, Tree& tree) {
00071 return is;
00072 }
00073
00074 std::ostream& operator <<(std::ostream& os, const JntArray& array) {
00075 os << "[";
00076 for (unsigned int i = 0; i < array.rows(); i++)
00077 os << std::setw(KDL_FRAME_WIDTH) << array(i);
00078 os << "]";
00079 return os;
00080 }
00081
00082 std::istream& operator >>(std::istream& is, JntArray& array) {
00083 return is;
00084 }
00085
00086 std::ostream& operator <<(std::ostream& os, const Jacobian& jac) {
00087 os << "[";
00088 for (unsigned int i = 0; i < jac.rows(); i++) {
00089 for (unsigned int j = 0; j < jac.columns(); j++)
00090 os << std::setw(KDL_FRAME_WIDTH) << jac(i, j);
00091 os << std::endl;
00092 }
00093 os << "]";
00094 return os;
00095 }
00096
00097 std::istream& operator >>(std::istream& is, Jacobian& jac) {
00098 return is;
00099 }
00100 std::ostream& operator <<(std::ostream& os, const JntSpaceInertiaMatrix& jntspaceinertiamatrix) {
00101 os << "[";
00102 for (unsigned int i = 0; i < jntspaceinertiamatrix.rows(); i++) {
00103 for (unsigned int j = 0; j < jntspaceinertiamatrix.columns(); j++)
00104 os << std::setw(KDL_FRAME_WIDTH) << jntspaceinertiamatrix(i, j);
00105 os << std::endl;
00106 }
00107 os << "]";
00108 return os;
00109 }
00110
00111 std::istream& operator >>(std::istream& is, JntSpaceInertiaMatrix& jntspaceinertiamatrix) {
00112 return is;
00113 }
00114 }
00115