mirror of
https://github.com/introlab/rtabmap_ros.git
synced 2026-10-04 00:37:46 +08:00
Fixed node ID=0 issues as msgs may not have seq. (#1202)
(cherry picked from commit 097cab0667)
This commit is contained in:
@@ -1778,10 +1778,7 @@ void CoreWrapper::commonSensorDataCallback(
|
||||
}
|
||||
|
||||
SensorData data = rtabmap_conversions::sensorDataFromROS(*sensorDataMsg);
|
||||
if(lastPoseIntermediate_)
|
||||
{
|
||||
data.setId(-1);
|
||||
}
|
||||
data.setId(lastPoseIntermediate_?-1:0);
|
||||
|
||||
OdometryInfo odomInfo;
|
||||
if(odomInfoMsg.get())
|
||||
@@ -2282,7 +2279,7 @@ void CoreWrapper::process(
|
||||
}
|
||||
|
||||
// If not intermediate node
|
||||
if(data.id() > 0)
|
||||
if(data.id() >= 0)
|
||||
{
|
||||
localizationDiagnostic_.updateStatus(rtabmap_.getStatistics().localizationCovariance(), twoDMapping_);
|
||||
tick(stamp, rate_>0?rate_:1000.0/(timeMsgConversion+timeRtabmap+timeUpdateMaps+timePublishMaps));
|
||||
|
||||
Reference in New Issue
Block a user