-
-
Save hunandy14/c5a74e769bd29be3c6a36b139f044573 to your computer and use it in GitHub Desktop.
VS2019 設置 OpneCV 設置擋
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | |
<ImportGroup Label="PropertySheets"></ImportGroup> | |
<!-- 使用說明詳見:https://charlottehong.blogspot.com/2021/01/opencv-451-visual-studio-2019.html --> | |
<!-- 使用者自訂變數 --> | |
<PropertyGroup Label="UserMacros"> | |
<!-- 函式庫檔案,多個用分號隔開 --> | |
<cvLib_x64>opencv_world451.lib</cvLib_x64> | |
<cvLibd_x64>opencv_world451d.lib</cvLibd_x64> | |
<!-- OpenCV 路徑 --> | |
<cvDir>C:\opencv</cvDir> | |
<cvIncDir>$(cvDir)\build\include</cvIncDir> | |
<cvLibDir>$(cvDir)\build\x64\vc15\lib</cvLibDir> | |
<cvBibDir>$(cvDir)\build\x64\vc15\bin</cvBibDir> | |
<!-- $(UserRootDir) 是 V4.0 位置--> | |
</PropertyGroup> | |
<!-- Link檔案設置 --> | |
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> | |
<Link> | |
<AdditionalDependencies>$(cvLibd_x64);%(AdditionalDependencies)</AdditionalDependencies> | |
</Link> | |
</ItemDefinitionGroup> | |
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> | |
<Link> | |
<AdditionalDependencies>$(cvLib_x64);%(AdditionalDependencies)</AdditionalDependencies> | |
</Link> | |
</ItemDefinitionGroup> | |
<!-- include與Lib目錄 --> | |
<PropertyGroup> | |
<IncludePath>$(cvIncDir);$(VC_IncludePath);$(WindowsSDK_IncludePath)</IncludePath> | |
<LibraryPath>$(cvLibDir);$(VC_LibraryPath_x64);$(WindowsSDK_LibraryPath_x64)</LibraryPath> | |
</PropertyGroup> | |
<!-- 環境變數 --> | |
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> | |
<LocalDebuggerEnvironment>PATH=%PATH%;$(cvBibDir);</LocalDebuggerEnvironment> | |
</PropertyGroup> | |
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> | |
<LocalDebuggerEnvironment>PATH=%PATH%;$(cvBibDir);</LocalDebuggerEnvironment> | |
</PropertyGroup> | |
</Project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment