diff --git a/include/hpp/fcl/math/transform.h b/include/hpp/fcl/math/transform.h index d69941d997a6fa7f9c389253150207e981ff7503..a11dc55ccced115f65b975c15e4681f56709d92f 100644 --- a/include/hpp/fcl/math/transform.h +++ b/include/hpp/fcl/math/transform.h @@ -442,10 +442,10 @@ public: /// @brief set transform from rotation and translation inline void setTransform(const Matrix3f& R_, const Vec3f& T_) { - R = R_; - T = T_; - matrix_set = true; + R.noalias() = R_; + T.noalias() = T_; q.fromRotation(R_); + matrix_set = true; } /// @brief set transform from rotation and translation @@ -453,7 +453,7 @@ public: { matrix_set = false; q = q_; - T = T_; + T.noalias() = T_; } /// @brief set transform from rotation