Blender V2.61 - r43446

traits.h

Go to the documentation of this file.
00001 
00004 #ifndef KDLPV_TRAITS_H 
00005 #define KDLPV_TRAITS_H 
00006 
00007 #include "utility.h"
00008 
00009  
00010 // forwards declarations :
00011 namespace KDL {
00012    class Frame;
00013     class Rotation;
00014     class Vector;
00015     class Twist;
00016     class Wrench;
00017     class FrameVel;
00018     class RotationVel;
00019     class VectorVel;
00020     class TwistVel;
00021 }
00022 
00023 
00040 template <typename T>
00041 struct Traits {
00042     typedef T valueType;
00043     typedef T derivType;
00044 };
00045 
00046 template <>
00047 struct Traits<KDL::Frame> {
00048     typedef KDL::Frame valueType;
00049     typedef KDL::Twist derivType;
00050 };
00051 template <>
00052 struct Traits<KDL::Twist> {
00053     typedef KDL::Twist valueType;
00054     typedef KDL::Twist derivType;
00055 };
00056 template <>
00057 struct Traits<KDL::Wrench> {
00058     typedef KDL::Wrench valueType;
00059     typedef KDL::Wrench derivType;
00060 };
00061 
00062 template <>
00063 struct Traits<KDL::Rotation> {
00064     typedef KDL::Rotation valueType;
00065     typedef KDL::Vector derivType;
00066 };
00067 
00068 template <>
00069 struct Traits<KDL::Vector> {
00070     typedef KDL::Vector valueType;
00071     typedef KDL::Vector derivType;
00072 };
00073 
00074 template <>
00075 struct Traits<double> {
00076     typedef double valueType;
00077     typedef double derivType;
00078 };
00079 
00080 template <>
00081 struct Traits<float> {
00082     typedef float valueType;
00083     typedef float derivType;
00084 };
00085 
00086 template <>
00087 struct Traits<KDL::FrameVel> {
00088     typedef KDL::Frame valueType;
00089     typedef KDL::TwistVel derivType;
00090 };
00091 template <>
00092 struct Traits<KDL::TwistVel> {
00093     typedef KDL::Twist valueType;
00094     typedef KDL::TwistVel derivType;
00095 };
00096 
00097 template <>
00098 struct Traits<KDL::RotationVel> {
00099     typedef KDL::Rotation valueType;
00100     typedef KDL::VectorVel derivType;
00101 };
00102 
00103 template <>
00104 struct Traits<KDL::VectorVel> {
00105     typedef KDL::Vector valueType;
00106     typedef KDL::VectorVel derivType;
00107 };
00108 
00109 
00110 
00111 #endif
00112 
00113 
00114