diff --git a/cpp/sophus/linalg/homogeneous.h b/cpp/sophus/linalg/homogeneous.h index 4c1eb0fc..91ee26c2 100644 --- a/cpp/sophus/linalg/homogeneous.h +++ b/cpp/sophus/linalg/homogeneous.h @@ -29,7 +29,8 @@ auto proj(Eigen::MatrixBase const& p) /// point: (z*a, z*b, z). Z defaults to 1. template auto unproj( - Eigen::MatrixBase const& p, const typename TPoint::Scalar& z = 1.0) + Eigen::MatrixBase const& p, + const typename TPoint::Scalar& z = typename TPoint::Scalar(1.0)) -> Eigen::Vector { using Scalar = typename TPoint::Scalar; static_assert(TPoint::ColsAtCompileTime == 1, "p must be a column-vector");