文章目录
近年来,人工智能(AI)技术,尤其是大模型的快速发展,打开了全新的时代大门。对于想要在这个时代迅速成长并提升自身能力的个人而言,学会利用AI辅助学习已经成为一种趋势。不论是国内的文心一言、豆包,还是国外的ChatGPT、Claude,它们都能成为我们编程学习的有力助手。利用AI进行编程学习将大大提升自己的编程学习效率,这里给大家推荐一个我自己在用的集成了ChatGPT和Claude的网站(国内可用,站点稳定): 传送门
前言
在3D模型处理领域,MeshLab 是一款开源且功能强大的工具,被广泛用于点云处理、网格编辑和三维模型修复等任务。无论是科研工作者、开发者,还是设计师,MeshLab 都是处理复杂3D数据的得力助手💻✨。然而,这个软件在进行配置时可能会遇到一些问题🤔,并且网上现有的环境配置方案距离现在时间都较久,没有新的配置方案的出现,故现记录并分享一下我的配置过程📒。后续我还将持续更新MeshLab插件开发流程,如果你觉得这篇文章能够帮助你,欢迎大家订阅📮、点赞👍、收藏📂与关注🔔,你的鼓励和支持将是我创作的最大动力💪!
一、配置前的准备
1. cmake
具体安装请参阅:
Windows下的CMake详细安装教程(2024/1/24)_windows 安装cmake-CSDN博客
本次配置使用cmake版本为3.29.8
2. Visual Studio要修改带有【英语】语言
C/C++的包管理——Vcpkg(2024/01/25)-CSDN博客
本次配置使用VS2022
进行,具体如何修改语言选项请查阅上述文章
3. Git
这个安装过程由于本人博客未进行记录,请读者自行查阅安装配置过程
4. Qt
博主在此次配置过程使用的是Qt-5.15.2
,在meshlab官方教程中,写到:
MeshLab builds with the three major compilers:
gcc
,clang
, andmsvc
. It requires Qt 5.15, cmake and optionally ninja (required on windows). Only 64 bit is supported.
Qt安装过程本博客未进行记录,请自行查阅其他博主博客
应注意的是,目前没有看到meshlab支持Qt6的信息,尽管在其src
文件夹下的CmakeLists.txt
中写到:
find_package(
Qt5
COMPONENTS OpenGL Xml Network
REQUIRED)
if (Qt5_VERSION VERSION_LESS 5.15.0)
message(FATAL_ERROR "Minimum supported Qt5 version is 5.15!")
endif()
“Minimum supported Qt5 version is 5.15”最小Qt版本为5.15,但是如果你去使用Qt6来进行环境配置是会报错的,当然如果你熟悉整个meshlab流程框架,可以尝试修改该配置文件,利用Qt6去尝试,本文不再作这方面的任何讨论。
!!重点:安装完QT5之后,需要将QT5放到环境变量中,路径如:E:\myQt5\5.15.2\msvc2019_64\bin
二、配置流程
1.克隆meshlab源码
在git bash
中执行命令:
git clone --recursive https://github.com/cnr-isti-vclab/meshlab
其中--recursive
表示在克隆仓库时,同时递归地克隆该仓库包含的所有子模块。如果一个仓库有依赖的子模块(例如其他项目或者库),这些子模块不会自动被克隆。使用 --recursive
参数可以确保所有子模块在克隆主仓库时一起被下载。
当你看到有如下输入时代表你克隆成功,如有网络问题未能下载全部的源码及依赖,请自行解决:
35372@DESKTOP-498LBTQ MINGW64 /e/Learn_MeshLab
$ git clone --recursive https://github.com/cnr-isti-vclab/meshlab
Cloning into 'meshlab'...
warning: redirecting to https://github.com/cnr-isti-vclab/meshlab/
remote: Enumerating objects: 97464, done.
remote: Counting objects: 100% (2545/2545), done.
remote: Compressing objects: 100% (918/918), done.
remote: Total 97464 (delta 1706), reused 2370 (delta 1589), pack-reused 94919 (from 1)
Receiving objects: 100% (97464/97464), 298.28 MiB | 12.63 MiB/s, done.
Resolving deltas: 100% (65863/65863), done.
Updating files: 100% (4741/4741), done.
Submodule 'src/vcglib' (https://github.com/cnr-isti-vclab/vcglib) registered for path 'src/vcglib'
Cloning into 'E:/Learn_MeshLab/meshlab/src/vcglib'...
remote: Enumerating objects: 47043, done.
remote: Counting objects: 100% (3798/3798), done.
remote: Compressing objects: 100% (1741/1741), done.
remote: Total 47043 (delta 2142), reused 3611 (delta 2012), pack-reused 43245 (from 1)
Receiving objects: 100% (47043/47043), 44.76 MiB | 14.34 MiB/s, done.
Resolving deltas: 100% (31187/31187), done.
Submodule path 'src/vcglib': checked out '88c881d8393929c8e09b9df765ce8582bf386499'
网上有许多教程让你去下载meshlab
和vcg
两个库,并把vcg
放到meshlab
的src
下的vcglib
文件夹里,或者放到哪个额外的地方,实际上是并不需要的,只需要执行上述命令即可。
完成后,文件夹组织结构如下:
35372@DESKTOP-498LBTQ MINGW64 /e/Learn_MeshLab
$ tree -L 2
.
`-- meshlab
|-- CMakeLists.txt
|-- LICENSE.txt
|-- ML_VERSION
|-- README.md
|-- docs
|-- meshlab.png
|-- resources
|-- sample
|-- scripts
|-- snapcraft.yaml
|-- src
|-- textures
`-- unsupported
8 directories, 6 files
打开ML_VERSION
可以看到,本次配置的meshlab版本为2023.12
2.编译
正式编译前请先进行如下操作:
在meshlab
文件夹下新建build
文件夹和install
文件夹,在install
文件夹下新建plugins
文件夹
1.修改CmakeLists.txt
(可选)
在src
文件夹下存在一个CmakeLists.txt
文件,在开头写入如下命令:
cmake_minimum_required(VERSION 3.23)
cmake_policy(SET CMP0020 NEW)
参数解释:
-
cmake_minimum_required(VERSION 3.23)
: 指定项目所需的最低 CMake 版本为 3.23,这个可以不写,版本号也可以自己随意改。 -
cmake_policy(SET CMP0020 NEW)
: 启用处理 Qt 项目时的 Windows 自动链接功能,可加可不加,最后都可以运行成功,只是少了些警告。
除此之外还有一处需要设置cmake_policy(SET CMPxxxx NEW)的地方,读者可自行查阅cmake运行时的debug输出,自己练习一下,只需要将policy放在project之前即可。
注意,第一步的所有操作都是非必须的,读者可跳过进行下一步
2.进行编译
1)进入build
文件夹后,右键点击在终端打开
2)在打开的终端中使用cmake命令进行编译,命令行如下(注意最后一行命令是刚刚新建的install
文件夹路径):
cmake .. -G "Visual Studio 17 2022" -A x64 -DQt5_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5 -DQt5Core_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Core -DQt5Gui_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Gui -DQt5Network_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Network -DQt5OpenGL_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5OpenGL -DQt5Widgets_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Widgets -DQt5Xml_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Xml -DCMAKE_INSTALL_PREFIX=E:/Learn_MeshLab/meshlab/install -DMESHLAB_PLUGIN_INSTALL_DIR=E:/Learn_MeshLab/meshlab/install\plugins
将上述所有路径更换为自己的本地路径
参数解释:
cmake ..
: 告诉 CMake 查找项目的Cmake配置文件并生成构建文件。-G "Visual Studio 17 2022"
: 指定使用 Visual Studio 2022 来构建项目。-A x64
: 目标平台为 64 位。-DQt5_*_DIR=...
: 指定 Qt5 各个模块的路径,以确保项目可以找到所需的 Qt5 库。-DMESHLAB_PLUGIN_INSTALL_DIR=...
:用于存放meshlab插件(meshlab实现各类功能采用的是插件式)-DCMAKE_INSTALL_PREFIX=...
: 设置安装路径,项目完成编译后文件会被安装到这个位置。
在执行过程中,如果缺少一些库,meshlab中写入了自动下载库的过程,例如:
-- Could NOT find Boost (missing: Boost_INCLUDE_DIR thread)
-- Downloading Boost from https://boostorg.jfrog.io/artifactory/main/release/1.75.0/source/boost_1_75_0.zip
如果觉得下载太慢,可以使用我提供的网盘中的压缩包,将压缩包里的各文件放入path/to/your/meshlab/src/external/downloads
文件夹即可:点击获取
放入完成后,重新运行cmake命令即可,等待编译完成。
编译完成会有如下输出:
PS E:\Learn_MeshLab\meshlab\build> cmake .. -G "Visual Studio 17 2022" -A x64 -DQt5_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5 -DQt5Core_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Core -DQt5Gui_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Gui -DQt5Network_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Network -DQt5OpenGL_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5OpenGL -DQt5Widgets_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Widgets -DQt5Xml_DIR=E:/myQt5/5.15.2/msvc2019_64/lib/cmake/Qt5Xml -DCMAKE_INSTALL_PREFIX=E:/Learn_MeshLab/meshlab/install -DMESHLAB_PLUGIN_INSTALL_DIR=E:/Learn_MeshLab/meshlab/install\plugins
-- Selecting Windows SDK version 10.0.22621.0 to target Windows 10.0.22631.
-- The C compiler identification is MSVC 19.41.34123.0
-- The CXX compiler identification is MSVC 19.41.34123.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: E:/Data_vs2022E/Enterprise/VC/Tools/MSVC/14.41.34120/bin/Hostx64/x64/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: E:/Data_vs2022E/Enterprise/VC/Tools/MSVC/14.41.34120/bin/Hostx64/x64/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found OpenGL: opengl32
-- Found OpenMP_C: -openmp (found version "2.0")
-- Found OpenMP_CXX: -openmp (found version "2.0")
-- Found OpenMP: TRUE (found version "2.0")
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - not found
-- Found Threads: TRUE
-- Searching for required components with bundled fallback
-- - Eigen - using bundled source
-- - VCGLib - using bundled source
-- - VCGLib directory: E:/Learn_MeshLab/meshlab/src/vcglib
-- - GLEW - using bundled source
-- - EasyExif - using bundled source
-- Searching for optional components
-- Could NOT find Boost (missing: Boost_INCLUDE_DIR thread)
-- - Boost - using downloaded source
-- - CGAL - using downloaded source
CMake Warning at src/external/embree.cmake:13 (find_package):
By not providing "Findembree.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "embree", but
CMake did not find one.
Could not find a package configuration file provided by "embree" (requested
version 4) with any of the following names:
embreeConfig.cmake
embree-config.cmake
Add the installation prefix of "embree" to CMAKE_PREFIX_PATH or set
"embree_DIR" to a directory containing one of the above files. If "embree"
provides a separate development package or SDK, be sure it has been
installed.
Call Stack (most recent call first):
src/external/CMakeLists.txt:50 (include)
CMake Warning at src/external/embree.cmake:14 (find_package):
By not providing "FindTBB.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "TBB", but
CMake did not find one.
Could not find a package configuration file provided by "TBB" with any of
the following names:
TBBConfig.cmake
tbb-config.cmake
Add the installation prefix of "TBB" to CMAKE_PREFIX_PATH or set "TBB_DIR"
to a directory containing one of the above files. If "TBB" provides a
separate development package or SDK, be sure it has been installed.
Call Stack (most recent call first):
src/external/CMakeLists.txt:50 (include)
-- - embree - using downloaded dll
-- - levmar - using downloaded source
CMake Deprecation Warning at src/external/downloads/levmar-2.6.1/CMakeLists.txt:4 (CMAKE_MINIMUM_REQUIRED):
Compatibility with CMake < 3.5 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
CMake Warning (dev) at src/cmake/meshlab_tools.cmake:93 (_message):
The package name passed to `find_package_handle_standard_args` (LIB3DS)
does not match the name of the calling package (Lib3ds). This can lead to
problems in calling code that expects `find_package` result variables
(e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
E:/Data_cmake/share/cmake-3.29/Modules/FindPackageHandleStandardArgs.cmake:438 (message)
src/cmake/FindLib3ds.cmake:30 (find_package_handle_standard_args)
src/external/lib3ds.cmake:9 (find_package)
src/external/CMakeLists.txt:56 (include)
This warning is for project developers. Use -Wno-dev to suppress it.
-- Could NOT find LIB3DS (missing: LIB3DS_INCLUDE_DIR LIB3DS_LIBRARY)
-- - lib3ds - using downloaded source
-- - libigl - using downloaded source
-- Could NOT find muparser (missing: MUPARSER_INCLUDE_DIR MUPARSER_LIBRARY)
-- - muparser - using downloaded source
CMake Deprecation Warning at src/external/downloads/muparser-2.3.3-1/CMakeLists.txt:2 (cmake_minimum_required):
Compatibility with CMake < 3.5 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
-- - nexus - using downloaded source
CMake Deprecation Warning at src/external/downloads/nexus-master/CMakeLists.txt:2 (cmake_minimum_required):
Compatibility with CMake < 3.5 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
-- - Eigen - using bundled source
-- - VCGLib - jumped - already included
-- nexus - VCGLib - using custom VCGDIR path library
CMake Deprecation Warning at src/external/downloads/nexus-master/src/corto/CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 3.5 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
CMake Deprecation Warning at src/external/downloads/nexus-master/src/CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 3.5 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
-- - newuoa - using bundled source
-- Could NOT find OpenCTM (missing: OPENCTM_INCLUDE_DIR OPENCTM_LIBRARY)
-- - OpenCTM - using downloaded source
-- Could NOT find Qhull (missing: Qhull_DIR)
-- - qhull - using downloaded source
CMake Deprecation Warning at src/external/downloads/qhull-2020.2/CMakeLists.txt:71 (cmake_minimum_required):
Compatibility with CMake < 3.5 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
-- - Structure Synth - using downloaded source
-- Searching for required components
-- - tiny glTF - using downloaded source
-- - u3d - using downloaded source
-- Failed to find XercesC (missing: XercesC_LIBRARY XercesC_INCLUDE_DIR XercesC_VERSION)
-- - Xerces-C - using downloaded source
-- - libE57 - using downloaded source
-- MeshLab version: 2023.12
-- Building with single precision
--
Configuring plugins
-- - meshlabplugins/io_3ds
-- - meshlabplugins/io_base
-- - meshlabplugins/io_bre
-- - meshlabplugins/io_collada
-- - meshlabplugins/io_ctm
-- - meshlabplugins/io_e57
-- - meshlabplugins/io_expe
-- - meshlabplugins/io_gltf
-- - meshlabplugins/io_json
-- - meshlabplugins/io_pdb
-- - meshlabplugins/io_tri
-- - meshlabplugins/io_txt
-- - meshlabplugins/io_u3d
-- - meshlabplugins/io_x3d
-- - meshlabplugins/filter_sample
-- - meshlabplugins/filter_createiso
-- - meshlabplugins/filter_geodesic
-- - meshlabplugins/filter_sample_gpu
-- - meshlabplugins/filter_ao
-- - meshlabplugins/filter_camera
-- - meshlabplugins/filter_clean
-- - meshlabplugins/filter_color_projection
-- - meshlabplugins/filter_colorproc
-- - meshlabplugins/filter_create
-- - meshlabplugins/filter_cubization
-- - meshlabplugins/filter_developability
-- - meshlabplugins/filter_dirt
-- - meshlabplugins/filter_embree
-- - meshlabplugins/filter_fractal
-- - meshlabplugins/filter_func
-- - meshlabplugins/filter_img_patch_param
-- - meshlabplugins/filter_icp
-- - meshlabplugins/filter_io_nxs
-- - meshlabplugins/filter_isoparametrization
-- - meshlabplugins/filter_layer
-- - meshlabplugins/filter_measure
-- - meshlabplugins/filter_mesh_booleans
-- - meshlabplugins/filter_mesh_alpha_wrap
-- - meshlabplugins/filter_meshing
-- - meshlabplugins/filter_mls
-- - meshlabplugins/filter_mutualglobal
-- - meshlabplugins/filter_mutualinfo
-- - meshlabplugins/filter_parametrization
-- - meshlabplugins/filter_plymc
-- - meshlabplugins/filter_qhull
-- - meshlabplugins/filter_quality
-- - meshlabplugins/filter_sampling
-- - meshlabplugins/filter_screened_poisson
-- - meshlabplugins/filter_sdfgpu
-- - meshlabplugins/filter_select
-- - meshlabplugins/filter_sketchfab
-- - meshlabplugins/filter_ssynth
-- - meshlabplugins/filter_texture
-- - meshlabplugins/filter_texture_defragmentation
-- - meshlabplugins/filter_trioptimize
-- - meshlabplugins/filter_unsharp
-- - meshlabplugins/filter_voronoi
-- - meshlabplugins/render_gdp
-- - meshlabplugins/render_radiance_scaling
-- - meshlabplugins/decorate_base
-- - meshlabplugins/decorate_background
-- - meshlabplugins/decorate_raster_proj
-- - meshlabplugins/decorate_shadow
-- - meshlabplugins/edit_sample
-- - meshlabplugins/edit_align
-- - meshlabplugins/edit_manipulators
-- - meshlabplugins/edit_measure
-- - meshlabplugins/edit_mutualcorrs
-- - meshlabplugins/edit_paint
-- - meshlabplugins/edit_pickpoints
-- - meshlabplugins/edit_point
-- - meshlabplugins/edit_referencing
-- - meshlabplugins/edit_quality
-- - meshlabplugins/edit_select
-- Configuring done (116.6s)
-- Generating done (2.1s)
-- Build files have been written to: E:/Learn_MeshLab/meshlab/build
3.生成与问题解决
1.在build
文件夹中,双击生成的MeshLab.sln
,打开后展开CMakePredefinedTargets
,对ALL_BUILD
右键,点击生成
。
可以看到,在首次生成完成后,会出现报错:
解决方案如下:
①设置项目选择方式为当前选定内容
②双击报错行,可以看到,已经定位到报错项目meshlab-common-gui
③打开项目属性,找到C/C++
–>命令行
–>添加/utf-8
,应用后关闭属性页
④对ALL_BUILD
右键,点击重新生成
,待重新生成后,可以看到:
note:至此,Meshlab的环境配置已经基本结束。
写这篇博客的原因是因为换了台新机子,想记录一下,方便以后查阅与帮助后来者少走弯路,到这虽然基本配置已经结束,但还请继续往下看,还有其他问题有待解决。
4.在完成上述步骤之后,可以看到,install/plugins
文件夹下并没有任何插件生成(空文件夹),此时需要做的是:
在INSTALL
上右键选择生成
此时,可以看到,plugins
文件夹下生成了各类功能插件dll
,共74
项
同时,向上一级文件夹(install
)中看,可以看到,已经生成了meshlab.exe
这时候双击该程序,即可正常打开并使用。
5.但这个时候还并不完美,我们希望能够调试程序来供我们学习,此时在VS中,将meshlab
项目设置为启动项,并进行调试,可以看到dll的报错。
报错及解决方案:
报错1 :meshlab.exe-系统错误
由于找不到 Qt5widgetsd.dll,无法继续执行代码。重新安装程序可能会解决此问题。
报错2 : meshlab.exe-系统错误
由于找不到 Qt5Networkd.dll,无法继续执行代码。重新安装程序可能会解决
此问题。
报错3 : meshlab.exe-系统错误
由于找不到 Qt5OpenGLd.dll,无法继续执行代码。重新安装程序可能会解决此问题。
报错4 :meshlab.exe-系统错误
由于找不到 Qt5Guid.d,无法继续执行代码。重新资装程序可能会解决此问题。
解决方案 :
先来说一下这种报错产生的原因,为什么在install
文件夹中双击meshlab.exe
没有问题,反而利用VS进行调试的时候有问题呢?
这是因为当你直接双击 meshlab.exe
运行程序时,程序会在系统的环境变量中查找所需的 DLL 文件,包括你已经添加到系统 PATH
中的 Qt 库路径 E:\myQt5\5.15.2\msvc2019_64\bin
。然而,当你在VS中调试程序时,调试器并不会完全继承系统的环境变量。VS的调试环境是独立的,为了提供一个可控的调试环境,它允许开发者在项目属性中指定调试时使用的环境变量。这意味着即使系统环境变量中已经包含了必要的路径,调试器可能仍然无法访问,导致程序在调试时无法找到 Qt 的 DLL 文件,从而报错。
这种报错是比较好解决的,在VS中,打开meshlab
的项目属性,在调试
–>环境
中添加:
PATH=%PATH%;E:\myQt5\5.15.2\msvc2019_64\bin
注意修改为自己的本地路径。其他解决方案可以参考MeshLab 2022.02 源码编译教程_meshlab编译-CSDN博客,本文不再赘述。
此时可以正常打开:
6.但是有个问题,可以看到,工具栏中并没有预想的那样加载出来plugins
,在meshlab
项目属性的常规属性中可以看到,其输出目录为E:\Learn_MeshLab\meshlab\build\src\distrib\Debug
,在distrib
文件夹中存在一个plugins
文件夹,里边的内容都是全的,与install
下的plugins
文件夹里的内容相同。
为了能让meshlab每次调试启动时正确加载plugins,在plugins_manager.cpp
文件的第158行处的loadPlugins
函数开头添加如下代码:
#if _DEBUG
pluginsDirectory.cd("Debug");
#else
pluginsDirectory.cd("Release")
#endif
这时候再次进行调试,可以发现能正常调试,但是会报几个小warning:
我们将distrib
文件夹中的如下dll
复制放到该目录下的Debug
文件夹
再次进行调试,则会发现所有错误和警告已经全部消失
,可以正常进行二次开发。
7.如果觉得太过麻烦,可以将VS中的meshlab
项目的常规属性的输出目录设置为E:\Learn_MeshLab\meshlab\install
,此时不用作任何调整即可调试运行,看自己的选择。
这么做的具体原因不再赘述,请读者自行探索。
最后,进行调试前将VS的meshlab
项目的配置属性中链接器
–>系统
–>子系统
设置为
控制台 (/SUBSYSTEM:CONSOLE)
🎉 至此,我们已经完整地梳理了 MeshLab 的配置流程!
不管你是否已经成功编译,如果成功了,给自己一个大大的👍吧!在这个教程中,你深入了解了 CMake 与 Visual Studio 的项目编译过程,已经有了显著的成长。接下来,你可以继续阅读和调试代码,探索更多的可能性。
如果还没有成功,也不要灰心放弃,多多尝试!✨ 编译是一个枯燥且考验耐心的过程,不可能一蹴而就。过程中可能会遇到各种奇奇怪怪的问题,有些甚至是作者都未曾预料到的。需要我们像侦探一样,一点点消除这些 bug,多利用网络资源,亲自动手解决问题,这样才能加深对项目编译的理解。
当遇到问题时,可以到项目的 Issues 中寻找答案,或直接向作者提问。除了 GitHub,国外的 Stack Overflow 也是一个查找问题的好地方。
总之,保持耐心,花时间去解决问题,多做记录,积累经验,才能更好地成长!💪
转载请注明出处
作者:BQ
主页:bqcode.blog.csdn.net
公众号:BQ经验书
QQ群:958124241
Learn Together!