aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/Product.h
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2008-06-15 08:33:44 +0000
committerGravatar Gael Guennebaud <g.gael@free.fr>2008-06-15 08:33:44 +0000
commitfbbd8afe3086cc1a1f455cc5264f0b6fc063f8b6 (patch)
tree48a7af7b7060033a3555c74be3a73fc7c638fcf2 /Eigen/src/Core/Product.h
parent4af7089ab82583d39cc6fa1679a1406fb1185da5 (diff)
Started a Transform class in the Geometry module to represent
homography. Fix indentation in Quaternion.h
Diffstat (limited to 'Eigen/src/Core/Product.h')
-rw-r--r--Eigen/src/Core/Product.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/Eigen/src/Core/Product.h b/Eigen/src/Core/Product.h
index 39bda7e6e..6c653a558 100644
--- a/Eigen/src/Core/Product.h
+++ b/Eigen/src/Core/Product.h
@@ -269,6 +269,10 @@ template<typename Lhs, typename Rhs, int EvalMode> class Product : ei_no_assignm
{
return m_lhs.coeff(row, col) * m_rhs.coeff(col, col);
}
+ else if ((Lhs::Flags&Diagonal)==Diagonal)
+ {
+ return m_lhs.coeff(row, row) * m_rhs.coeff(row, col);
+ }
else
{
Scalar res;
@@ -286,7 +290,7 @@ template<typename Lhs, typename Rhs, int EvalMode> class Product : ei_no_assignm
{
if ((Rhs::Flags&Diagonal)==Diagonal)
{
- assert((_LhsNested::Flags&RowMajorBit)==0);
+ ei_assert((_LhsNested::Flags&RowMajorBit)==0);
return ei_pmul(m_lhs.template packetCoeff<LoadMode>(row, col), ei_pset1(m_rhs.coeff(col, col)));
}
else