IKTrajectoryHelper.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536
  1. #ifndef IK_TRAJECTORY_HELPER_H
  2. #define IK_TRAJECTORY_HELPER_H
  3. enum IK2_Method
  4. {
  5. IK2_JACOB_TRANS=0,
  6. IK2_PURE_PSEUDO,
  7. IK2_DLS,
  8. IK2_SDLS ,
  9. IK2_DLS_SVD,
  10. IK2_VEL_DLS,
  11. IK2_VEL_DLS_WITH_ORIENTATION,
  12. IK2_VEL_DLS_WITH_NULLSPACE,
  13. IK2_VEL_DLS_WITH_ORIENTATION_NULLSPACE,
  14. };
  15. class IKTrajectoryHelper
  16. {
  17. struct IKTrajectoryHelperInternalData* m_data;
  18. public:
  19. IKTrajectoryHelper();
  20. virtual ~IKTrajectoryHelper();
  21. bool computeIK(const double endEffectorTargetPosition[3],
  22. const double endEffectorTargetOrientation[4],
  23. const double endEffectorWorldPosition[3],
  24. const double endEffectorWorldOrientation[4],
  25. const double* q_old, int numQ, int endEffectorIndex,
  26. double* q_new, int ikMethod, const double* linear_jacobian, const double* angular_jacobian, int jacobian_size, const double dampIk[6]);
  27. bool computeNullspaceVel(int numQ, const double* q_current, const double* lower_limit, const double* upper_limit, const double* joint_range, const double* rest_pose);
  28. };
  29. #endif //IK_TRAJECTORY_HELPER_H