File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -154,6 +154,12 @@ template <> VectorQuaternion random<VectorQuaternion>() {
154154template <> MatrixRotation random<MatrixRotation>() {
155155 return MatrixRotation (random<VectorQuaternion>());
156156}
157+ template <> MatrixHomogeneous random<MatrixHomogeneous>() {
158+ MatrixHomogeneous matrix_homo;
159+ matrix_homo.translation () = Eigen::Vector3d::Random ();
160+ matrix_homo.linear () = random<MatrixRotation>();
161+ return matrix_homo;
162+ }
157163
158164template <typename type> bool compare (const type &a, const type &b) {
159165 return a.isApprox (b);
@@ -189,5 +195,8 @@ BOOST_AUTO_TEST_CASE(quaternion_rpy) {
189195BOOST_AUTO_TEST_CASE (matrix_quaternion) {
190196 test_impl<MatrixToQuaternion, QuaternionToMatrix>();
191197}
198+ BOOST_AUTO_TEST_CASE (matrixHomo_poseQuaternion) {
199+ test_impl<MatrixHomoToPoseQuaternion, PoseQuaternionToMatrixHomo>();
200+ }
192201
193202BOOST_AUTO_TEST_SUITE_END ()
You can’t perform that action at this time.
0 commit comments