Skip to content
Snippets Groups Projects
Commit 8cff599b authored by Rohan Budhiraja's avatar Rohan Budhiraja Committed by Olivier Stasse
Browse files

[c++] update the ostream output format for MatrixHomogeneous to [M,N]((,,,),(,,,),(,,,))

parent 198c54d6
No related branches found
No related tags found
No related merge requests found
......@@ -138,9 +138,21 @@ namespace Eigen {
/* \brief Eigen Homogeneous Matrix output
*
* Matrix format: [M,N]((val11,val12,val13,...,val1N),...,(valM1,valM2,...,valMN))
* e.g. [2,5]((1 23 32.2 12.12 32),(2 32 23 92.01 19.2))
*/
inline std::ostream& operator << (std::ostream &os,
Transform<double,3,Affine> MH) {
os << MH.matrix(); return os; }
IOFormat boostFmt(StreamPrecision, DontAlignCols,
",", ",",
"(",")",
"(",")");
os << "[4,4]"<< MH.matrix().format(boostFmt); return os; }
inline std::ostream& operator << (std::ostream &os,
......
......@@ -18,6 +18,7 @@
#ifndef DYNAMIC_GRAPH_LINEAR_ALGEBRA_H
#define DYNAMIC_GRAPH_LINEAR_ALGEBRA_H
#include <Eigen/Core>
#include <Eigen/Geometry>
namespace dynamicgraph {
typedef Eigen::MatrixXd Matrix;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment