mirror of
https://github.com/introlab/rtabmap_ros.git
synced 2026-10-04 00:37:46 +08:00
Fixed build with RTABMAP_SYNC_USER_DATA=ON. Fixed wordids!=descriptors error #659 when Mem/RawDescriptorsKept is false
This commit is contained in:
@@ -1067,7 +1067,7 @@ rtabmap::Signature nodeDataFromROS(const rtabmap_ros::NodeData & msg)
|
||||
{
|
||||
ROS_ERROR("Word IDs and 3D points should be the same size (%d, %d)!", (int)msg.wordIds.size(), (int)msg.wordPts.size());
|
||||
}
|
||||
if(wordsDescriptors.rows != (int)msg.wordIds.size())
|
||||
if(!wordsDescriptors.empty() && wordsDescriptors.rows != (int)msg.wordIds.size())
|
||||
{
|
||||
ROS_ERROR("Word IDs and descriptors should be the same size (%d, %d)!", (int)msg.wordIds.size(), wordsDescriptors.rows);
|
||||
wordsDescriptors = cv::Mat();
|
||||
|
||||
@@ -414,7 +414,7 @@ void CommonDataSubscriber::setupScanCallbacks(
|
||||
{
|
||||
subscribedToOdomInfo_ = true;
|
||||
odomInfoSub_.subscribe(nh, "odom_info", queueSize);
|
||||
SYNC_DECL3(dataScan2dInfo, approxSync, queueSize, userDataSub_, scanSub_, odomInfoSub_);
|
||||
SYNC_DECL3(CommonDataSubscriber, dataScan2dInfo, approxSync, queueSize, userDataSub_, scanSub_, odomInfoSub_);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user