mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 00:37:51 -06:00
Added helper functions to extract euler angles from 3d transforms
This commit is contained in:
parent
d843f1a76f
commit
9bb93cc4f4
4 changed files with 61 additions and 46 deletions
|
@ -172,6 +172,14 @@ void assemble_transform(Transform3d& transform, const Vec3d& translation = Vec3d
|
|||
// 4) rotate Z
|
||||
// 5) translate
|
||||
Transform3d assemble_transform(const Vec3d& translation = Vec3d::Zero(), const Vec3d& rotation = Vec3d::Zero(), const Vec3d& scale = Vec3d::Ones());
|
||||
|
||||
// Returns the euler angles extracted from the given rotation matrix
|
||||
// Warning -> The matrix should not contain any scale or shear !!!
|
||||
Vec3d extract_euler_angles(const Eigen::Matrix<double, 3, 3, Eigen::DontAlign>& rotation_matrix);
|
||||
|
||||
// Returns the euler angles extracted from the given affine transform
|
||||
// Warning -> The transform should not contain any shear !!!
|
||||
Vec3d extract_euler_angles(const Transform3d& transform);
|
||||
} }
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue