Including headers from Windows 10 SDK

Started by
11 comments, last by そら 8 years, 8 months ago

Please clarify what "doesn't get included" means. Do you get an error? If so, what is the exact error message?

#Include <d3d12.h> doesn't work (or IntelliSense doesn't detect that.)

@Dave:
Am I supposed to include path to Windows 10 SDK manually? I don't have to do this with Windows 8 SDK.


You have to select the target platform in the project propriety window:

Cattura.png

I don't have that option in my visual studio (2013 community).

@Dave: ofcourse not.

2 IntelliSense: cannot open source file "d3d12.h" k:\Visual Studio Projects\NT Engine\Application\Application.cpp 2
Error 1 error C1083: Cannot open include file: 'd3d12.h': No such file or directory k:\visual studio projects\nt engine\application\application.cpp 2


I think I'll have to install Visual Studio 2015 (Community). But it's 3 GB only, how come it is supposed to have Windows SDK in it? (cause Windows SDK itself is around 2 GB)
BTW, I am downloading the .iso file and not the installer (vs_community.exe).

Thats because you need VS2015 which can compile for that target. It's only 3GB because the installer for the community edition has a downloaded built into the installer, same as the 2012 and 2013 versions.

The Target OS is something new in 2013 and will probably work the same as selecting your platform toolset even though the higher versions are installed you cannot select them in a lower VS version.

Worked on titles: CMR:DiRT2, DiRT 3, DiRT: Showdown, GRID 2, theHunter, theHunter: Primal, Mad Max, Watch Dogs: Legion

Advertisement

Please clarify what "doesn't get included" means. Do you get an error? If so, what is the exact error message?

#Include <d3d12.h> doesn't work (or IntelliSense doesn't detect that.)

@Dave:
Am I supposed to include path to Windows 10 SDK manually? I don't have to do this with Windows 8 SDK.


You have to select the target platform in the project propriety window:

Cattura.png

I don't have that option in my visual studio (2013 community).

@Dave: ofcourse not.

2 IntelliSense: cannot open source file "d3d12.h" k:\Visual Studio Projects\NT Engine\Application\Application.cpp 2
Error 1 error C1083: Cannot open include file: 'd3d12.h': No such file or directory k:\visual studio projects\nt engine\application\application.cpp 2


I think I'll have to install Visual Studio 2015 (Community). But it's 3 GB only, how come it is supposed to have Windows SDK in it? (cause Windows SDK itself is around 2 GB)
BTW, I am downloading the .iso file and not the installer (vs_community.exe).

Also, after upgrading to Windows 10, my D3D11CreateDevice() fails on debug .exe because in debug mode, I've this flag setup: D3D11_CREATE_DEVICE_DEBUG

This is what I get in logs:
D3D11CreateDevice: Flags (0x2) were specified which require the D3D11 SDK Layers for Windows 10, but they are not present on the system.
These flags must be removed, or the Windows 10 SDK must be installed.
Flags include: D3D11_CREATE_DEVICE_DEBUG
First-chance exception at 0x75283E28 in Application.exe: Microsoft C++ exception: _com_error at memory location 0x00C0E944.
I've Windows SDK 10 installed already but still it gives me that error. I am downloading VS 2015 and it'll take more time for me because of slow connection. I'll report back if all these errors are fixed in VS 2015.

You have to manually change the VC directories in your project. However, since you are using VS2013 Community, I suggest you to update to VS 2015 Community. Be sure also to not have any preview SDK installed.

"Recursion is the first step towards madness." - "Skegg?ld, Skálm?ld, Skildir ro Klofnir!"
Direct3D 12 quick reference: https://github.com/alessiot89/D3D12QuickRef/


D3D11CreateDevice: Flags (0x2) were specified which require the D3D11 SDK Layers for Windows 10, but they are not present on the system.
These flags must be removed, or the Windows 10 SDK must be installed.
Flags include: D3D11_CREATE_DEVICE_DEBUG
First-chance exception at 0x75283E28 in Application.exe: Microsoft C++ exception: _com_error at memory location 0x00C0E944.

Yep, you need to enable Graphics Toools:

DirectX SDK Debug Layer: For Windows 10 Technical Preview (9926 or later), you need to enable the debug layer as a Windows optional feature to successfully use D3D11_CREATE_DEBUG_DEVICE or the Visual Studio 2013 Graphics Diagnostics tools: Start -> Settings -> System -> Optional features -> Add a feature; select "Graphics Tools".

Check out: http://blogs.msdn.com/b/chuckw/archive/2014/10/03/windows-10-technical-preview.aspx

"lots of shoulddas, coulddas, woulddas in the air, thinking about things they shouldda couldda wouldda donne, however all those shoulddas coulddas woulddas ran away when they saw the little did to come"

This topic is closed to new replies.

Advertisement