D3D10CreateDeviceAndSwapChain fails in debug mode

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

Recommended Posts

For a few weeks I have been developing only in release mode. I recently switched back to debug mode and found my previously working code failed. I have narrowed down the issue but have found it is not only present in the code I was working on, but all code (test code, old projects, sample code etc) on my machine.

The problem is that when D3D10CreateDeviceAndSwapChain is called in debug mode I get an E_FAIL error code (see error box attached). I.e. the code below (taken from a Frank Luna sample) fails:

    HR( D3D10CreateDeviceAndSwapChain(
md3dDriverType,
0,                 // no software device
D3D10_CREATE_DEVICE_DEBUG,
D3D10_SDK_VERSION,
&sd,
&mSwapChain,
&md3dDevice) );


However if I change the 4th argument to 0 everything works.

I can only think that either my graphics card is broken or the Direct X SDK or Direct X runtime is somehow corrupt. Has anyone got any suggestions as to what should be my next steps?

Ben.

Share on other sites

Yup - thats it.
KB 2670838 has stopped debug mode working. The link you pasted above leads on to a more detailed debate, but my solution was to uninstall this update and now everything works fine.

Going to switch off automatic updates from now on.

Thanks,

Ben.