首页 > 其他分享 >vcpkg在vs2022下integrate install之后仍找不到第三方库的解决方案

vcpkg在vs2022下integrate install之后仍找不到第三方库的解决方案

时间:2024-05-29 22:11:15浏览次数:15  
标签:install vcpkg pcl integrate include cloud

首先是vcpkg的安装,许多其他帖子都有,从github上拉取下来之后运行bootstrap-vcpkg.bat即可。不再赘述。
接下来是使用部分,假设需要安装pcl库。
在vs2022的开发者powershell中输入vcpkg install pcl

此时下载完成,成功拉取了pcl包。
接下来按照教程所说为在vs2022的开发者powershell中输入vcpkg integrate install之后即可使用

当让如果此时能够成功过调用那么恭喜你不用往下看了。但是实际上笔者在这里卡住了三天,因为一直显示无法找到pcl文件。
最终解决无法找到文件的方法为右键点击解决方案进入属性

在包含目录中添加下图中的路径

在库目录中添加

之后保存设置即可。
所以到最终其实vcpkg integrate install还是没有完成环境变量的设置,需要手动添加。
最后附上测试代码,中间的ply文件需自定义路径,其他的没什么,只有手动导入vcpkg路径这里是一个大坑,因为官方教程表示vcpkg integrate install之后就万事大吉

#include <string>
#include <pcl/point_types.h>
#include <pcl/octree/octree.h>
#include <pcl/filters/random_sample.h>
#include <pcl/filters/filter_indices.h>

#include <pcl/io/ply_io.h>
#include <vector>
//#include"Frame.h"
//#include"encode.h"
//#include <pcl/visualization/cloud_viewer.h>



typedef pcl::PointXYZRGB RGB_Cloud;
typedef pcl::PointCloud<RGB_Cloud> point_cloud;
typedef point_cloud::Ptr cloud_pointer;
typedef point_cloud::Ptr prevCloud;



int main(){
        pcl::PointCloud<pcl::PointXYZRGB>::Ptr cloud(new pcl::PointCloud<pcl::PointXYZRGB>);

        pcl::PLYReader plyRead;
        plyRead.read ("D:\\longdress\\longdress\\Ply\\longdress_vox10_1051.ply", *cloud);
        std::cout << cloud->points.size() << std::endl;//输出点云数


        int a;
        
        }

标签:install,vcpkg,pcl,integrate,include,cloud
From: https://www.cnblogs.com/wxL-videostreaming/p/18221204

相关文章

  • pip install . 和 pip install -e . 的区别
    pipinstall.和pipinstall-e.都用于将当前目录下的项目安装为Python包,但它们之间有一些区别。pipinstall.:这个命令会将项目打包并安装在Python环境中,项目的文件将被复制到Python的site-packages目录中。安装后,您可以在Python中导入该包并使用其中的功能。这种方式适......
  • webstrom中npm install err 问题
    npmERR!pathD:\gitcode\yoyochatroom1.0\YoYo_Chat_Room/package.json这里的package.json终端显示没有路径,因为需项目具有package.json的文件中开启终端那么我们在设置中找到设置找到终端启动目录就可以了。如果还有问题可以在排卵期聊。......
  • Inno Setup Dependency Installer 安装包 运行环境安装
    Downloadandinstallanydependencysuchas.NET,VisualC++orSQLServerduringyourapplication'sinstallation!Inthisarticle,youwillseeinstallation,usage,integration,details,anddependenciesofInnoSetupDependencyInstaller.Downlo......
  • Windows pyinstaller wxPython pyecharts无法正常显示问题
    WindowspyinstallerwxPythonpyecharts无法正常显示问题最近遇到一个pyinstaller打包wxPythonpyecharts无法显示的问题,pyecharts生成的html页面显示空白。未使用pyinstaller打包时显示正常。问题原因WebViewBackendDefault=b''WebViewBackendEdge=b'wxWebViewEdge'Web......
  • pyinstaller 打包无窗口python http.server无法启动
    最近在写一个简单的文件服务器用来访问静态文件,遇到在pyinstaller无窗口模式下无法启动的问题,记录一下解决方案。原因:http.server需要将记录输出到窗口,而pyinstaller打包无窗口模式没有地方输出classBaseHTTPRequestHandler(socketserver.StreamRequestHandler):.........
  • How to Install LibreOffice on Ubuntu
    HowtoInstallLibreOfficeonUbuntuBYHAROONJAVEDPUBLISHEDDEC30,2023 LookingforasimplealternativetoMicrosoftOfficeonLinux?StartbyinstallingLibreOffice.CorbinDavenport/TheDocumentFoundationQuickLinksWhatIsLibreOffice?......
  • Docker系列---【/usr/bin/docker-current: Error response from daemon: shim error:
    1.报错信息dockerrun创建新容器时报错/usr/bin/docker-current:Errorresponsefromdaemon:shimerror:docker-runcnotinstalledonsystem.2.解决方案[root@localhost~]#cd/usr/libexec/docker/[root@localhost~]#sudoln-sdocker-runc-currentdocker-runc......
  • 问题2:yum install pstree无法安装
    解决办法1.查找pstree命令在哪个包内,执行命令:yum provideslsof2.找到对应的包名:执行安装命令:yuminstallpsmisc3.结果再次执行pstree查看命令执行情况  ......
  • vue搭建脚手架 出现问题Command vue init requires a global addon to be installed.
    使用vue-cli脚手架命令vueinitwebpackmy-App创建项目回车时显示Commandvueinitrequiresa global addontobeinstalled.Pleaserun yarn globaladd@vue/cli-initandtryagain. 解决方法:npminstall-g@vue/cli-init 然后创建项目,正常。 ......
  • Mac install omicverse second time
    安装老版本的omicverse后发现scvelomodule缺少,再单独安装scvelo,更新了一些包后ov不能用了,于是重新安装!幸好mac的conda安装非常友好按照安装文档https://omicverse.readthedocs.io/en/latest/Installation_guild/#4-after-the-installation-of-pytorch-we-can-start-to-install-......