ORB-SLAM3 atal error: opencv/cv.h: 没有那个文件或目录
时间: 2023-11-22 14:11:31 浏览: 169
opencv编译时缺少的文件
这个错误提示 "fatal error: opencv/cv.h: 没有那个文件或目录" 表明在编译过程中找不到 "opencv/cv.h" 这个头文件。根据引用的内容,可以尝试将文件中的 "#include <opencv/cv.h>" 替换为 "#include <opencv2/opencv.hpp>"。另外,引用中提到,如果你要使用自己指定路径的opencv-4.2.0,可以在CMakeList.txt文件中添加以下指令:set(CMAKE_PREFIX_PATH "/home/wangyy/opencv4")。这样编译器就能找到正确的opencv路径并包含相应的头文件。希望这些信息对解决你的问题有所帮助。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* *2* [fatal error: opencv/cv.h: 没有那个文件或目录 错误;fatal error: opencv2/contrib/contrib.hpp: 没有...](https://blog.csdn.net/pvmsmfchcs/article/details/128658681)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
- *3* [ORBSLAM3和配套file:///home/nsvi/ORB_SLAM3-master.zippangolin](https://download.csdn.net/download/weixin_41623823/85346807)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文