fixed "CameraModel() Condition (fx > 0.0) not met! [fx=0.000000]" error on appearance-based demo

This commit is contained in:
matlabbe
2020-02-21 10:45:54 -05:00
parent ee9d16994f
commit 7d0711878e
+7
View File
@@ -895,6 +895,12 @@ rtabmap::Signature nodeDataFromROS(const rtabmap_ros::NodeData & msg)
msg.fx.size() == msg.localTransform.size())
{
for(unsigned int i=0; i<msg.fx.size(); ++i)
{
if(msg.fx[i] == 0)
{
models.push_back(rtabmap::CameraModel());
}
else
{
models.push_back(rtabmap::CameraModel(
msg.fx[i],
@@ -907,6 +913,7 @@ rtabmap::Signature nodeDataFromROS(const rtabmap_ros::NodeData & msg)
}
}
}
}
rtabmap::Signature s(
msg.id,