首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >在Windows 10上构建OBS-Studio时出现编译时错误

在Windows 10上构建OBS-Studio时出现编译时错误
EN

Stack Overflow用户
提问于 2021-01-14 19:48:47
回答 1查看 194关注 0票数 1

我正在尝试通过以下官方步骤来构建obs-studio

https://github.com/obsproject/obs-studio/wiki/Install-Instructions#windows-build-directions

我使用cmake GUI生成Visual Studio项目。当我试图在Visual Studio中构建项目时,我得到了以下错误

代码语言:javascript
复制
Severity    Code    Description Project File    Line    Suppression State
Error   C2039   'IsCursorCaptureEnabled': is not a member of 'winrt::Windows::Graphics::Capture::GraphicsCaptureSession'    libobs-winrt    C:\Users\alokm\obs-studio\libobs-winrt\winrt-capture.cpp    290 

Error   C2039   'IsCursorCaptureEnabled': is not a member of 'winrt::Windows::Graphics::Capture::GraphicsCaptureSession'    libobs-winrt    C:\Users\alokm\obs-studio\libobs-winrt\winrt-capture.cpp    372 

Error   C2039   'IsCursorCaptureEnabled': is not a member of 'winrt::Windows::Graphics::Capture::GraphicsCaptureSession'    libobs-winrt    C:\Users\alokm\obs-studio\libobs-winrt\winrt-capture.cpp    473 

我如何解决这些错误?

以下是我的Visual Studio详细信息

代码语言:javascript
复制
Microsoft Visual Studio Community 2019
Version 16.8.4
VisualStudio.16.Release/16.8.4+30907.101
Microsoft .NET Framework
Version 4.8.04084

Installed Version: Community

Visual C++ 2019   00435-60000-00000-AA868
Microsoft Visual C++ 2019

ASP.NET and Web Tools 2019   16.8.557.25636
ASP.NET and Web Tools 2019

Azure App Service Tools v3.0.0   16.8.557.25636
Azure App Service Tools v3.0.0

C# Tools   3.8.0-5.20604.10+9ed4b774d20940880de8df1ca8b07508aa01c8cd
C# components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.

Common Azure Tools   1.10
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

IntelliCode Extension   1.0
IntelliCode Visual Studio Extension Detailed Info

Microsoft JVM Debugger   1.0
Provides support for connecting the Visual Studio debugger to JDWP compatible Java Virtual Machines

Microsoft MI-Based Debugger   1.0
Provides support for connecting Visual Studio to MI compatible debuggers

Microsoft Visual C++ Wizards   1.0
Microsoft Visual C++ Wizards

Microsoft Visual Studio VC Package   1.0
Microsoft Visual Studio VC Package

NuGet Package Manager   5.8.1
NuGet Package Manager in Visual Studio. For more information about NuGet, visit https://docs.nuget.org/

ProjectServicesPackage Extension   1.0
ProjectServicesPackage Visual Studio Extension Detailed Info

Test Adapter for Boost.Test   1.0
Enables Visual Studio's testing tools with unit tests written for Boost.Test.  The use terms and Third Party Notices are available in the extension installation directory.

Test Adapter for Google Test   1.0
Enables Visual Studio's testing tools with unit tests written for Google Test.  The use terms and Third Party Notices are available in the extension installation directory.

Visual Basic Tools   3.8.0-5.20604.10+9ed4b774d20940880de8df1ca8b07508aa01c8cd
Visual Basic components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.

Visual C++ for Linux Development   1.0.9.30608
Visual C++ for Linux Development

Visual F# Tools   16.8.0-beta.20507.4+da6be68280c89131cdba2045525b80890401defd
Microsoft Visual F# Tools

Visual Studio Code Debug Adapter Host Package   1.0
Interop layer for hosting Visual Studio Code debug adapters in Visual Studio

Visual Studio Tools for CMake   1.0
Visual Studio Tools for CMake
EN

回答 1

Stack Overflow用户

发布于 2021-01-14 22:34:50

更新Windows SDK并删除过时的版本将解决所有错误。

在Visual Studio中,打开Tools > Get Tools and Features > Individual components

用"Windows SDK“搜索,然后选择最新的Windows 10 SDK,取消选择旧版本,然后单击modify

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/65718410

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档