OdometryROS: refactored imu sync (#331). Using tf to compute baseline if Rtabmap/ImagesAlreadyRectified is true (for convenience with realsense rectified IR images but right camera info Tx not set)

This commit is contained in:
matlabbe
2020-07-30 12:43:44 -04:00
parent 0f7044f6ff
commit ae854dfb4c
10 changed files with 134 additions and 30 deletions
+7 -1
View File
@@ -115,6 +115,7 @@ CoreWrapper::CoreWrapper() :
rate_(Parameters::defaultRtabmapDetectionRate()),
createIntermediateNodes_(Parameters::defaultRtabmapCreateIntermediateNodes()),
maxMappingNodes_(Parameters::defaultGridGlobalMaxNodes()),
alreadyRectifiedImages_(Parameters::defaultRtabmapImagesAlreadyRectified()),
previousStamp_(0),
mbClient_(0)
{
@@ -544,6 +545,10 @@ void CoreWrapper::onInit()
NODELET_INFO("Max mapping nodes = %d", maxMappingNodes_);
}
}
if(parameters_.find(Parameters::kRtabmapImagesAlreadyRectified()) != parameters_.end())
{
Parameters::parse(parameters_, Parameters::kRtabmapImagesAlreadyRectified(), alreadyRectifiedImages_);
}
if(paused_)
{
@@ -1334,7 +1339,8 @@ void CoreWrapper::commonStereoCallback(
right,
stereoModel,
tfListener_,
waitForTransform_?waitForTransformDuration_:0.0))
waitForTransform_?waitForTransformDuration_:0.0,
alreadyRectifiedImages_))
{
NODELET_ERROR("Could not convert stereo msgs! Aborting rtabmap update...");
return;