implement the idea that row-vectors have the RowMajorBit and col-vectors don't.

This commit is contained in:
Benoit Jacob
2010-03-09 00:16:07 -05:00
parent b81351cb07
commit 74a7c5caee
6 changed files with 52 additions and 37 deletions

View File

@@ -32,8 +32,13 @@ template<typename T> struct NumTraits;
template<typename Derived> struct EigenBase;
template<typename _Scalar, int _Rows, int _Cols,
int _Options = EIGEN_DEFAULT_MATRIX_STORAGE_ORDER_OPTION | AutoAlign,
int _MaxRows = _Rows, int _MaxCols = _Cols> class Matrix;
int _Options = AutoAlign |
( (_Rows==1 && _Cols!=1) ? RowMajor
: (_Cols==1 && _Rows!=1) ? ColMajor
: EIGEN_DEFAULT_MATRIX_STORAGE_ORDER_OPTION ),
int _MaxRows = _Rows,
int _MaxCols = _Cols
> class Matrix;
template<typename ExpressionType, unsigned int Added, unsigned int Removed> class Flagged;
template<typename ExpressionType, template <typename> class StorageBase > class NoAlias;

View File

@@ -317,6 +317,7 @@ using Eigen::ei_cos;
#define EIGEN_ENUM_MAX(a,b) (((int)a >= (int)b) ? (int)a : (int)b)
#define EIGEN_LOGICAL_XOR(a,b) (((a) || (b)) && !((a) && (b)))
#define EIGEN_IMPLIES(a,b) (!(a) || (b))
#define EIGEN_MAKE_CWISE_BINARY_OP(METHOD,FUNCTOR) \
template<typename OtherDerived> \