Jump to content

  • Log In with Google      Sign In   
  • Create Account


Error Creating Debug Device


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • This topic is locked This topic is locked
12 replies to this topic

#1 Anoop Chauhan   Members   -  Reputation: 115

Like
0Likes
Like

Posted 03 January 2013 - 12:39 AM

I'm getting mad with following error:

Attempted to create a device with the debug layer enabled and the layer is not installed.

everytime I created D3D10 or D3D11 device with debug configuration, this function fails with E_FAIL, It is mind boggling , I ever tried  D3D10_CREATE_DEVICE_DEBUG flag to create dubug layer and I have also tried to enable it using DirectX control panel and it still didnt work. What should I do?



Sponsor:

#2 BenS1   Members   -  Reputation: 320

Like
3Likes
Like

Posted 03 January 2013 - 02:09 AM

The debug layer is not installed by default, you only get it if you install the developer runtime. You normally get the developer runtime though if you install the DirectX SDK or the Windows 8 SDK (Which now contains the DirectX SDK).

 

What OS are you on?

 

See this link: http://msdn.microsoft.com/en-us/library/windows/desktop/ff476881.aspx

 

It states: "Note  For Windows 8, to create a device that supports the debug layer, install the Windows Software Development Kit (SDK) for Windows 8 to get D3D11_1SDKLayers.dll."

 

Are you using a full version of Visual Studio, or an Express version?

 

Maybe you need to download the Windows 8 SDK separately and install that.

 

Thanks

Ben



#3 iedoc   Members   -  Reputation: 664

Like
1Likes
Like

Posted 03 January 2013 - 03:44 AM

I had this same exact problem, and helped others on gamedev with the same problem. what happened for me was that i installed a new version of directx over an older version, instead of completely uninstalling the older version first. have you recently updated your directx sdk? that might be the problem, and you might want to uninstall it completely and reinstall it again


Braynzar Soft - DirectX Lessons & Game Programming Resources!

#4 Anoop Chauhan   Members   -  Reputation: 115

Like
0Likes
Like

Posted 03 January 2013 - 10:29 PM

I reinstalled DXSDK but couldn't get it fixed. It's DirectX SDK June 2010 and I'm using Windows 7.
I guess the error is being caused by wrong configuration of VC++ runtimes on my machine. I have manually deleted and updated them
for many times
Any suggestion?  Thanks guys



#5 NewDisplayName   Members   -  Reputation: 351

Like
0Likes
Like

Posted 03 January 2013 - 10:39 PM

Try following steps :

 

1) Completely uninstall your Visual Studio (which version are you using btw?) and DirectX SDK.

2) Install Visual Studio 2010 first.

3) Then install DirectX SDK. Don't leave out any options while installing, just install the whole piece, even if you will never use some of its features.

4) Revisit your problem and see if you still face the issue.



#6 Anoop Chauhan   Members   -  Reputation: 115

Like
0Likes
Like

Posted 04 January 2013 - 02:46 AM

It wont get me anywhere. Uninstalling Visual Studio does not uninstall its all features and VC++ runtimes too then what benefit would I reap doing this? Does it seem to be dependency issue? Anyway I'll give it a try. Thanks
 



#7 NewDisplayName   Members   -  Reputation: 351

Like
0Likes
Like

Posted 04 January 2013 - 03:28 AM

Does it seem to be dependency issue?

It does actually. Also, there is a probability that your project is getting built in release mode, and it's ignoring all the debug level info from d3d.

Just check if that's not the case.



#8 BenS1   Members   -  Reputation: 320

Like
1Likes
Like

Posted 04 January 2013 - 06:00 AM

Can you check if you have D3D11SDKLayers.dll on your system. On my system I found it in the System32 and SysWOW64 directories, as well as in \Microsoft DirectX SDK (June 2010)\Developer Runtime\x86 and \Microsoft DirectX SDK (June 2010)\Developer Runtime\x64 directories.

 

Also when you run your app use something like SysInternals Process Explorer to see if the D3D11SDKLayers.dll is being loaded.

 

For example, when I run my game in Debug mode I can see from Process Explorer that the DLL is being loaded, and specifically I can see its the one from the SysWOW64 directory:

D3dDebugDLL.JPG

 

Thanks

Ben



#9 BenS1   Members   -  Reputation: 320

Like
1Likes
Like

Posted 04 January 2013 - 06:20 AM

Another tool to try is Depends.exe and tell it to profile your game. It'll then list all the DLLs loaded (Which tree of which DLLs loaded them).

 

Here is the output on mine:

Depends.jpg

 

Interestingly you can see that D3D11.dll tries to dynamically load D3D11SDKLayers.dll twice. The first time it tries to load if from my games directory, and fails (See the yellow circle with a question mark in it). The second time it loads it successfully from the SysWOW64 directory.

 

Try this with your app and see whether D3D11.dll is even trying to load the layers DLL and if it is where is it looking and failing.

 

Thanks

Ben



#10 Anoop Chauhan   Members   -  Reputation: 115

Like
0Likes
Like

Posted 05 January 2013 - 09:12 PM

Yeah Thanks Ben! Dependency Walker makes it clear to understand,
System loads all necessary load time dynamic dependecies to start application.
the actual cause is here
LoadLibraryExW("C:\Windows\system32\DXGIDebug.dll", 0x00000000, 0x00000000) returned NULL. Error: The specified module could not be found (126).
LoadLibraryExW("C:\Windows\system32\D3D11_1SDKLayers.dll", 0x00000000, 0x00000000) returned NULL. Error: The specified module could not be found (126).
 , its run time failure
I couldn't understand why system had tried to load D3d11_1SDKlayers.dll instead of D3D11SDKLayer.dll,

CaptureDepends2.JPGCaptureDepends.JPG



#11 Anoop Chauhan   Members   -  Reputation: 115

Like
0Likes
Like

Posted 06 January 2013 - 07:57 PM

I still could'nt fix my problem



#12 GraphicDNA   Members   -  Reputation: 125

Like
-1Likes
Like

Posted 04 October 2013 - 11:24 AM

I wrote a post about this topic. You basically need to install the correct SDK, as the DX SDK (June 2010) no longer installs the necessary components for debugging. You can read more here: http://graphicdna.blogspot.co.uk/2013/10/directx-control-panel-and-d3d-debug.html



#13 MJP   Moderators   -  Reputation: 10235

Like
0Likes
Like

Posted 04 October 2013 - 12:10 PM

Please don't bump such old threads.






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS