deform_skeleton.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. #ifndef IGL_DEFORM_SKELETON_H
  2. #define IGL_DEFORM_SKELETON_H
  3. #include "igl_inline.h"
  4. #include <Eigen/Core>
  5. #include <Eigen/Geometry>
  6. #include <vector>
  7. namespace igl
  8. {
  9. // Deform a skeleton.
  10. //
  11. // Inputs:
  12. // C #C by 3 list of joint positions
  13. // BE #BE by 2 list of bone edge indices
  14. // vA #BE list of bone transformations
  15. // Outputs
  16. // CT #BE*2 by 3 list of deformed joint positions
  17. // BET #BE by 2 list of bone edge indices (maintains order)
  18. //
  19. IGL_INLINE void deform_skeleton(
  20. const Eigen::MatrixXd & C,
  21. const Eigen::MatrixXi & BE,
  22. const std::vector<
  23. Eigen::Affine3d,Eigen::aligned_allocator<Eigen::Affine3d> > & vA,
  24. Eigen::MatrixXd & CT,
  25. Eigen::MatrixXi & BET);
  26. // Inputs:
  27. // T #BE*4 by 3 list of stacked transformation matrix
  28. IGL_INLINE void deform_skeleton(
  29. const Eigen::MatrixXd & C,
  30. const Eigen::MatrixXi & BE,
  31. const Eigen::MatrixXd & T,
  32. Eigen::MatrixXd & CT,
  33. Eigen::MatrixXi & BET);
  34. }
  35. #ifndef IGL_STATIC_LIBRARY
  36. # include "deform_skeleton.cpp"
  37. #endif
  38. #endif