Commit 2274608e authored by Iulian Grindeanu's avatar Iulian Grindeanu

add deprecated attribute, and doxygen comments

duplicate code, but it will be deprecated anyway
using delegating constructors is allowed in c++11 and up
parent f7e9c090
......@@ -346,21 +346,33 @@ public:
}
}
// will be deprecated in future versions
// assumes that the input vectors are rows
template< typename Vector>
inline Matrix3( const Vector & row0,
const Vector & row1,
const Vector & row2) {
_mat << row0[0], row0[1], row0[2],
row1[0], row1[1], row1[2],
row2[0], row2[1], row2[2];
}
#ifdef __GNUC__
#define DEPRECATED __attribute__((deprecated))
#else
#pragma message("WARNING: You need to implement DEPRECATED for this compiler")
#define DEPRECATED
#endif
/*
* \deprecated { Use instead the constructor with explicit fourth argument, bool isRow, above }
*
*/
template< typename Vector>
inline DEPRECATED Matrix3( const Vector & row0,
const Vector & row1,
const Vector & row2)
{
_mat << row0[0], row0[1], row0[2],
row1[0], row1[1], row1[2],
row2[0], row2[1], row2[2];
}
#undef DEPRECATED
inline Matrix3( const double v[9] ){
_mat << v[0], v[1], v[2],
v[3], v[4], v[5],
v[6], v[7], v[8];
}
inline Matrix3& operator=( const Matrix3& m ){
_mat = m._mat;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment