DX11 No visualizations at first when using DirectX SDK

This topic is 472 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

Recommended Posts

I tried to run some of RasterTek's DirectX 11 tutorials using the obsolete DirectX SDK (June 2010). When I run these tutorials (as-is) my screen becomes completely black on my notebook (i.e. so no visualizations). My notebook also seems unresponsive for a few seconds while pushing CTRL+ALT+DELETE. Finally, CTRL+ALT+DELETE works and after re-clicking the application icon (so that it has focus again), the application and visualizations work fine.

Any ideas why this does not work out of the box?

Edited by matt77hias

Share on other sites

Could be a problem with your laptop. You mean you get this problem when you run any executable provided by rastertek tutorials only? Did you compile that executable yourself or you downloaded it from the website?

Share on other sites

Could be a problem with your laptop. You mean you get this problem when you run any executable provided by rastertek tutorials only? Did you compile that executable yourself or you downloaded it from the website?

Tried an exe. Works fine.

My own compiled exe's seem not to work. I only updated the platform while importing the solution in Visual Studio 2017 and added the Include/Libs to the DXSDK.

Share on other sites
added the Include/Libs to the DXSDK

Probably that's your problem. Visual Studio comes with DirectX since a few years ago. Mixing them together is just asking for trouble.

Edited by Zaoshi Kaba

Share on other sites
Probably that's your problem. Visual Studio comes with DirectX since a few years ago. Mixing them together is just asking for trouble.

I have no issues running my own programs using Direct3D 11 and the obsolete DirectX 9 SDK. I never used the obsolete DirectX 11 SDK before, so RasterTek's tutorials are the first ones I tried.

I do not see why "Mixing them together is just asking for trouble" since it is only a matter of including and linking libs in Visual Studio. Besides Direct3D 11 seems rather a subset of the full DirectX 11 SDK.

Edited by matt77hias

Share on other sites

The installation of DXSDK_Jun10 returned a failure code, but I presume this is due to the deprecation policy of Microsoft. Besides all the content seems to be present and in the right directories (even the environment variable is set).

Share on other sites
Probably that's your problem. Visual Studio comes with DirectX since a few years ago.

Yeah spot on.

I had similar issues setting up a DX project recently. By default your VS project properties probably have the following include and lib directories:

• c:\Program Files (x86)\Windows Kits\[some version]\Include\
• c:\Program Files (x86)\Windows Kits\[some version]\lib\winv6.3\x64

Or something similar, I think there are around three Include directories and a couple of lib directories. This is where the current version of DirectX is kept and your project is probably linking against these instead of the June 2010 SDK.

To prevent this from happening, under your project's Include & Lib directories you can uncheck the 'Inherit from parent or project defaults' checkbox. Note that you'll probably still need to explicitly include $(VC_IncludePath), and have$(VC_LibraryPath_x64) for your libs... it's the Windows SDK stuff you want to avoid.

Hope that helps!

Edited by Orangeatang

Share on other sites
Or something similar, I think there are around three Include directories and a couple of lib directories. So this is where the latest version of DirectX is kept so you project is probably linking against these instead of the June 2010 SDK.

Removed all the SDK paths under VC++ directories. But what is now the alternative for windows.h?

Edited by matt77hias

Share on other sites

Ah you probably still need the following include directory:

• c:\Program Files (x86)\Windows Kits\8.1\Include\um\

Since that's where Windows.h, you really just want to make sure that you're including and linking against the June 2010 SDK and not the Windows Kit SDK for DirectX.

Share on other sites
Since that's where Windows.h, you really just want to make sure that you're including and linking against the June 2010 SDK and not the Windows Kit SDK for DirectX.

I needed to add a few more, but now it compiles again :)

• Executable Directories: $(VC_ExecutablePath_x86);$(VS_ExecutablePath);C:\Program Files (x86)\Windows Kits\8.1\bin\x86;$(MSBuild_ExecutablePath);$(SystemRoot)\SysWow64;$(FxCopDir);$(PATH);
• Include Directories: $(DXSDK_DIR)Include;$(VC_IncludePath);C:\Program Files (x86)\Windows Kits\8.1\Include\um;C:\Program Files (x86)\Windows Kits\8.1\Include\shared
• Library Directories: $(DXSDK_DIR)Lib\x86\;$(VC_LibraryPath_x86);\$(NETFXKitsDir)Lib\um\x86;C:\Program Files (x86)\Windows Kits\8.1\Lib\winv6.3\um\x86

Unfortunately, the result is pretty much the same. (I think the order matters, so if you place DXSDK first, there will be no conflict with the Windows SDK)

My .sln can be found here: https://www.dropbox.com/s/zzscgq9oxcbz74u/Engine.zip?dl=0

Edited by matt77hias

1. 1
2. 2
Rutin
19
3. 3
4. 4
frob
13
5. 5

• 9
• 18
• 11
• 9
• 17
• Forum Statistics

• Total Topics
632605
• Total Posts
3007371

×