Tesseract
Motion Planning Environment
Loading...
Searching...
No Matches
kdl_utils.h
Go to the documentation of this file.
1
26#ifndef TESSERACT_KINEMATICS_KDL_UTILS_H
27#define TESSERACT_KINEMATICS_KDL_UTILS_H
28
31#include <kdl/frames.hpp>
32#include <kdl/jntarray.hpp>
33#include <Eigen/Eigen>
35
42
44{
50void KDLToEigen(const KDL::Frame& frame, Eigen::Isometry3d& transform);
51
57void EigenToKDL(const Eigen::Isometry3d& transform, KDL::Frame& frame);
58
64void KDLToEigen(const KDL::Jacobian& jacobian, Eigen::Ref<Eigen::MatrixXd> matrix);
65
72void KDLToEigen(const KDL::Jacobian& jacobian, const std::vector<int>& q_nrs, Eigen::Ref<Eigen::MatrixXd> matrix);
73
79void EigenToKDL(const Eigen::Ref<const Eigen::VectorXd>& vec, KDL::JntArray& joints);
80
86void KDLToEigen(const KDL::JntArray& joints, Eigen::Ref<Eigen::VectorXd> vec);
87
95{
96 KDL::Chain robot_chain;
97 KDL::Tree kdl_tree;
98 std::vector<std::string> joint_names;
99 std::string base_link_name;
100 std::string tip_link_name;
101 std::map<std::string, int> segment_index;
102 std::vector<std::pair<std::string, std::string>> chains;
103};
104
113bool parseSceneGraph(KDLChainData& results,
115 const std::vector<std::pair<std::string, std::string>>& chains);
116
125bool parseSceneGraph(KDLChainData& results,
127 const std::string& base_name,
128 const std::string& tip_name);
129} // namespace tesseract_kinematics
130#endif // TESSERACT_KINEMATICS_KDL_UTILS_H
Definition: graph.h:125
results transform[0]
Definition: collision_core_unit.cpp:144
A basic scene graph using boost.
auto scene_graph
Definition: ikfast_kinematics_7dof_unit.cpp:51
Eigen::MatrixXd jacobian
Definition: kinematics_core_unit.cpp:153
Common Tesseract Macros.
#define TESSERACT_COMMON_IGNORE_WARNINGS_PUSH
Definition: macros.h:71
Definition: create_convex_hull.cpp:36
Definition: forward_kinematics.h:44
bool parseSceneGraph(KDLChainData &results, const tesseract_scene_graph::SceneGraph &scene_graph, const std::vector< std::pair< std::string, std::string > > &chains)
Parse KDL chain data from the scene graph.
Definition: kdl_utils.cpp:79
void KDLToEigen(const KDL::Frame &frame, Eigen::Isometry3d &transform)
Convert KDL::Frame to Eigen::Isometry3d.
Definition: kdl_utils.cpp:31
void EigenToKDL(const Eigen::Isometry3d &transform, KDL::Frame &frame)
Convert Eigen::Isometry3d to KDL::Frame.
Definition: kdl_utils.cpp:44
The KDLChainData struct.
Definition: kdl_utils.h:95
std::vector< std::string > joint_names
List of joint names.
Definition: kdl_utils.h:98
KDL::Tree kdl_tree
KDL tree object.
Definition: kdl_utils.h:97
KDL::Chain robot_chain
KDL Chain object.
Definition: kdl_utils.h:96
std::string tip_link_name
Link name of last kink in the kinematic object.
Definition: kdl_utils.h:100
std::vector< std::pair< std::string, std::string > > chains
Definition: kdl_utils.h:102
std::string base_link_name
Link name of first link in the kinematic object.
Definition: kdl_utils.h:99
std::map< std::string, int > segment_index
A map from chain link name to kdl chain segment number.
Definition: kdl_utils.h:101
Common Tesseract Types.
Common Tesseract Utility Functions.
Kinematics types.
Kinematics utility functions.
object joints["j_1"]
Definition: tesseract_scene_graph_serialization_unit.cpp:224