DirectX10 Hardware and Reference Driver Types

Started by
0 comments, last by ET3D 15 years, 4 months ago
I was using code from the samples that come with the November 2008 SDK (I believe the most recent?). It is code to determine whether a hardware driver type or reference is available and then sets the driver type accordingly. // Store driver type choices in an array D3D10_DRIVER_TYPE driverTypes[] = { D3D10_DRIVER_TYPE_HARDWARE, D3D10_DRIVER_TYPE_REFERENCE, }; UINT numDriverTypes = sizeof(driverTypes) / sizeof(driverTypes[0]); // Check the Driver Types Avialable for(UINT driverTypeIndex = 0; driverTypeIndex < numDriverTypes; driverTypeIndex++) { g_driverType = driverTypes[driverTypeIndex]; // Set the driver type to hardware, then refer // Create the Device and Swap Chain using the selected driver type hr = D3D10CreateDeviceAndSwapChain( NULL, g_driverType, NULL, createDeviceFlags, D3D10_SDK_VERSION, &sd, &g_pSwapChain, &g_pd3dDevice ); // If the first selection (hardware) is successful then break if(SUCCEEDED(hr)) break; // If it did not succeed loop using the next driver type } I then checked my global driver type variable against D3D10_DRIVER_TYPE_HARDWARE to make sure I had a hardware driver type, and much to my surprise I do not. I am running Vista 64bit with an ATI Radeon HD 2600 with 512MB, I'm sure I should be able to use hardware. I asked someone that told me that there are two main reasons why the SDK code falls back to the ref device. 1. A problem with the swap chain description like an uninitialized field or a value that is beyond the hardware capacities. Fullscreen mode with a size that is not supported as example. 2. Your driver doesn’t support Direct3D 10. This is not unlikely for notebooks as they are often delivered with old drivers. I was running in fullscreen mode in 1280x800, but I put it back in Windowed mode and bumped it down to 1024x768. I also updated my drivers from ATI and I still can attain no hardware driver type. Any help would be much appreciated.
That which doesn't kill you makes you stronger.
Advertisement
Do other D3D10 programs, such as the samples, run in hardware?

If they do, then it's a problems with your program. Have you checked the return code (hr)?

This topic is closed to new replies.

Advertisement