把ros部分的代码放在主工程里去编译,结果在
ai@ai-OMEN:~/workspace/ORB_SLAM3$ ./build/bin/Mono_Inertial ./Vocabulary/ORBvoc.txt ./Examples/ROS/ORB_SLAM3/mtuav.yaml
ORB-SLAM3 Copyright © 2017-2020 Carlos Campos, Richard Elvira, Juan J. Gómez, José M.M. Montiel and Juan D. Tardós, University of Zaragoza.
ORB-SLAM2 Copyright © 2014-2016 Raúl Mur-Artal, José M.M. Montiel and Juan D. Tardós, University of Zaragoza.
This program comes with ABSOLUTELY NO WARRANTY;
This is free software, and you are welcome to redistribute it
under certain conditions. See LICENSE.txt.
Input sensor was set to: Monocular-Inertial
Segmentation fault (core dumped)
这里是因为在
cv::FileStorage fsSettings(strSettingsFile.c_str(), cv::FileStorage::READ);
一直报内存错误。
解决办法:把主工程的cmakelist ros的cmakelist dbow的cmakelist 的opencv版本全部统一在4.