【问题标题】:Cannot include XACT3 header不能包含 XACT3 标头
【发布时间】:2013-05-11 14:20:03
【问题描述】:

我正在尝试在游戏项目中包含 xact3.h 头文件,但我不断收到一些与 mmreg.h 相关的错误

#include <xact3.h>
#include <Windows.h>

1>c:\program files\windows kits\8.0\include\shared\mmreg.h(2469): error C2332: 'struct' : missing tag name
1>c:\program files\windows kits\8.0\include\shared\mmreg.h(2469): warning C4094: untagged 'struct' declared no symbols
1>c:\program files\windows kits\8.0\include\shared\mmreg.h(2469): error C2143: syntax error : missing ';' before '__uuidof'
1>c:\program files\windows kits\8.0\include\shared\mmreg.h(2469): error C2059: syntax error : '__uuidof'
1>c:\program files\windows kits\8.0\include\shared\mmreg.h(2470): warning C4005: 'KSDATAFORMAT_SUBTYPE_PCM' : macro redefinition

以上是我得到的一些错误。如果相关,我正在使用 Windows 8。我已经尝试了很多东西,比如定义 WIN32_LEAN_AND_MEAN 或重新排列标题但没有成功。谁能告诉我可能是什么问题,我该如何解决?

【问题讨论】:

  • 你是说我应该将最低Windows版本设置为XP?我试过了,但出现以下错误:#error:“此版本的 XAudio2 仅在 Windows 8 或更高版本中可用。将 DirectX SDK 中的 XAudio2 标头和库与面向 Windows 7 和更早版本的应用程序一起使用。” c:\program files\windows kits\8.0\include\um\xaudio2.h'
  • 所以设置最小windows 8.

标签: audio windows-8 directx game-engine xact


【解决方案1】:

设法通过在 xact3 标头上方添加 XAudio2 标头来解决它

【讨论】:

    猜你喜欢
    • 2014-11-29
    • 1970-01-01
    • 1970-01-01
    • 2018-02-15
    • 2014-02-08
    • 1970-01-01
    • 1970-01-01
    • 2021-07-31
    • 2013-10-11
    相关资源
    最近更新 更多