I am a little bit confused, because I have ever assigned DIRECT3D_VERSION, which is $900. Also in all my books and samples $900 is used...Budman's dxdriver also use it.
But the DX reference says really there must be D3D_SDK_VERSION assiged, which is 32 on my installation...
But the DX reference says really there must be D3D_SDK_VERSION assiged, which is 32 on my installation...
Create an IDirect3D9 object as shown here: LPDIRECT3D9 g_pD3D = NULL; if( NULL == (g_pD3D = Direct3DCreate9(D3D_SDK_VERSION))) return E_FAIL;
/*==========================================================================; * * Copyright (C) Microsoft Corporation. All Rights Reserved. * * File: d3d9.h * Content: Direct3D include file * ****************************************************************************/ #ifndef _D3D9_H_ #define _D3D9_H_ #ifndef DIRECT3D_VERSION #define DIRECT3D_VERSION 0x0900 #endif //DIRECT3D_VERSION // include this file content only if compiling for DX9 interfaces #if(DIRECT3D_VERSION >= 0x0900) /* ... */ #ifdef D3D_DEBUG_INFO #define D3D_SDK_VERSION (32 | 0x80000000) #define D3D9b_SDK_VERSION (31 | 0x80000000) #else #define D3D_SDK_VERSION 32 #define D3D9b_SDK_VERSION 31 #endif