From 5e635f9ca104fe17ae651b63536df1fdffaee54e Mon Sep 17 00:00:00 2001 From: Valentin Roussellet Date: Tue, 21 Jul 2015 16:42:52 +0000 Subject: AlignedVector3 accepts implicit conversions from more operators. --- unsupported/Eigen/AlignedVector3 | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'unsupported/Eigen/AlignedVector3') diff --git a/unsupported/Eigen/AlignedVector3 b/unsupported/Eigen/AlignedVector3 index 93b017437..ca647eab3 100644 --- a/unsupported/Eigen/AlignedVector3 +++ b/unsupported/Eigen/AlignedVector3 @@ -105,7 +105,7 @@ template class AlignedVector3 }; template - inline explicit AlignedVector3(const MatrixBase& other) + inline AlignedVector3(const MatrixBase& other) { generic_assign_selector::run(*this,other.derived()); } @@ -113,6 +113,12 @@ template class AlignedVector3 inline AlignedVector3& operator=(const AlignedVector3& other) { m_coeffs = other.m_coeffs; return *this; } + template + inline AlignedVector3& operator=(const MatrixBase& other) + { + generic_assign_selector::run(*this,other.derived()); + return *this; + } inline AlignedVector3 operator+(const AlignedVector3& other) const { return AlignedVector3(m_coeffs + other.m_coeffs); } @@ -153,7 +159,7 @@ template class AlignedVector3 m_coeffs /= norm(); } - inline AlignedVector3 normalized() + inline AlignedVector3 normalized() const { return AlignedVector3(m_coeffs / norm()); } -- cgit v1.2.3