Posted by
g.bartoli on
URL: http://official-rtab-map-forum.206.s1.nabble.com/Compile-RTAB-Map-with-additional-libraries-tp731p735.html
1) Ok, I'm planning to use the compiled RTAB-Map library via a ROS node with rtabmap_ros, so OpenNI2 should be ok with it. After I compiled RTAB-Map library, I will compile rtabmap_ros, too.
2) I compiled g2o from source and now RTAB-Map cmake finds it, thanks!
3) Thanks, I will take a look at that link!
4*) Is cvsba also needed for Vertigo? I also compiled and installed the cvsba library, but RTAB-Map cmake still cannot find it, so I ignored it for now.
So, now that OpenCV, g2o, GTSAM and Qt are successfully built and recognized by RTAB-Map, I tried to compile it with make, but I receive a lot of GTSAM-related errors like the following ones:
In file included from /usr/local/include/gtsam/geometry/Pose2.h:24:0,
from /home/vision/Libraries/rtabmap/corelib/src/Graph.cpp:71:
/usr/local/include/gtsam/base/Matrix.h: In function ‘void gtsam::inplace_QR(MATRIX&)’:
/usr/local/include/gtsam/base/Matrix.h:316:71: error: expected ‘;’ before ‘::’ token
Eigen::internal::householder_qr_inplace_blocked<MATRIX, HCoeffsType>::run(A, hCoeffs, 48, temp.data());
[...]
In file included from /usr/local/include/gtsam/geometry/Pose3.h:30:0,
from /home/vision/Libraries/rtabmap/corelib/src/Graph.cpp:72:
/usr/local/include/gtsam/geometry/Rot3.h: In static member function ‘static gtsam::Rot3 gtsam::Rot3::rodriguez(double, double, double)’:
/usr/local/include/gtsam/geometry/Rot3.h:197:51: error: no matching function for call to ‘gtsam::Rot3::rodriguez(Eigen::CommaInitializer<Eigen::Matrix<double, -1, 1> >&)’
{ return rodriguez((Vector(3) << wx, wy, wz));}
^
/usr/local/include/gtsam/geometry/Rot3.h:197:51: note: candidates are:
/usr/local/include/gtsam/geometry/Rot3.h:164:17: note: static gtsam::Rot3 gtsam::Rot3::rodriguez(const Vector&, double)
static Rot3 rodriguez(const Vector& w, double theta);
[...]
/home/vision/Libraries/rtabmap/corelib/src/Graph.cpp:1345:35: error: ‘const class gtsam::Value’ has no member named ‘cast’
gtsam::Pose3 p = iter->value.cast<gtsam::Pose3>();
Maybe RTAB-Map does not compile with the latest GTSAM 3.2.1?
Thanks
~Guido