home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the 3D Game Programming Gurus / gurus.iso / DirectX / dx9sdkcp.exe / SDK (C++) / Include / d3d9.h < prev    next >
Encoding:
C/C++ Source or Header  |  2002-12-04  |  93.9 KB  |  1,668 lines

  1. /*==========================================================================;
  2.  *
  3.  *  Copyright (C) Microsoft Corporation.  All Rights Reserved.
  4.  *
  5.  *  File:   d3d9.h
  6.  *  Content:    Direct3D include file
  7.  *
  8.  ****************************************************************************/
  9.  
  10. #ifndef _D3D9_H_
  11. #define _D3D9_H_
  12.  
  13. #ifndef DIRECT3D_VERSION
  14. #define DIRECT3D_VERSION         0x0900
  15. #endif  //DIRECT3D_VERSION
  16.  
  17. // include this file content only if compiling for DX9 interfaces
  18. #if(DIRECT3D_VERSION >= 0x0900)
  19.  
  20.  
  21. /* This identifier is passed to Direct3DCreate9 in order to ensure that an
  22.  * application was built against the correct header files. This number is
  23.  * incremented whenever a header (or other) change would require applications
  24.  * to be rebuilt. If the version doesn't match, Direct3DCreate9 will fail.
  25.  * (The number itself has no meaning.)*/
  26.  
  27. #define D3D_SDK_VERSION 31
  28.  
  29.  
  30. #include <stdlib.h>
  31.  
  32. #define COM_NO_WINDOWS_H
  33. #include <objbase.h>
  34.  
  35. #include <windows.h>
  36.  
  37. #if !defined(HMONITOR_DECLARED) && (WINVER < 0x0500)
  38.     #define HMONITOR_DECLARED
  39.     DECLARE_HANDLE(HMONITOR);
  40. #endif
  41.  
  42. #define D3DAPI WINAPI
  43.  
  44. /*
  45.  * Interface IID's
  46.  */
  47. #if defined( _WIN32 ) && !defined( _NO_COM)
  48.  
  49. /* IID_IDirect3D9 */
  50. /* {81BDCBCA-64D4-426d-AE8D-AD0147F4275C} */
  51. DEFINE_GUID(IID_IDirect3D9, 0x81bdcbca, 0x64d4, 0x426d, 0xae, 0x8d, 0xad, 0x1, 0x47, 0xf4, 0x27, 0x5c);
  52.  
  53. /* IID_IDirect3DDevice9 */
  54. // {D0223B96-BF7A-43fd-92BD-A43B0D82B9EB} */
  55. DEFINE_GUID(IID_IDirect3DDevice9, 0xd0223b96, 0xbf7a, 0x43fd, 0x92, 0xbd, 0xa4, 0x3b, 0xd, 0x82, 0xb9, 0xeb);
  56.  
  57. /* IID_IDirect3DResource9 */
  58. // {05EEC05D-8F7D-4362-B999-D1BAF357C704}
  59. DEFINE_GUID(IID_IDirect3DResource9, 0x5eec05d, 0x8f7d, 0x4362, 0xb9, 0x99, 0xd1, 0xba, 0xf3, 0x57, 0xc7, 0x4);
  60.  
  61. /* IID_IDirect3DBaseTexture9 */
  62. /* {580CA87E-1D3C-4d54-991D-B7D3E3C298CE} */
  63. DEFINE_GUID(IID_IDirect3DBaseTexture9, 0x580ca87e, 0x1d3c, 0x4d54, 0x99, 0x1d, 0xb7, 0xd3, 0xe3, 0xc2, 0x98, 0xce);
  64.  
  65. /* IID_IDirect3DTexture9 */
  66. /* {85C31227-3DE5-4f00-9B3A-F11AC38C18B5} */
  67. DEFINE_GUID(IID_IDirect3DTexture9, 0x85c31227, 0x3de5, 0x4f00, 0x9b, 0x3a, 0xf1, 0x1a, 0xc3, 0x8c, 0x18, 0xb5);
  68.  
  69. /* IID_IDirect3DCubeTexture9 */
  70. /* {FFF32F81-D953-473a-9223-93D652ABA93F} */
  71. DEFINE_GUID(IID_IDirect3DCubeTexture9, 0xfff32f81, 0xd953, 0x473a, 0x92, 0x23, 0x93, 0xd6, 0x52, 0xab, 0xa9, 0x3f);
  72.  
  73. /* IID_IDirect3DVolumeTexture9 */
  74. /* {2518526C-E789-4111-A7B9-47EF328D13E6} */
  75. DEFINE_GUID(IID_IDirect3DVolumeTexture9, 0x2518526c, 0xe789, 0x4111, 0xa7, 0xb9, 0x47, 0xef, 0x32, 0x8d, 0x13, 0xe6);
  76.  
  77. /* IID_IDirect3DVertexBuffer9 */
  78. /* {B64BB1B5-FD70-4df6-BF91-19D0A12455E3} */
  79. DEFINE_GUID(IID_IDirect3DVertexBuffer9, 0xb64bb1b5, 0xfd70, 0x4df6, 0xbf, 0x91, 0x19, 0xd0, 0xa1, 0x24, 0x55, 0xe3);
  80.  
  81. /* IID_IDirect3DIndexBuffer9 */
  82. /* {7C9DD65E-D3F7-4529-ACEE-785830ACDE35} */
  83. DEFINE_GUID(IID_IDirect3DIndexBuffer9, 0x7c9dd65e, 0xd3f7, 0x4529, 0xac, 0xee, 0x78, 0x58, 0x30, 0xac, 0xde, 0x35);
  84.  
  85. /* IID_IDirect3DSurface9 */
  86. /* {0CFBAF3A-9FF6-429a-99B3-A2796AF8B89B} */
  87. DEFINE_GUID(IID_IDirect3DSurface9, 0xcfbaf3a, 0x9ff6, 0x429a, 0x99, 0xb3, 0xa2, 0x79, 0x6a, 0xf8, 0xb8, 0x9b);
  88.  
  89. /* IID_IDirect3DVolume9 */
  90. /* {24F416E6-1F67-4aa7-B88E-D33F6F3128A1} */
  91. DEFINE_GUID(IID_IDirect3DVolume9, 0x24f416e6, 0x1f67, 0x4aa7, 0xb8, 0x8e, 0xd3, 0x3f, 0x6f, 0x31, 0x28, 0xa1);
  92.  
  93. /* IID_IDirect3DSwapChain9 */
  94. /* {794950F2-ADFC-458a-905E-10A10B0B503B} */
  95. DEFINE_GUID(IID_IDirect3DSwapChain9, 0x794950f2, 0xadfc, 0x458a, 0x90, 0x5e, 0x10, 0xa1, 0xb, 0xb, 0x50, 0x3b);
  96.  
  97. /* IID_IDirect3DVertexDeclaration9 */
  98. /* {DD13C59C-36FA-4098-A8FB-C7ED39DC8546} */
  99. DEFINE_GUID(IID_IDirect3DVertexDeclaration9, 0xdd13c59c, 0x36fa, 0x4098, 0xa8, 0xfb, 0xc7, 0xed, 0x39, 0xdc, 0x85, 0x46);
  100.  
  101. /* IID_IDirect3DVertexShader9 */
  102. /* {EFC5557E-6265-4613-8A94-43857889EB36} */
  103. DEFINE_GUID(IID_IDirect3DVertexShader9, 0xefc5557e, 0x6265, 0x4613, 0x8a, 0x94, 0x43, 0x85, 0x78, 0x89, 0xeb, 0x36);
  104.  
  105. /* IID_IDirect3DPixelShader9 */
  106. /* {6D3BDBDC-5B02-4415-B852-CE5E8BCCB289} */
  107. DEFINE_GUID(IID_IDirect3DPixelShader9, 0x6d3bdbdc, 0x5b02, 0x4415, 0xb8, 0x52, 0xce, 0x5e, 0x8b, 0xcc, 0xb2, 0x89);
  108.  
  109. /* IID_IDirect3DStateBlock9 */
  110. /* {B07C4FE5-310D-4ba8-A23C-4F0F206F218B} */
  111. DEFINE_GUID(IID_IDirect3DStateBlock9, 0xb07c4fe5, 0x310d, 0x4ba8, 0xa2, 0x3c, 0x4f, 0xf, 0x20, 0x6f, 0x21, 0x8b);
  112.  
  113. /* IID_IDirect3DQuery9 */
  114. /* {d9771460-a695-4f26-bbd3-27b840b541cc} */
  115. DEFINE_GUID(IID_IDirect3DQuery9, 0xd9771460, 0xa695, 0x4f26, 0xbb, 0xd3, 0x27, 0xb8, 0x40, 0xb5, 0x41, 0xcc);
  116.  
  117.  
  118. #endif
  119.  
  120. #ifdef __cplusplus
  121.  
  122. #ifndef DECLSPEC_UUID
  123. #if _MSC_VER >= 1100
  124. #define DECLSPEC_UUID(x)    __declspec(uuid(x))
  125. #else
  126. #define DECLSPEC_UUID(x)
  127. #endif
  128. #endif
  129.  
  130. interface DECLSPEC_UUID("81BDCBCA-64D4-426d-AE8D-AD0147F4275C") IDirect3D9;
  131. interface DECLSPEC_UUID("D0223B96-BF7A-43fd-92BD-A43B0D82B9EB") IDirect3DDevice9;
  132.  
  133. interface DECLSPEC_UUID("B07C4FE5-310D-4ba8-A23C-4F0F206F218B") IDirect3DStateBlock9;
  134. interface DECLSPEC_UUID("05EEC05D-8F7D-4362-B999-D1BAF357C704") IDirect3DResource9;
  135. interface DECLSPEC_UUID("DD13C59C-36FA-4098-A8FB-C7ED39DC8546") IDirect3DVertexDeclaration9;
  136. interface DECLSPEC_UUID("EFC5557E-6265-4613-8A94-43857889EB36") IDirect3DVertexShader9;
  137. interface DECLSPEC_UUID("6D3BDBDC-5B02-4415-B852-CE5E8BCCB289") IDirect3DPixelShader9;
  138. interface DECLSPEC_UUID("580CA87E-1D3C-4d54-991D-B7D3E3C298CE") IDirect3DBaseTexture9;
  139. interface DECLSPEC_UUID("85C31227-3DE5-4f00-9B3A-F11AC38C18B5") IDirect3DTexture9;
  140. interface DECLSPEC_UUID("2518526C-E789-4111-A7B9-47EF328D13E6") IDirect3DVolumeTexture9;
  141. interface DECLSPEC_UUID("FFF32F81-D953-473a-9223-93D652ABA93F") IDirect3DCubeTexture9;
  142.  
  143. interface DECLSPEC_UUID("B64BB1B5-FD70-4df6-BF91-19D0A12455E3") IDirect3DVertexBuffer9;
  144. interface DECLSPEC_UUID("7C9DD65E-D3F7-4529-ACEE-785830ACDE35") IDirect3DIndexBuffer9;
  145.  
  146. interface DECLSPEC_UUID("0CFBAF3A-9FF6-429a-99B3-A2796AF8B89B") IDirect3DSurface9;
  147. interface DECLSPEC_UUID("24F416E6-1F67-4aa7-B88E-D33F6F3128A1") IDirect3DVolume9;
  148.  
  149. interface DECLSPEC_UUID("794950F2-ADFC-458a-905E-10A10B0B503B") IDirect3DSwapChain9;
  150. interface DECLSPEC_UUID("d9771460-a695-4f26-bbd3-27b840b541cc") IDirect3DQuery9;
  151.  
  152.  
  153. #if defined(_COM_SMARTPTR_TYPEDEF)
  154. _COM_SMARTPTR_TYPEDEF(IDirect3D9, __uuidof(IDirect3D9));
  155. _COM_SMARTPTR_TYPEDEF(IDirect3DDevice9, __uuidof(IDirect3DDevice9));
  156.  
  157. _COM_SMARTPTR_TYPEDEF(IDirect3DStateBlock9, __uuidof(IDirect3DStateBlock9));
  158. _COM_SMARTPTR_TYPEDEF(IDirect3DResource9, __uuidof(IDirect3DResource9));
  159. _COM_SMARTPTR_TYPEDEF(IDirect3DVertexDeclaration9, __uuidof(IDirect3DVertexDeclaration9));
  160. _COM_SMARTPTR_TYPEDEF(IDirect3DVertexShader9, __uuidof(IDirect3DVertexShader9));
  161. _COM_SMARTPTR_TYPEDEF(IDirect3DPixelShader9, __uuidof(IDirect3DPixelShader9));
  162. _COM_SMARTPTR_TYPEDEF(IDirect3DBaseTexture9, __uuidof(IDirect3DBaseTexture9));
  163. _COM_SMARTPTR_TYPEDEF(IDirect3DTexture9, __uuidof(IDirect3DTexture9));
  164. _COM_SMARTPTR_TYPEDEF(IDirect3DVolumeTexture9, __uuidof(IDirect3DVolumeTexture9));
  165. _COM_SMARTPTR_TYPEDEF(IDirect3DCubeTexture9, __uuidof(IDirect3DCubeTexture9));
  166.  
  167. _COM_SMARTPTR_TYPEDEF(IDirect3DVertexBuffer9, __uuidof(IDirect3DVertexBuffer9));
  168. _COM_SMARTPTR_TYPEDEF(IDirect3DIndexBuffer9, __uuidof(IDirect3DIndexBuffer9));
  169.  
  170. _COM_SMARTPTR_TYPEDEF(IDirect3DSurface9, __uuidof(IDirect3DSurface9));
  171. _COM_SMARTPTR_TYPEDEF(IDirect3DVolume9, __uuidof(IDirect3DVolume9));
  172.  
  173. _COM_SMARTPTR_TYPEDEF(IDirect3DSwapChain9, __uuidof(IDirect3DSwapChain9));
  174. _COM_SMARTPTR_TYPEDEF(IDirect3DQuery9, __uuidof(IDirect3DQuery9));
  175.  
  176. #endif
  177. #endif
  178.  
  179.  
  180. typedef interface IDirect3D9                    IDirect3D9;
  181. typedef interface IDirect3DDevice9              IDirect3DDevice9;
  182. typedef interface IDirect3DStateBlock9          IDirect3DStateBlock9;
  183. typedef interface IDirect3DVertexDeclaration9   IDirect3DVertexDeclaration9;
  184. typedef interface IDirect3DVertexShader9        IDirect3DVertexShader9;
  185. typedef interface IDirect3DPixelShader9         IDirect3DPixelShader9;
  186. typedef interface IDirect3DResource9            IDirect3DResource9;
  187. typedef interface IDirect3DBaseTexture9         IDirect3DBaseTexture9;
  188. typedef interface IDirect3DTexture9             IDirect3DTexture9;
  189. typedef interface IDirect3DVolumeTexture9       IDirect3DVolumeTexture9;
  190. typedef interface IDirect3DCubeTexture9         IDirect3DCubeTexture9;
  191. typedef interface IDirect3DVertexBuffer9        IDirect3DVertexBuffer9;
  192. typedef interface IDirect3DIndexBuffer9         IDirect3DIndexBuffer9;
  193. typedef interface IDirect3DSurface9             IDirect3DSurface9;
  194. typedef interface IDirect3DVolume9              IDirect3DVolume9;
  195. typedef interface IDirect3DSwapChain9           IDirect3DSwapChain9;
  196. typedef interface IDirect3DQuery9               IDirect3DQuery9;
  197.  
  198.  
  199. #include "d3d9types.h"
  200. #include "d3d9caps.h"
  201.  
  202.  
  203. #ifdef __cplusplus
  204. extern "C" {
  205. #endif
  206.  
  207. /*
  208.  * DLL Function for creating a Direct3D9 object. This object supports
  209.  * enumeration and allows the creation of Direct3DDevice9 objects.
  210.  * Pass the value of the constant D3D_SDK_VERSION to this function, so
  211.  * that the run-time can validate that your application was compiled
  212.  * against the right headers.
  213.  */
  214.  
  215. IDirect3D9 * WINAPI Direct3DCreate9(UINT SDKVersion);
  216.  
  217.  
  218. /*
  219.  * Direct3D interfaces
  220.  */
  221.  
  222.  
  223.  
  224.  
  225.  
  226. #undef INTERFACE
  227. #define INTERFACE IDirect3D9
  228.  
  229. DECLARE_INTERFACE_(IDirect3D9, IUnknown)
  230. {
  231.     /*** IUnknown methods ***/
  232.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  233.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  234.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  235.  
  236.     /*** IDirect3D9 methods ***/
  237.     STDMETHOD(RegisterSoftwareDevice)(THIS_ void* pInitializeFunction) PURE;
  238.     STDMETHOD_(UINT, GetAdapterCount)(THIS) PURE;
  239.     STDMETHOD(GetAdapterIdentifier)(THIS_ UINT Adapter,DWORD Flags,D3DADAPTER_IDENTIFIER9* pIdentifier) PURE;
  240.     STDMETHOD_(UINT, GetAdapterModeCount)(THIS_ UINT Adapter,D3DFORMAT Format) PURE;
  241.     STDMETHOD(EnumAdapterModes)(THIS_ UINT Adapter,D3DFORMAT Format,UINT Mode,D3DDISPLAYMODE* pMode) PURE;
  242.     STDMETHOD(GetAdapterDisplayMode)(THIS_ UINT Adapter,D3DDISPLAYMODE* pMode) PURE;
  243.     STDMETHOD(CheckDeviceType)(THIS_ UINT iAdapter,D3DDEVTYPE DevType,D3DFORMAT DisplayFormat,D3DFORMAT BackBufferFormat,BOOL bWindowed) PURE;
  244.     STDMETHOD(CheckDeviceFormat)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,DWORD Usage,D3DRESOURCETYPE RType,D3DFORMAT CheckFormat) PURE;
  245.     STDMETHOD(CheckDeviceMultiSampleType)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT SurfaceFormat,BOOL Windowed,D3DMULTISAMPLE_TYPE MultiSampleType,DWORD* pQualityLevels) PURE;
  246.     STDMETHOD(CheckDepthStencilMatch)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,D3DFORMAT RenderTargetFormat,D3DFORMAT DepthStencilFormat) PURE;
  247.     STDMETHOD(CheckDeviceFormatConversion)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT SourceFormat,D3DFORMAT TargetFormat) PURE;
  248.     STDMETHOD(GetDeviceCaps)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DCAPS9* pCaps) PURE;
  249.     STDMETHOD_(HMONITOR, GetAdapterMonitor)(THIS_ UINT Adapter) PURE;
  250.     STDMETHOD(CreateDevice)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,HWND hFocusWindow,DWORD BehaviorFlags,D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DDevice9** ppReturnedDeviceInterface) PURE;
  251. };
  252.  
  253. typedef struct IDirect3D9 *LPDIRECT3D9, *PDIRECT3D9;
  254.  
  255. #if !defined(__cplusplus) || defined(CINTERFACE)
  256. #define IDirect3D9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  257. #define IDirect3D9_AddRef(p) (p)->lpVtbl->AddRef(p)
  258. #define IDirect3D9_Release(p) (p)->lpVtbl->Release(p)
  259. #define IDirect3D9_RegisterSoftwareDevice(p,a) (p)->lpVtbl->RegisterSoftwareDevice(p,a)
  260. #define IDirect3D9_GetAdapterCount(p) (p)->lpVtbl->GetAdapterCount(p)
  261. #define IDirect3D9_GetAdapterIdentifier(p,a,b,c) (p)->lpVtbl->GetAdapterIdentifier(p,a,b,c)
  262. #define IDirect3D9_GetAdapterModeCount(p,a,b) (p)->lpVtbl->GetAdapterModeCount(p,a,b)
  263. #define IDirect3D9_EnumAdapterModes(p,a,b,c,d) (p)->lpVtbl->EnumAdapterModes(p,a,b,c,d)
  264. #define IDirect3D9_GetAdapterDisplayMode(p,a,b) (p)->lpVtbl->GetAdapterDisplayMode(p,a,b)
  265. #define IDirect3D9_CheckDeviceType(p,a,b,c,d,e) (p)->lpVtbl->CheckDeviceType(p,a,b,c,d,e)
  266. #define IDirect3D9_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceFormat(p,a,b,c,d,e,f)
  267. #define IDirect3D9_CheckDeviceMultiSampleType(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceMultiSampleType(p,a,b,c,d,e,f)
  268. #define IDirect3D9_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->lpVtbl->CheckDepthStencilMatch(p,a,b,c,d,e)
  269. #define IDirect3D9_CheckDeviceFormatConversion(p,a,b,c,d) (p)->lpVtbl->CheckDeviceFormatConversion(p,a,b,c,d)
  270. #define IDirect3D9_GetDeviceCaps(p,a,b,c) (p)->lpVtbl->GetDeviceCaps(p,a,b,c)
  271. #define IDirect3D9_GetAdapterMonitor(p,a) (p)->lpVtbl->GetAdapterMonitor(p,a)
  272. #define IDirect3D9_CreateDevice(p,a,b,c,d,e,f) (p)->lpVtbl->CreateDevice(p,a,b,c,d,e,f)
  273. #else
  274. #define IDirect3D9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  275. #define IDirect3D9_AddRef(p) (p)->AddRef()
  276. #define IDirect3D9_Release(p) (p)->Release()
  277. #define IDirect3D9_RegisterSoftwareDevice(p,a) (p)->RegisterSoftwareDevice(a)
  278. #define IDirect3D9_GetAdapterCount(p) (p)->GetAdapterCount()
  279. #define IDirect3D9_GetAdapterIdentifier(p,a,b,c) (p)->GetAdapterIdentifier(a,b,c)
  280. #define IDirect3D9_GetAdapterModeCount(p,a,b) (p)->GetAdapterModeCount(a,b)
  281. #define IDirect3D9_EnumAdapterModes(p,a,b,c,d) (p)->EnumAdapterModes(a,b,c,d)
  282. #define IDirect3D9_GetAdapterDisplayMode(p,a,b) (p)->GetAdapterDisplayMode(a,b)
  283. #define IDirect3D9_CheckDeviceType(p,a,b,c,d,e) (p)->CheckDeviceType(a,b,c,d,e)
  284. #define IDirect3D9_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->CheckDeviceFormat(a,b,c,d,e,f)
  285. #define IDirect3D9_CheckDeviceMultiSampleType(p,a,b,c,d,e,f) (p)->CheckDeviceMultiSampleType(a,b,c,d,e,f)
  286. #define IDirect3D9_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->CheckDepthStencilMatch(a,b,c,d,e)
  287. #define IDirect3D9_CheckDeviceFormatConversion(p,a,b,c,d) (p)->CheckDeviceFormatConversion(a,b,c,d)
  288. #define IDirect3D9_GetDeviceCaps(p,a,b,c) (p)->GetDeviceCaps(a,b,c)
  289. #define IDirect3D9_GetAdapterMonitor(p,a) (p)->GetAdapterMonitor(a)
  290. #define IDirect3D9_CreateDevice(p,a,b,c,d,e,f) (p)->CreateDevice(a,b,c,d,e,f)
  291. #endif
  292.  
  293.  
  294.  
  295.  
  296.  
  297.  
  298.  
  299. /* SwapChain */
  300.  
  301.  
  302.  
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  
  311.  
  312.  
  313.  
  314.  
  315. #undef INTERFACE
  316. #define INTERFACE IDirect3DDevice9
  317.  
  318. DECLARE_INTERFACE_(IDirect3DDevice9, IUnknown)
  319. {
  320.     /*** IUnknown methods ***/
  321.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  322.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  323.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  324.  
  325.     /*** IDirect3DDevice9 methods ***/
  326.     STDMETHOD(TestCooperativeLevel)(THIS) PURE;
  327.     STDMETHOD_(UINT, GetAvailableTextureMem)(THIS) PURE;
  328.     STDMETHOD(EvictManagedResources)(THIS) PURE;
  329.     STDMETHOD(GetDirect3D)(THIS_ IDirect3D9** ppD3D9) PURE;
  330.     STDMETHOD(GetDeviceCaps)(THIS_ D3DCAPS9* pCaps) PURE;
  331.     STDMETHOD(GetDisplayMode)(THIS_ UINT iSwapChain,D3DDISPLAYMODE* pMode) PURE;
  332.     STDMETHOD(GetCreationParameters)(THIS_ D3DDEVICE_CREATION_PARAMETERS *pParameters) PURE;
  333.     STDMETHOD(SetCursorProperties)(THIS_ UINT XHotSpot,UINT YHotSpot,IDirect3DSurface9* pCursorBitmap) PURE;
  334.     STDMETHOD_(void, SetCursorPosition)(THIS_ int X,int Y,DWORD Flags) PURE;
  335.     STDMETHOD_(BOOL, ShowCursor)(THIS_ BOOL bShow) PURE;
  336.     STDMETHOD(CreateAdditionalSwapChain)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DSwapChain9** pSwapChain) PURE;
  337.     STDMETHOD(GetSwapChain)(THIS_ UINT iSwapChain,IDirect3DSwapChain9** pSwapChain) PURE;
  338.     STDMETHOD_(UINT, GetNumberOfSwapChains)(THIS) PURE;
  339.     STDMETHOD(Reset)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters) PURE;
  340.     STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion) PURE;
  341.     STDMETHOD(GetBackBuffer)(THIS_ UINT iSwapChain,UINT iBackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface9** ppBackBuffer) PURE;
  342.     STDMETHOD(GetRasterStatus)(THIS_ UINT iSwapChain,D3DRASTER_STATUS* pRasterStatus) PURE;
  343.     STDMETHOD(SetDialogBoxMode)(THIS_ BOOL bEnableDialogs) PURE;
  344.     STDMETHOD_(void, SetGammaRamp)(THIS_ UINT iSwapChain,DWORD Flags,CONST D3DGAMMARAMP* pRamp) PURE;
  345.     STDMETHOD_(void, GetGammaRamp)(THIS_ UINT iSwapChain,D3DGAMMARAMP* pRamp) PURE;
  346.     STDMETHOD(CreateTexture)(THIS_ UINT Width,UINT Height,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DTexture9** ppTexture,HANDLE* pSharedHandle) PURE;
  347.     STDMETHOD(CreateVolumeTexture)(THIS_ UINT Width,UINT Height,UINT Depth,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DVolumeTexture9** ppVolumeTexture,HANDLE* pSharedHandle) PURE;
  348.     STDMETHOD(CreateCubeTexture)(THIS_ UINT EdgeLength,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DCubeTexture9** ppCubeTexture,HANDLE* pSharedHandle) PURE;
  349.     STDMETHOD(CreateVertexBuffer)(THIS_ UINT Length,DWORD Usage,DWORD FVF,D3DPOOL Pool,IDirect3DVertexBuffer9** ppVertexBuffer,HANDLE* pSharedHandle) PURE;
  350.     STDMETHOD(CreateIndexBuffer)(THIS_ UINT Length,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DIndexBuffer9** ppIndexBuffer,HANDLE* pSharedHandle) PURE;
  351.     STDMETHOD(CreateRenderTarget)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,DWORD MultisampleQuality,BOOL Lockable,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle) PURE;
  352.     STDMETHOD(CreateDepthStencilSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,DWORD MultisampleQuality,BOOL Discard,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle) PURE;
  353.     STDMETHOD(UpdateSurface)(THIS_ IDirect3DSurface9* pSourceSurface,CONST RECT* pSourceRect,IDirect3DSurface9* pDestinationSurface,CONST POINT* pDestPoint) PURE;
  354.     STDMETHOD(UpdateTexture)(THIS_ IDirect3DBaseTexture9* pSourceTexture,IDirect3DBaseTexture9* pDestinationTexture) PURE;
  355.     STDMETHOD(GetRenderTargetData)(THIS_ IDirect3DSurface9* pRenderTarget,IDirect3DSurface9* pDestSurface) PURE;
  356.     STDMETHOD(GetFrontBufferData)(THIS_ UINT iSwapChain,IDirect3DSurface9* pDestSurface) PURE;
  357.     STDMETHOD(StretchRect)(THIS_ IDirect3DSurface9* pSourceSurface,CONST RECT* pSourceRect,IDirect3DSurface9* pDestSurface,CONST RECT* pDestRect,D3DTEXTUREFILTERTYPE Filter) PURE;
  358.     STDMETHOD(ColorFill)(THIS_ IDirect3DSurface9* pSurface,CONST RECT* pRect,D3DCOLOR color) PURE;
  359.     STDMETHOD(CreateOffscreenPlainSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DPOOL Pool,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle) PURE;
  360.     STDMETHOD(SetRenderTarget)(THIS_ DWORD RenderTargetIndex,IDirect3DSurface9* pRenderTarget) PURE;
  361.     STDMETHOD(GetRenderTarget)(THIS_ DWORD RenderTargetIndex,IDirect3DSurface9** ppRenderTarget) PURE;
  362.     STDMETHOD(SetDepthStencilSurface)(THIS_ IDirect3DSurface9* pNewZStencil) PURE;
  363.     STDMETHOD(GetDepthStencilSurface)(THIS_ IDirect3DSurface9** ppZStencilSurface) PURE;
  364.     STDMETHOD(BeginScene)(THIS) PURE;
  365.     STDMETHOD(EndScene)(THIS) PURE;
  366.     STDMETHOD(Clear)(THIS_ DWORD Count,CONST D3DRECT* pRects,DWORD Flags,D3DCOLOR Color,float Z,DWORD Stencil) PURE;
  367.     STDMETHOD(SetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,CONST D3DMATRIX* pMatrix) PURE;
  368.     STDMETHOD(GetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,D3DMATRIX* pMatrix) PURE;
  369.     STDMETHOD(MultiplyTransform)(THIS_ D3DTRANSFORMSTATETYPE,CONST D3DMATRIX*) PURE;
  370.     STDMETHOD(SetViewport)(THIS_ CONST D3DVIEWPORT9* pViewport) PURE;
  371.     STDMETHOD(GetViewport)(THIS_ D3DVIEWPORT9* pViewport) PURE;
  372.     STDMETHOD(SetMaterial)(THIS_ CONST D3DMATERIAL9* pMaterial) PURE;
  373.     STDMETHOD(GetMaterial)(THIS_ D3DMATERIAL9* pMaterial) PURE;
  374.     STDMETHOD(SetLight)(THIS_ DWORD Index,CONST D3DLIGHT9*) PURE;
  375.     STDMETHOD(GetLight)(THIS_ DWORD Index,D3DLIGHT9*) PURE;
  376.     STDMETHOD(LightEnable)(THIS_ DWORD Index,BOOL Enable) PURE;
  377.     STDMETHOD(GetLightEnable)(THIS_ DWORD Index,BOOL* pEnable) PURE;
  378.     STDMETHOD(SetClipPlane)(THIS_ DWORD Index,CONST float* pPlane) PURE;
  379.     STDMETHOD(GetClipPlane)(THIS_ DWORD Index,float* pPlane) PURE;
  380.     STDMETHOD(SetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD Value) PURE;
  381.     STDMETHOD(GetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD* pValue) PURE;
  382.     STDMETHOD(CreateStateBlock)(THIS_ D3DSTATEBLOCKTYPE Type,IDirect3DStateBlock9** ppSB) PURE;
  383.     STDMETHOD(BeginStateBlock)(THIS) PURE;
  384.     STDMETHOD(EndStateBlock)(THIS_ IDirect3DStateBlock9** ppSB) PURE;
  385.     STDMETHOD(SetClipStatus)(THIS_ CONST D3DCLIPSTATUS9* pClipStatus) PURE;
  386.     STDMETHOD(GetClipStatus)(THIS_ D3DCLIPSTATUS9* pClipStatus) PURE;
  387.     STDMETHOD(GetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture9** ppTexture) PURE;
  388.     STDMETHOD(SetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture9* pTexture) PURE;
  389.     STDMETHOD(GetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD* pValue) PURE;
  390.     STDMETHOD(SetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD Value) PURE;
  391.     STDMETHOD(GetSamplerState)(THIS_ DWORD Sampler,D3DSAMPLERSTATETYPE Type,DWORD* pValue) PURE;
  392.     STDMETHOD(SetSamplerState)(THIS_ DWORD Sampler,D3DSAMPLERSTATETYPE Type,DWORD Value) PURE;
  393.     STDMETHOD(ValidateDevice)(THIS_ DWORD* pNumPasses) PURE;
  394.     STDMETHOD(SetPaletteEntries)(THIS_ UINT PaletteNumber,CONST PALETTEENTRY* pEntries) PURE;
  395.     STDMETHOD(GetPaletteEntries)(THIS_ UINT PaletteNumber,PALETTEENTRY* pEntries) PURE;
  396.     STDMETHOD(SetCurrentTexturePalette)(THIS_ UINT PaletteNumber) PURE;
  397.     STDMETHOD(GetCurrentTexturePalette)(THIS_ UINT *PaletteNumber) PURE;
  398.     STDMETHOD(SetScissorRect)(THIS_ CONST RECT* pRect) PURE;
  399.     STDMETHOD(GetScissorRect)(THIS_ RECT* pRect) PURE;
  400.     STDMETHOD(SetSoftwareVertexProcessing)(THIS_ BOOL bSoftware) PURE;
  401.     STDMETHOD_(BOOL, GetSoftwareVertexProcessing)(THIS) PURE;
  402.     STDMETHOD(SetNPatchMode)(THIS_ float nSegments) PURE;
  403.     STDMETHOD_(float, GetNPatchMode)(THIS) PURE;
  404.     STDMETHOD(DrawPrimitive)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT StartVertex,UINT PrimitiveCount) PURE;
  405.     STDMETHOD(DrawIndexedPrimitive)(THIS_ D3DPRIMITIVETYPE,INT BaseVertexIndex,UINT MinVertexIndex,UINT NumVertices,UINT startIndex,UINT primCount) PURE;
  406.     STDMETHOD(DrawPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT PrimitiveCount,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE;
  407.     STDMETHOD(DrawIndexedPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT MinVertexIndex,UINT NumVertices,UINT PrimitiveCount,CONST void* pIndexData,D3DFORMAT IndexDataFormat,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE;
  408.     STDMETHOD(ProcessVertices)(THIS_ UINT SrcStartIndex,UINT DestIndex,UINT VertexCount,IDirect3DVertexBuffer9* pDestBuffer,IDirect3DVertexDeclaration9* pVertexDecl,DWORD Flags) PURE;
  409.     STDMETHOD(CreateVertexDeclaration)(THIS_ CONST D3DVERTEXELEMENT9* pVertexElements,IDirect3DVertexDeclaration9** ppDecl) PURE;
  410.     STDMETHOD(SetVertexDeclaration)(THIS_ IDirect3DVertexDeclaration9* pDecl) PURE;
  411.     STDMETHOD(GetVertexDeclaration)(THIS_ IDirect3DVertexDeclaration9** ppDecl) PURE;
  412.     STDMETHOD(SetFVF)(THIS_ DWORD FVF) PURE;
  413.     STDMETHOD(GetFVF)(THIS_ DWORD* pFVF) PURE;
  414.     STDMETHOD(CreateVertexShader)(THIS_ CONST DWORD* pFunction,IDirect3DVertexShader9** ppShader) PURE;
  415.     STDMETHOD(SetVertexShader)(THIS_ IDirect3DVertexShader9* pShader) PURE;
  416.     STDMETHOD(GetVertexShader)(THIS_ IDirect3DVertexShader9** ppShader) PURE;
  417.     STDMETHOD(SetVertexShaderConstantF)(THIS_ UINT StartRegister,CONST float* pConstantData,UINT Vector4fCount) PURE;
  418.     STDMETHOD(GetVertexShaderConstantF)(THIS_ UINT StartRegister,float* pConstantData,UINT Vector4fCount) PURE;
  419.     STDMETHOD(SetVertexShaderConstantI)(THIS_ UINT StartRegister,CONST int* pConstantData,UINT Vector4iCount) PURE;
  420.     STDMETHOD(GetVertexShaderConstantI)(THIS_ UINT StartRegister,int* pConstantData,UINT Vector4iCount) PURE;
  421.     STDMETHOD(SetVertexShaderConstantB)(THIS_ UINT StartRegister,CONST BOOL* pConstantData,UINT  BoolCount) PURE;
  422.     STDMETHOD(GetVertexShaderConstantB)(THIS_ UINT StartRegister,BOOL* pConstantData,UINT BoolCount) PURE;
  423.     STDMETHOD(SetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer9* pStreamData,UINT OffsetInBytes,UINT Stride) PURE;
  424.     STDMETHOD(GetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer9** ppStreamData,UINT* OffsetInBytes,UINT* pStride) PURE;
  425.     STDMETHOD(SetStreamSourceFreq)(THIS_ UINT StreamNumber,UINT Divider) PURE;
  426.     STDMETHOD(GetStreamSourceFreq)(THIS_ UINT StreamNumber,UINT* Divider) PURE;
  427.     STDMETHOD(SetIndices)(THIS_ IDirect3DIndexBuffer9* pIndexData) PURE;
  428.     STDMETHOD(GetIndices)(THIS_ IDirect3DIndexBuffer9** ppIndexData) PURE;
  429.     STDMETHOD(CreatePixelShader)(THIS_ CONST DWORD* pFunction,IDirect3DPixelShader9** ppShader) PURE;
  430.     STDMETHOD(SetPixelShader)(THIS_ IDirect3DPixelShader9* pShader) PURE;
  431.     STDMETHOD(GetPixelShader)(THIS_ IDirect3DPixelShader9** ppShader) PURE;
  432.     STDMETHOD(SetPixelShaderConstantF)(THIS_ UINT StartRegister,CONST float* pConstantData,UINT Vector4fCount) PURE;
  433.     STDMETHOD(GetPixelShaderConstantF)(THIS_ UINT StartRegister,float* pConstantData,UINT Vector4fCount) PURE;
  434.     STDMETHOD(SetPixelShaderConstantI)(THIS_ UINT StartRegister,CONST int* pConstantData,UINT Vector4iCount) PURE;
  435.     STDMETHOD(GetPixelShaderConstantI)(THIS_ UINT StartRegister,int* pConstantData,UINT Vector4iCount) PURE;
  436.     STDMETHOD(SetPixelShaderConstantB)(THIS_ UINT StartRegister,CONST BOOL* pConstantData,UINT  BoolCount) PURE;
  437.     STDMETHOD(GetPixelShaderConstantB)(THIS_ UINT StartRegister,BOOL* pConstantData,UINT BoolCount) PURE;
  438.     STDMETHOD(DrawRectPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DRECTPATCH_INFO* pRectPatchInfo) PURE;
  439.     STDMETHOD(DrawTriPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DTRIPATCH_INFO* pTriPatchInfo) PURE;
  440.     STDMETHOD(DeletePatch)(THIS_ UINT Handle) PURE;
  441.     STDMETHOD(CreateQuery)(THIS_ D3DQUERYTYPE Type,IDirect3DQuery9** ppQuery) PURE;
  442. };
  443.  
  444. typedef struct IDirect3DDevice9 *LPDIRECT3DDEVICE9, *PDIRECT3DDEVICE9;
  445.  
  446. #if !defined(__cplusplus) || defined(CINTERFACE)
  447. #define IDirect3DDevice9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  448. #define IDirect3DDevice9_AddRef(p) (p)->lpVtbl->AddRef(p)
  449. #define IDirect3DDevice9_Release(p) (p)->lpVtbl->Release(p)
  450. #define IDirect3DDevice9_TestCooperativeLevel(p) (p)->lpVtbl->TestCooperativeLevel(p)
  451. #define IDirect3DDevice9_GetAvailableTextureMem(p) (p)->lpVtbl->GetAvailableTextureMem(p)
  452. #define IDirect3DDevice9_EvictManagedResources(p) (p)->lpVtbl->EvictManagedResources(p)
  453. #define IDirect3DDevice9_GetDirect3D(p,a) (p)->lpVtbl->GetDirect3D(p,a)
  454. #define IDirect3DDevice9_GetDeviceCaps(p,a) (p)->lpVtbl->GetDeviceCaps(p,a)
  455. #define IDirect3DDevice9_GetDisplayMode(p,a,b) (p)->lpVtbl->GetDisplayMode(p,a,b)
  456. #define IDirect3DDevice9_GetCreationParameters(p,a) (p)->lpVtbl->GetCreationParameters(p,a)
  457. #define IDirect3DDevice9_SetCursorProperties(p,a,b,c) (p)->lpVtbl->SetCursorProperties(p,a,b,c)
  458. #define IDirect3DDevice9_SetCursorPosition(p,a,b,c) (p)->lpVtbl->SetCursorPosition(p,a,b,c)
  459. #define IDirect3DDevice9_ShowCursor(p,a) (p)->lpVtbl->ShowCursor(p,a)
  460. #define IDirect3DDevice9_CreateAdditionalSwapChain(p,a,b) (p)->lpVtbl->CreateAdditionalSwapChain(p,a,b)
  461. #define IDirect3DDevice9_GetSwapChain(p,a,b) (p)->lpVtbl->GetSwapChain(p,a,b)
  462. #define IDirect3DDevice9_GetNumberOfSwapChains(p) (p)->lpVtbl->GetNumberOfSwapChains(p)
  463. #define IDirect3DDevice9_Reset(p,a) (p)->lpVtbl->Reset(p,a)
  464. #define IDirect3DDevice9_Present(p,a,b,c,d) (p)->lpVtbl->Present(p,a,b,c,d)
  465. #define IDirect3DDevice9_GetBackBuffer(p,a,b,c,d) (p)->lpVtbl->GetBackBuffer(p,a,b,c,d)
  466. #define IDirect3DDevice9_GetRasterStatus(p,a,b) (p)->lpVtbl->GetRasterStatus(p,a,b)
  467. #define IDirect3DDevice9_SetDialogBoxMode(p,a) (p)->lpVtbl->SetDialogBoxMode(p,a)
  468. #define IDirect3DDevice9_SetGammaRamp(p,a,b,c) (p)->lpVtbl->SetGammaRamp(p,a,b,c)
  469. #define IDirect3DDevice9_GetGammaRamp(p,a,b) (p)->lpVtbl->GetGammaRamp(p,a,b)
  470. #define IDirect3DDevice9_CreateTexture(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateTexture(p,a,b,c,d,e,f,g,h)
  471. #define IDirect3DDevice9_CreateVolumeTexture(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CreateVolumeTexture(p,a,b,c,d,e,f,g,h,i)
  472. #define IDirect3DDevice9_CreateCubeTexture(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateCubeTexture(p,a,b,c,d,e,f,g)
  473. #define IDirect3DDevice9_CreateVertexBuffer(p,a,b,c,d,e,f) (p)->lpVtbl->CreateVertexBuffer(p,a,b,c,d,e,f)
  474. #define IDirect3DDevice9_CreateIndexBuffer(p,a,b,c,d,e,f) (p)->lpVtbl->CreateIndexBuffer(p,a,b,c,d,e,f)
  475. #define IDirect3DDevice9_CreateRenderTarget(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateRenderTarget(p,a,b,c,d,e,f,g,h)
  476. #define IDirect3DDevice9_CreateDepthStencilSurface(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateDepthStencilSurface(p,a,b,c,d,e,f,g,h)
  477. #define IDirect3DDevice9_UpdateSurface(p,a,b,c,d) (p)->lpVtbl->UpdateSurface(p,a,b,c,d)
  478. #define IDirect3DDevice9_UpdateTexture(p,a,b) (p)->lpVtbl->UpdateTexture(p,a,b)
  479. #define IDirect3DDevice9_GetRenderTargetData(p,a,b) (p)->lpVtbl->GetRenderTargetData(p,a,b)
  480. #define IDirect3DDevice9_GetFrontBufferData(p,a,b) (p)->lpVtbl->GetFrontBufferData(p,a,b)
  481. #define IDirect3DDevice9_StretchRect(p,a,b,c,d,e) (p)->lpVtbl->StretchRect(p,a,b,c,d,e)
  482. #define IDirect3DDevice9_ColorFill(p,a,b,c) (p)->lpVtbl->ColorFill(p,a,b,c)
  483. #define IDirect3DDevice9_CreateOffscreenPlainSurface(p,a,b,c,d,e,f) (p)->lpVtbl->CreateOffscreenPlainSurface(p,a,b,c,d,e,f)
  484. #define IDirect3DDevice9_SetRenderTarget(p,a,b) (p)->lpVtbl->SetRenderTarget(p,a,b)
  485. #define IDirect3DDevice9_GetRenderTarget(p,a,b) (p)->lpVtbl->GetRenderTarget(p,a,b)
  486. #define IDirect3DDevice9_SetDepthStencilSurface(p,a) (p)->lpVtbl->SetDepthStencilSurface(p,a)
  487. #define IDirect3DDevice9_GetDepthStencilSurface(p,a) (p)->lpVtbl->GetDepthStencilSurface(p,a)
  488. #define IDirect3DDevice9_BeginScene(p) (p)->lpVtbl->BeginScene(p)
  489. #define IDirect3DDevice9_EndScene(p) (p)->lpVtbl->EndScene(p)
  490. #define IDirect3DDevice9_Clear(p,a,b,c,d,e,f) (p)->lpVtbl->Clear(p,a,b,c,d,e,f)
  491. #define IDirect3DDevice9_SetTransform(p,a,b) (p)->lpVtbl->SetTransform(p,a,b)
  492. #define IDirect3DDevice9_GetTransform(p,a,b) (p)->lpVtbl->GetTransform(p,a,b)
  493. #define IDirect3DDevice9_MultiplyTransform(p,a,b) (p)->lpVtbl->MultiplyTransform(p,a,b)
  494. #define IDirect3DDevice9_SetViewport(p,a) (p)->lpVtbl->SetViewport(p,a)
  495. #define IDirect3DDevice9_GetViewport(p,a) (p)->lpVtbl->GetViewport(p,a)
  496. #define IDirect3DDevice9_SetMaterial(p,a) (p)->lpVtbl->SetMaterial(p,a)
  497. #define IDirect3DDevice9_GetMaterial(p,a) (p)->lpVtbl->GetMaterial(p,a)
  498. #define IDirect3DDevice9_SetLight(p,a,b) (p)->lpVtbl->SetLight(p,a,b)
  499. #define IDirect3DDevice9_GetLight(p,a,b) (p)->lpVtbl->GetLight(p,a,b)
  500. #define IDirect3DDevice9_LightEnable(p,a,b) (p)->lpVtbl->LightEnable(p,a,b)
  501. #define IDirect3DDevice9_GetLightEnable(p,a,b) (p)->lpVtbl->GetLightEnable(p,a,b)
  502. #define IDirect3DDevice9_SetClipPlane(p,a,b) (p)->lpVtbl->SetClipPlane(p,a,b)
  503. #define IDirect3DDevice9_GetClipPlane(p,a,b) (p)->lpVtbl->GetClipPlane(p,a,b)
  504. #define IDirect3DDevice9_SetRenderState(p,a,b) (p)->lpVtbl->SetRenderState(p,a,b)
  505. #define IDirect3DDevice9_GetRenderState(p,a,b) (p)->lpVtbl->GetRenderState(p,a,b)
  506. #define IDirect3DDevice9_CreateStateBlock(p,a,b) (p)->lpVtbl->CreateStateBlock(p,a,b)
  507. #define IDirect3DDevice9_BeginStateBlock(p) (p)->lpVtbl->BeginStateBlock(p)
  508. #define IDirect3DDevice9_EndStateBlock(p,a) (p)->lpVtbl->EndStateBlock(p,a)
  509. #define IDirect3DDevice9_SetClipStatus(p,a) (p)->lpVtbl->SetClipStatus(p,a)
  510. #define IDirect3DDevice9_GetClipStatus(p,a) (p)->lpVtbl->GetClipStatus(p,a)
  511. #define IDirect3DDevice9_GetTexture(p,a,b) (p)->lpVtbl->GetTexture(p,a,b)
  512. #define IDirect3DDevice9_SetTexture(p,a,b) (p)->lpVtbl->SetTexture(p,a,b)
  513. #define IDirect3DDevice9_GetTextureStageState(p,a,b,c) (p)->lpVtbl->GetTextureStageState(p,a,b,c)
  514. #define IDirect3DDevice9_SetTextureStageState(p,a,b,c) (p)->lpVtbl->SetTextureStageState(p,a,b,c)
  515. #define IDirect3DDevice9_GetSamplerState(p,a,b,c) (p)->lpVtbl->GetSamplerState(p,a,b,c)
  516. #define IDirect3DDevice9_SetSamplerState(p,a,b,c) (p)->lpVtbl->SetSamplerState(p,a,b,c)
  517. #define IDirect3DDevice9_ValidateDevice(p,a) (p)->lpVtbl->ValidateDevice(p,a)
  518. #define IDirect3DDevice9_SetPaletteEntries(p,a,b) (p)->lpVtbl->SetPaletteEntries(p,a,b)
  519. #define IDirect3DDevice9_GetPaletteEntries(p,a,b) (p)->lpVtbl->GetPaletteEntries(p,a,b)
  520. #define IDirect3DDevice9_SetCurrentTexturePalette(p,a) (p)->lpVtbl->SetCurrentTexturePalette(p,a)
  521. #define IDirect3DDevice9_GetCurrentTexturePalette(p,a) (p)->lpVtbl->GetCurrentTexturePalette(p,a)
  522. #define IDirect3DDevice9_SetScissorRect(p,a) (p)->lpVtbl->SetScissorRect(p,a)
  523. #define IDirect3DDevice9_GetScissorRect(p,a) (p)->lpVtbl->GetScissorRect(p,a)
  524. #define IDirect3DDevice9_SetSoftwareVertexProcessing(p,a) (p)->lpVtbl->SetSoftwareVertexProcessing(p,a)
  525. #define IDirect3DDevice9_GetSoftwareVertexProcessing(p) (p)->lpVtbl->GetSoftwareVertexProcessing(p)
  526. #define IDirect3DDevice9_SetNPatchMode(p,a) (p)->lpVtbl->SetNPatchMode(p,a)
  527. #define IDirect3DDevice9_GetNPatchMode(p) (p)->lpVtbl->GetNPatchMode(p)
  528. #define IDirect3DDevice9_DrawPrimitive(p,a,b,c) (p)->lpVtbl->DrawPrimitive(p,a,b,c)
  529. #define IDirect3DDevice9_DrawIndexedPrimitive(p,a,b,c,d,e,f) (p)->lpVtbl->DrawIndexedPrimitive(p,a,b,c,d,e,f)
  530. #define IDirect3DDevice9_DrawPrimitiveUP(p,a,b,c,d) (p)->lpVtbl->DrawPrimitiveUP(p,a,b,c,d)
  531. #define IDirect3DDevice9_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h)
  532. #define IDirect3DDevice9_ProcessVertices(p,a,b,c,d,e,f) (p)->lpVtbl->ProcessVertices(p,a,b,c,d,e,f)
  533. #define IDirect3DDevice9_CreateVertexDeclaration(p,a,b) (p)->lpVtbl->CreateVertexDeclaration(p,a,b)
  534. #define IDirect3DDevice9_SetVertexDeclaration(p,a) (p)->lpVtbl->SetVertexDeclaration(p,a)
  535. #define IDirect3DDevice9_GetVertexDeclaration(p,a) (p)->lpVtbl->GetVertexDeclaration(p,a)
  536. #define IDirect3DDevice9_SetFVF(p,a) (p)->lpVtbl->SetFVF(p,a)
  537. #define IDirect3DDevice9_GetFVF(p,a) (p)->lpVtbl->GetFVF(p,a)
  538. #define IDirect3DDevice9_CreateVertexShader(p,a,b) (p)->lpVtbl->CreateVertexShader(p,a,b)
  539. #define IDirect3DDevice9_SetVertexShader(p,a) (p)->lpVtbl->SetVertexShader(p,a)
  540. #define IDirect3DDevice9_GetVertexShader(p,a) (p)->lpVtbl->GetVertexShader(p,a)
  541. #define IDirect3DDevice9_SetVertexShaderConstantF(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstantF(p,a,b,c)
  542. #define IDirect3DDevice9_GetVertexShaderConstantF(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstantF(p,a,b,c)
  543. #define IDirect3DDevice9_SetVertexShaderConstantI(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstantI(p,a,b,c)
  544. #define IDirect3DDevice9_GetVertexShaderConstantI(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstantI(p,a,b,c)
  545. #define IDirect3DDevice9_SetVertexShaderConstantB(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstantB(p,a,b,c)
  546. #define IDirect3DDevice9_GetVertexShaderConstantB(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstantB(p,a,b,c)
  547. #define IDirect3DDevice9_SetStreamSource(p,a,b,c,d) (p)->lpVtbl->SetStreamSource(p,a,b,c,d)
  548. #define IDirect3DDevice9_GetStreamSource(p,a,b,c,d) (p)->lpVtbl->GetStreamSource(p,a,b,c,d)
  549. #define IDirect3DDevice9_SetStreamSourceFreq(p,a,b) (p)->lpVtbl->SetStreamSourceFreq(p,a,b)
  550. #define IDirect3DDevice9_GetStreamSourceFreq(p,a,b) (p)->lpVtbl->GetStreamSourceFreq(p,a,b)
  551. #define IDirect3DDevice9_SetIndices(p,a) (p)->lpVtbl->SetIndices(p,a)
  552. #define IDirect3DDevice9_GetIndices(p,a) (p)->lpVtbl->GetIndices(p,a)
  553. #define IDirect3DDevice9_CreatePixelShader(p,a,b) (p)->lpVtbl->CreatePixelShader(p,a,b)
  554. #define IDirect3DDevice9_SetPixelShader(p,a) (p)->lpVtbl->SetPixelShader(p,a)
  555. #define IDirect3DDevice9_GetPixelShader(p,a) (p)->lpVtbl->GetPixelShader(p,a)
  556. #define IDirect3DDevice9_SetPixelShaderConstantF(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstantF(p,a,b,c)
  557. #define IDirect3DDevice9_GetPixelShaderConstantF(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstantF(p,a,b,c)
  558. #define IDirect3DDevice9_SetPixelShaderConstantI(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstantI(p,a,b,c)
  559. #define IDirect3DDevice9_GetPixelShaderConstantI(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstantI(p,a,b,c)
  560. #define IDirect3DDevice9_SetPixelShaderConstantB(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstantB(p,a,b,c)
  561. #define IDirect3DDevice9_GetPixelShaderConstantB(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstantB(p,a,b,c)
  562. #define IDirect3DDevice9_DrawRectPatch(p,a,b,c) (p)->lpVtbl->DrawRectPatch(p,a,b,c)
  563. #define IDirect3DDevice9_DrawTriPatch(p,a,b,c) (p)->lpVtbl->DrawTriPatch(p,a,b,c)
  564. #define IDirect3DDevice9_DeletePatch(p,a) (p)->lpVtbl->DeletePatch(p,a)
  565. #define IDirect3DDevice9_CreateQuery(p,a,b) (p)->lpVtbl->CreateQuery(p,a,b)
  566. #else
  567. #define IDirect3DDevice9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  568. #define IDirect3DDevice9_AddRef(p) (p)->AddRef()
  569. #define IDirect3DDevice9_Release(p) (p)->Release()
  570. #define IDirect3DDevice9_TestCooperativeLevel(p) (p)->TestCooperativeLevel()
  571. #define IDirect3DDevice9_GetAvailableTextureMem(p) (p)->GetAvailableTextureMem()
  572. #define IDirect3DDevice9_EvictManagedResources(p) (p)->EvictManagedResources()
  573. #define IDirect3DDevice9_GetDirect3D(p,a) (p)->GetDirect3D(a)
  574. #define IDirect3DDevice9_GetDeviceCaps(p,a) (p)->GetDeviceCaps(a)
  575. #define IDirect3DDevice9_GetDisplayMode(p,a,b) (p)->GetDisplayMode(a,b)
  576. #define IDirect3DDevice9_GetCreationParameters(p,a) (p)->GetCreationParameters(a)
  577. #define IDirect3DDevice9_SetCursorProperties(p,a,b,c) (p)->SetCursorProperties(a,b,c)
  578. #define IDirect3DDevice9_SetCursorPosition(p,a,b,c) (p)->SetCursorPosition(a,b,c)
  579. #define IDirect3DDevice9_ShowCursor(p,a) (p)->ShowCursor(a)
  580. #define IDirect3DDevice9_CreateAdditionalSwapChain(p,a,b) (p)->CreateAdditionalSwapChain(a,b)
  581. #define IDirect3DDevice9_GetSwapChain(p,a,b) (p)->GetSwapChain(a,b)
  582. #define IDirect3DDevice9_GetNumberOfSwapChains(p) (p)->GetNumberOfSwapChains()
  583. #define IDirect3DDevice9_Reset(p,a) (p)->Reset(a)
  584. #define IDirect3DDevice9_Present(p,a,b,c,d) (p)->Present(a,b,c,d)
  585. #define IDirect3DDevice9_GetBackBuffer(p,a,b,c,d) (p)->GetBackBuffer(a,b,c,d)
  586. #define IDirect3DDevice9_GetRasterStatus(p,a,b) (p)->GetRasterStatus(a,b)
  587. #define IDirect3DDevice9_SetDialogBoxMode(p,a) (p)->SetDialogBoxMode(a)
  588. #define IDirect3DDevice9_SetGammaRamp(p,a,b,c) (p)->SetGammaRamp(a,b,c)
  589. #define IDirect3DDevice9_GetGammaRamp(p,a,b) (p)->GetGammaRamp(a,b)
  590. #define IDirect3DDevice9_CreateTexture(p,a,b,c,d,e,f,g,h) (p)->CreateTexture(a,b,c,d,e,f,g,h)
  591. #define IDirect3DDevice9_CreateVolumeTexture(p,a,b,c,d,e,f,g,h,i) (p)->CreateVolumeTexture(a,b,c,d,e,f,g,h,i)
  592. #define IDirect3DDevice9_CreateCubeTexture(p,a,b,c,d,e,f,g) (p)->CreateCubeTexture(a,b,c,d,e,f,g)
  593. #define IDirect3DDevice9_CreateVertexBuffer(p,a,b,c,d,e,f) (p)->CreateVertexBuffer(a,b,c,d,e,f)
  594. #define IDirect3DDevice9_CreateIndexBuffer(p,a,b,c,d,e,f) (p)->CreateIndexBuffer(a,b,c,d,e,f)
  595. #define IDirect3DDevice9_CreateRenderTarget(p,a,b,c,d,e,f,g,h) (p)->CreateRenderTarget(a,b,c,d,e,f,g,h)
  596. #define IDirect3DDevice9_CreateDepthStencilSurface(p,a,b,c,d,e,f,g,h) (p)->CreateDepthStencilSurface(a,b,c,d,e,f,g,h)
  597. #define IDirect3DDevice9_UpdateSurface(p,a,b,c,d) (p)->UpdateSurface(a,b,c,d)
  598. #define IDirect3DDevice9_UpdateTexture(p,a,b) (p)->UpdateTexture(a,b)
  599. #define IDirect3DDevice9_GetRenderTargetData(p,a,b) (p)->GetRenderTargetData(a,b)
  600. #define IDirect3DDevice9_GetFrontBufferData(p,a,b) (p)->GetFrontBufferData(a,b)
  601. #define IDirect3DDevice9_StretchRect(p,a,b,c,d,e) (p)->StretchRect(a,b,c,d,e)
  602. #define IDirect3DDevice9_ColorFill(p,a,b,c) (p)->ColorFill(a,b,c)
  603. #define IDirect3DDevice9_CreateOffscreenPlainSurface(p,a,b,c,d,e,f) (p)->CreateOffscreenPlainSurface(a,b,c,d,e,f)
  604. #define IDirect3DDevice9_SetRenderTarget(p,a,b) (p)->SetRenderTarget(a,b)
  605. #define IDirect3DDevice9_GetRenderTarget(p,a,b) (p)->GetRenderTarget(a,b)
  606. #define IDirect3DDevice9_SetDepthStencilSurface(p,a) (p)->SetDepthStencilSurface(a)
  607. #define IDirect3DDevice9_GetDepthStencilSurface(p,a) (p)->GetDepthStencilSurface(a)
  608. #define IDirect3DDevice9_BeginScene(p) (p)->BeginScene()
  609. #define IDirect3DDevice9_EndScene(p) (p)->EndScene()
  610. #define IDirect3DDevice9_Clear(p,a,b,c,d,e,f) (p)->Clear(a,b,c,d,e,f)
  611. #define IDirect3DDevice9_SetTransform(p,a,b) (p)->SetTransform(a,b)
  612. #define IDirect3DDevice9_GetTransform(p,a,b) (p)->GetTransform(a,b)
  613. #define IDirect3DDevice9_MultiplyTransform(p,a,b) (p)->MultiplyTransform(a,b)
  614. #define IDirect3DDevice9_SetViewport(p,a) (p)->SetViewport(a)
  615. #define IDirect3DDevice9_GetViewport(p,a) (p)->GetViewport(a)
  616. #define IDirect3DDevice9_SetMaterial(p,a) (p)->SetMaterial(a)
  617. #define IDirect3DDevice9_GetMaterial(p,a) (p)->GetMaterial(a)
  618. #define IDirect3DDevice9_SetLight(p,a,b) (p)->SetLight(a,b)
  619. #define IDirect3DDevice9_GetLight(p,a,b) (p)->GetLight(a,b)
  620. #define IDirect3DDevice9_LightEnable(p,a,b) (p)->LightEnable(a,b)
  621. #define IDirect3DDevice9_GetLightEnable(p,a,b) (p)->GetLightEnable(a,b)
  622. #define IDirect3DDevice9_SetClipPlane(p,a,b) (p)->SetClipPlane(a,b)
  623. #define IDirect3DDevice9_GetClipPlane(p,a,b) (p)->GetClipPlane(a,b)
  624. #define IDirect3DDevice9_SetRenderState(p,a,b) (p)->SetRenderState(a,b)
  625. #define IDirect3DDevice9_GetRenderState(p,a,b) (p)->GetRenderState(a,b)
  626. #define IDirect3DDevice9_CreateStateBlock(p,a,b) (p)->CreateStateBlock(a,b)
  627. #define IDirect3DDevice9_BeginStateBlock(p) (p)->BeginStateBlock()
  628. #define IDirect3DDevice9_EndStateBlock(p,a) (p)->EndStateBlock(a)
  629. #define IDirect3DDevice9_SetClipStatus(p,a) (p)->SetClipStatus(a)
  630. #define IDirect3DDevice9_GetClipStatus(p,a) (p)->GetClipStatus(a)
  631. #define IDirect3DDevice9_GetTexture(p,a,b) (p)->GetTexture(a,b)
  632. #define IDirect3DDevice9_SetTexture(p,a,b) (p)->SetTexture(a,b)
  633. #define IDirect3DDevice9_GetTextureStageState(p,a,b,c) (p)->GetTextureStageState(a,b,c)
  634. #define IDirect3DDevice9_SetTextureStageState(p,a,b,c) (p)->SetTextureStageState(a,b,c)
  635. #define IDirect3DDevice9_GetSamplerState(p,a,b,c) (p)->GetSamplerState(a,b,c)
  636. #define IDirect3DDevice9_SetSamplerState(p,a,b,c) (p)->SetSamplerState(a,b,c)
  637. #define IDirect3DDevice9_ValidateDevice(p,a) (p)->ValidateDevice(a)
  638. #define IDirect3DDevice9_SetPaletteEntries(p,a,b) (p)->SetPaletteEntries(a,b)
  639. #define IDirect3DDevice9_GetPaletteEntries(p,a,b) (p)->GetPaletteEntries(a,b)
  640. #define IDirect3DDevice9_SetCurrentTexturePalette(p,a) (p)->SetCurrentTexturePalette(a)
  641. #define IDirect3DDevice9_GetCurrentTexturePalette(p,a) (p)->GetCurrentTexturePalette(a)
  642. #define IDirect3DDevice9_SetScissorRect(p,a) (p)->SetScissorRect(a)
  643. #define IDirect3DDevice9_GetScissorRect(p,a) (p)->GetScissorRect(a)
  644. #define IDirect3DDevice9_SetSoftwareVertexProcessing(p,a) (p)->SetSoftwareVertexProcessing(a)
  645. #define IDirect3DDevice9_GetSoftwareVertexProcessing(p) (p)->GetSoftwareVertexProcessing()
  646. #define IDirect3DDevice9_SetNPatchMode(p,a) (p)->SetNPatchMode(a)
  647. #define IDirect3DDevice9_GetNPatchMode(p) (p)->GetNPatchMode()
  648. #define IDirect3DDevice9_DrawPrimitive(p,a,b,c) (p)->DrawPrimitive(a,b,c)
  649. #define IDirect3DDevice9_DrawIndexedPrimitive(p,a,b,c,d,e,f) (p)->DrawIndexedPrimitive(a,b,c,d,e,f)
  650. #define IDirect3DDevice9_DrawPrimitiveUP(p,a,b,c,d) (p)->DrawPrimitiveUP(a,b,c,d)
  651. #define IDirect3DDevice9_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->DrawIndexedPrimitiveUP(a,b,c,d,e,f,g,h)
  652. #define IDirect3DDevice9_ProcessVertices(p,a,b,c,d,e,f) (p)->ProcessVertices(a,b,c,d,e,f)
  653. #define IDirect3DDevice9_CreateVertexDeclaration(p,a,b) (p)->CreateVertexDeclaration(a,b)
  654. #define IDirect3DDevice9_SetVertexDeclaration(p,a) (p)->SetVertexDeclaration(a)
  655. #define IDirect3DDevice9_GetVertexDeclaration(p,a) (p)->GetVertexDeclaration(a)
  656. #define IDirect3DDevice9_SetFVF(p,a) (p)->SetFVF(a)
  657. #define IDirect3DDevice9_GetFVF(p,a) (p)->GetFVF(a)
  658. #define IDirect3DDevice9_CreateVertexShader(p,a,b) (p)->CreateVertexShader(a,b)
  659. #define IDirect3DDevice9_SetVertexShader(p,a) (p)->SetVertexShader(a)
  660. #define IDirect3DDevice9_GetVertexShader(p,a) (p)->GetVertexShader(a)
  661. #define IDirect3DDevice9_SetVertexShaderConstantF(p,a,b,c) (p)->SetVertexShaderConstantF(a,b,c)
  662. #define IDirect3DDevice9_GetVertexShaderConstantF(p,a,b,c) (p)->GetVertexShaderConstantF(a,b,c)
  663. #define IDirect3DDevice9_SetVertexShaderConstantI(p,a,b,c) (p)->SetVertexShaderConstantI(a,b,c)
  664. #define IDirect3DDevice9_GetVertexShaderConstantI(p,a,b,c) (p)->GetVertexShaderConstantI(a,b,c)
  665. #define IDirect3DDevice9_SetVertexShaderConstantB(p,a,b,c) (p)->SetVertexShaderConstantB(a,b,c)
  666. #define IDirect3DDevice9_GetVertexShaderConstantB(p,a,b,c) (p)->GetVertexShaderConstantB(a,b,c)
  667. #define IDirect3DDevice9_SetStreamSource(p,a,b,c,d) (p)->SetStreamSource(a,b,c,d)
  668. #define IDirect3DDevice9_GetStreamSource(p,a,b,c,d) (p)->GetStreamSource(a,b,c,d)
  669. #define IDirect3DDevice9_SetStreamSourceFreq(p,a,b) (p)->SetStreamSourceFreq(a,b)
  670. #define IDirect3DDevice9_GetStreamSourceFreq(p,a,b) (p)->GetStreamSourceFreq(a,b)
  671. #define IDirect3DDevice9_SetIndices(p,a) (p)->SetIndices(a)
  672. #define IDirect3DDevice9_GetIndices(p,a) (p)->GetIndices(a)
  673. #define IDirect3DDevice9_CreatePixelShader(p,a,b) (p)->CreatePixelShader(a,b)
  674. #define IDirect3DDevice9_SetPixelShader(p,a) (p)->SetPixelShader(a)
  675. #define IDirect3DDevice9_GetPixelShader(p,a) (p)->GetPixelShader(a)
  676. #define IDirect3DDevice9_SetPixelShaderConstantF(p,a,b,c) (p)->SetPixelShaderConstantF(a,b,c)
  677. #define IDirect3DDevice9_GetPixelShaderConstantF(p,a,b,c) (p)->GetPixelShaderConstantF(a,b,c)
  678. #define IDirect3DDevice9_SetPixelShaderConstantI(p,a,b,c) (p)->SetPixelShaderConstantI(a,b,c)
  679. #define IDirect3DDevice9_GetPixelShaderConstantI(p,a,b,c) (p)->GetPixelShaderConstantI(a,b,c)
  680. #define IDirect3DDevice9_SetPixelShaderConstantB(p,a,b,c) (p)->SetPixelShaderConstantB(a,b,c)
  681. #define IDirect3DDevice9_GetPixelShaderConstantB(p,a,b,c) (p)->GetPixelShaderConstantB(a,b,c)
  682. #define IDirect3DDevice9_DrawRectPatch(p,a,b,c) (p)->DrawRectPatch(a,b,c)
  683. #define IDirect3DDevice9_DrawTriPatch(p,a,b,c) (p)->DrawTriPatch(a,b,c)
  684. #define IDirect3DDevice9_DeletePatch(p,a) (p)->DeletePatch(a)
  685. #define IDirect3DDevice9_CreateQuery(p,a,b) (p)->CreateQuery(a,b)
  686. #endif
  687.  
  688.  
  689. #undef INTERFACE
  690. #define INTERFACE IDirect3DStateBlock9
  691.  
  692. DECLARE_INTERFACE_(IDirect3DStateBlock9, IUnknown)
  693. {
  694.     /*** IUnknown methods ***/
  695.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  696.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  697.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  698.  
  699.     /*** IDirect3DStateBlock9 methods ***/
  700.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  701.     STDMETHOD(Capture)(THIS) PURE;
  702.     STDMETHOD(Apply)(THIS) PURE;
  703. };
  704.  
  705. typedef struct IDirect3DStateBlock9 *LPDIRECT3DSTATEBLOCK9, *PDIRECT3DSTATEBLOCK9;
  706.  
  707. #if !defined(__cplusplus) || defined(CINTERFACE)
  708. #define IDirect3DStateBlock9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  709. #define IDirect3DStateBlock9_AddRef(p) (p)->lpVtbl->AddRef(p)
  710. #define IDirect3DStateBlock9_Release(p) (p)->lpVtbl->Release(p)
  711. #define IDirect3DStateBlock9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  712. #define IDirect3DStateBlock9_Capture(p) (p)->lpVtbl->Capture(p)
  713. #define IDirect3DStateBlock9_Apply(p) (p)->lpVtbl->Apply(p)
  714. #else
  715. #define IDirect3DStateBlock9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  716. #define IDirect3DStateBlock9_AddRef(p) (p)->AddRef()
  717. #define IDirect3DStateBlock9_Release(p) (p)->Release()
  718. #define IDirect3DStateBlock9_GetDevice(p,a) (p)->GetDevice(a)
  719. #define IDirect3DStateBlock9_Capture(p) (p)->Capture()
  720. #define IDirect3DStateBlock9_Apply(p) (p)->Apply()
  721. #endif
  722.  
  723.  
  724.  
  725. #undef INTERFACE
  726. #define INTERFACE IDirect3DSwapChain9
  727.  
  728. DECLARE_INTERFACE_(IDirect3DSwapChain9, IUnknown)
  729. {
  730.     /*** IUnknown methods ***/
  731.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  732.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  733.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  734.  
  735.     /*** IDirect3DSwapChain9 methods ***/
  736.     STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion,DWORD dwFlags) PURE;
  737.     STDMETHOD(GetFrontBufferData)(THIS_ IDirect3DSurface9* pDestSurface) PURE;
  738.     STDMETHOD(GetBackBuffer)(THIS_ UINT iBackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface9** ppBackBuffer) PURE;
  739.     STDMETHOD(GetRasterStatus)(THIS_ D3DRASTER_STATUS* pRasterStatus) PURE;
  740.     STDMETHOD(GetDisplayMode)(THIS_ D3DDISPLAYMODE* pMode) PURE;
  741.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  742.     STDMETHOD(GetPresentParameters)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters) PURE;
  743. };
  744.  
  745. typedef struct IDirect3DSwapChain9 *LPDIRECT3DSWAPCHAIN9, *PDIRECT3DSWAPCHAIN9;
  746.  
  747. #if !defined(__cplusplus) || defined(CINTERFACE)
  748. #define IDirect3DSwapChain9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  749. #define IDirect3DSwapChain9_AddRef(p) (p)->lpVtbl->AddRef(p)
  750. #define IDirect3DSwapChain9_Release(p) (p)->lpVtbl->Release(p)
  751. #define IDirect3DSwapChain9_Present(p,a,b,c,d,e) (p)->lpVtbl->Present(p,a,b,c,d,e)
  752. #define IDirect3DSwapChain9_GetFrontBufferData(p,a) (p)->lpVtbl->GetFrontBufferData(p,a)
  753. #define IDirect3DSwapChain9_GetBackBuffer(p,a,b,c) (p)->lpVtbl->GetBackBuffer(p,a,b,c)
  754. #define IDirect3DSwapChain9_GetRasterStatus(p,a) (p)->lpVtbl->GetRasterStatus(p,a)
  755. #define IDirect3DSwapChain9_GetDisplayMode(p,a) (p)->lpVtbl->GetDisplayMode(p,a)
  756. #define IDirect3DSwapChain9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  757. #define IDirect3DSwapChain9_GetPresentParameters(p,a) (p)->lpVtbl->GetPresentParameters(p,a)
  758. #else
  759. #define IDirect3DSwapChain9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  760. #define IDirect3DSwapChain9_AddRef(p) (p)->AddRef()
  761. #define IDirect3DSwapChain9_Release(p) (p)->Release()
  762. #define IDirect3DSwapChain9_Present(p,a,b,c,d,e) (p)->Present(a,b,c,d,e)
  763. #define IDirect3DSwapChain9_GetFrontBufferData(p,a) (p)->GetFrontBufferData(a)
  764. #define IDirect3DSwapChain9_GetBackBuffer(p,a,b,c) (p)->GetBackBuffer(a,b,c)
  765. #define IDirect3DSwapChain9_GetRasterStatus(p,a) (p)->GetRasterStatus(a)
  766. #define IDirect3DSwapChain9_GetDisplayMode(p,a) (p)->GetDisplayMode(a)
  767. #define IDirect3DSwapChain9_GetDevice(p,a) (p)->GetDevice(a)
  768. #define IDirect3DSwapChain9_GetPresentParameters(p,a) (p)->GetPresentParameters(a)
  769. #endif
  770.  
  771.  
  772.  
  773. #undef INTERFACE
  774. #define INTERFACE IDirect3DResource9
  775.  
  776. DECLARE_INTERFACE_(IDirect3DResource9, IUnknown)
  777. {
  778.     /*** IUnknown methods ***/
  779.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  780.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  781.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  782.  
  783.     /*** IDirect3DResource9 methods ***/
  784.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  785.     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
  786.     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
  787.     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
  788.     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
  789.     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
  790.     STDMETHOD_(void, PreLoad)(THIS) PURE;
  791.     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
  792. };
  793.  
  794. typedef struct IDirect3DResource9 *LPDIRECT3DRESOURCE9, *PDIRECT3DRESOURCE9;
  795.  
  796. #if !defined(__cplusplus) || defined(CINTERFACE)
  797. #define IDirect3DResource9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  798. #define IDirect3DResource9_AddRef(p) (p)->lpVtbl->AddRef(p)
  799. #define IDirect3DResource9_Release(p) (p)->lpVtbl->Release(p)
  800. #define IDirect3DResource9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  801. #define IDirect3DResource9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
  802. #define IDirect3DResource9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
  803. #define IDirect3DResource9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
  804. #define IDirect3DResource9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
  805. #define IDirect3DResource9_GetPriority(p) (p)->lpVtbl->GetPriority(p)
  806. #define IDirect3DResource9_PreLoad(p) (p)->lpVtbl->PreLoad(p)
  807. #define IDirect3DResource9_GetType(p) (p)->lpVtbl->GetType(p)
  808. #else
  809. #define IDirect3DResource9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  810. #define IDirect3DResource9_AddRef(p) (p)->AddRef()
  811. #define IDirect3DResource9_Release(p) (p)->Release()
  812. #define IDirect3DResource9_GetDevice(p,a) (p)->GetDevice(a)
  813. #define IDirect3DResource9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
  814. #define IDirect3DResource9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
  815. #define IDirect3DResource9_FreePrivateData(p,a) (p)->FreePrivateData(a)
  816. #define IDirect3DResource9_SetPriority(p,a) (p)->SetPriority(a)
  817. #define IDirect3DResource9_GetPriority(p) (p)->GetPriority()
  818. #define IDirect3DResource9_PreLoad(p) (p)->PreLoad()
  819. #define IDirect3DResource9_GetType(p) (p)->GetType()
  820. #endif
  821.  
  822.  
  823.  
  824. #undef INTERFACE
  825. #define INTERFACE IDirect3DVertexDeclaration9
  826.  
  827. DECLARE_INTERFACE_(IDirect3DVertexDeclaration9, IUnknown)
  828. {
  829.     /*** IUnknown methods ***/
  830.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  831.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  832.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  833.  
  834.     /*** IDirect3DVertexDeclaration9 methods ***/
  835.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  836.     STDMETHOD(GetDeclaration)(THIS_ D3DVERTEXELEMENT9*,UINT* pNumElements) PURE;
  837. };
  838.  
  839. typedef struct IDirect3DVertexDeclaration9 *LPDIRECT3DVERTEXDECLARATION9, *PDIRECT3DVERTEXDECLARATION9;
  840.  
  841. #if !defined(__cplusplus) || defined(CINTERFACE)
  842. #define IDirect3DVertexDeclaration9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  843. #define IDirect3DVertexDeclaration9_AddRef(p) (p)->lpVtbl->AddRef(p)
  844. #define IDirect3DVertexDeclaration9_Release(p) (p)->lpVtbl->Release(p)
  845. #define IDirect3DVertexDeclaration9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  846. #define IDirect3DVertexDeclaration9_GetDeclaration(p,a,b) (p)->lpVtbl->GetDeclaration(p,a,b)
  847. #else
  848. #define IDirect3DVertexDeclaration9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  849. #define IDirect3DVertexDeclaration9_AddRef(p) (p)->AddRef()
  850. #define IDirect3DVertexDeclaration9_Release(p) (p)->Release()
  851. #define IDirect3DVertexDeclaration9_GetDevice(p,a) (p)->GetDevice(a)
  852. #define IDirect3DVertexDeclaration9_GetDeclaration(p,a,b) (p)->GetDeclaration(a,b)
  853. #endif
  854.  
  855.  
  856.  
  857. #undef INTERFACE
  858. #define INTERFACE IDirect3DVertexShader9
  859.  
  860. DECLARE_INTERFACE_(IDirect3DVertexShader9, IUnknown)
  861. {
  862.     /*** IUnknown methods ***/
  863.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  864.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  865.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  866.  
  867.     /*** IDirect3DVertexShader9 methods ***/
  868.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  869.     STDMETHOD(GetFunction)(THIS_ void*,UINT* pSizeOfData) PURE;
  870. };
  871.  
  872. typedef struct IDirect3DVertexShader9 *LPDIRECT3DVERTEXSHADER9, *PDIRECT3DVERTEXSHADER9;
  873.  
  874. #if !defined(__cplusplus) || defined(CINTERFACE)
  875. #define IDirect3DVertexShader9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  876. #define IDirect3DVertexShader9_AddRef(p) (p)->lpVtbl->AddRef(p)
  877. #define IDirect3DVertexShader9_Release(p) (p)->lpVtbl->Release(p)
  878. #define IDirect3DVertexShader9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  879. #define IDirect3DVertexShader9_GetFunction(p,a,b) (p)->lpVtbl->GetFunction(p,a,b)
  880. #else
  881. #define IDirect3DVertexShader9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  882. #define IDirect3DVertexShader9_AddRef(p) (p)->AddRef()
  883. #define IDirect3DVertexShader9_Release(p) (p)->Release()
  884. #define IDirect3DVertexShader9_GetDevice(p,a) (p)->GetDevice(a)
  885. #define IDirect3DVertexShader9_GetFunction(p,a,b) (p)->GetFunction(a,b)
  886. #endif
  887.  
  888.  
  889.  
  890. #undef INTERFACE
  891. #define INTERFACE IDirect3DPixelShader9
  892.  
  893. DECLARE_INTERFACE_(IDirect3DPixelShader9, IUnknown)
  894. {
  895.     /*** IUnknown methods ***/
  896.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  897.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  898.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  899.  
  900.     /*** IDirect3DPixelShader9 methods ***/
  901.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  902.     STDMETHOD(GetFunction)(THIS_ void*,UINT* pSizeOfData) PURE;
  903. };
  904.  
  905. typedef struct IDirect3DPixelShader9 *LPDIRECT3DPIXELSHADER9, *PDIRECT3DPIXELSHADER9;
  906.  
  907. #if !defined(__cplusplus) || defined(CINTERFACE)
  908. #define IDirect3DPixelShader9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  909. #define IDirect3DPixelShader9_AddRef(p) (p)->lpVtbl->AddRef(p)
  910. #define IDirect3DPixelShader9_Release(p) (p)->lpVtbl->Release(p)
  911. #define IDirect3DPixelShader9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  912. #define IDirect3DPixelShader9_GetFunction(p,a,b) (p)->lpVtbl->GetFunction(p,a,b)
  913. #else
  914. #define IDirect3DPixelShader9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  915. #define IDirect3DPixelShader9_AddRef(p) (p)->AddRef()
  916. #define IDirect3DPixelShader9_Release(p) (p)->Release()
  917. #define IDirect3DPixelShader9_GetDevice(p,a) (p)->GetDevice(a)
  918. #define IDirect3DPixelShader9_GetFunction(p,a,b) (p)->GetFunction(a,b)
  919. #endif
  920.  
  921.  
  922.  
  923.  
  924. #undef INTERFACE
  925. #define INTERFACE IDirect3DBaseTexture9
  926.  
  927. DECLARE_INTERFACE_(IDirect3DBaseTexture9, IDirect3DResource9)
  928. {
  929.     /*** IUnknown methods ***/
  930.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  931.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  932.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  933.  
  934.     /*** IDirect3DResource9 methods ***/
  935.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  936.     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
  937.     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
  938.     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
  939.     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
  940.     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
  941.     STDMETHOD_(void, PreLoad)(THIS) PURE;
  942.     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
  943.     STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
  944.     STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
  945.     STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
  946.     STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE;
  947.     STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE;
  948.     STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE;
  949. };
  950.  
  951. typedef struct IDirect3DBaseTexture9 *LPDIRECT3DBASETEXTURE9, *PDIRECT3DBASETEXTURE9;
  952.  
  953. #if !defined(__cplusplus) || defined(CINTERFACE)
  954. #define IDirect3DBaseTexture9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  955. #define IDirect3DBaseTexture9_AddRef(p) (p)->lpVtbl->AddRef(p)
  956. #define IDirect3DBaseTexture9_Release(p) (p)->lpVtbl->Release(p)
  957. #define IDirect3DBaseTexture9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  958. #define IDirect3DBaseTexture9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
  959. #define IDirect3DBaseTexture9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
  960. #define IDirect3DBaseTexture9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
  961. #define IDirect3DBaseTexture9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
  962. #define IDirect3DBaseTexture9_GetPriority(p) (p)->lpVtbl->GetPriority(p)
  963. #define IDirect3DBaseTexture9_PreLoad(p) (p)->lpVtbl->PreLoad(p)
  964. #define IDirect3DBaseTexture9_GetType(p) (p)->lpVtbl->GetType(p)
  965. #define IDirect3DBaseTexture9_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
  966. #define IDirect3DBaseTexture9_GetLOD(p) (p)->lpVtbl->GetLOD(p)
  967. #define IDirect3DBaseTexture9_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
  968. #define IDirect3DBaseTexture9_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a)
  969. #define IDirect3DBaseTexture9_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p)
  970. #define IDirect3DBaseTexture9_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p)
  971. #else
  972. #define IDirect3DBaseTexture9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  973. #define IDirect3DBaseTexture9_AddRef(p) (p)->AddRef()
  974. #define IDirect3DBaseTexture9_Release(p) (p)->Release()
  975. #define IDirect3DBaseTexture9_GetDevice(p,a) (p)->GetDevice(a)
  976. #define IDirect3DBaseTexture9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
  977. #define IDirect3DBaseTexture9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
  978. #define IDirect3DBaseTexture9_FreePrivateData(p,a) (p)->FreePrivateData(a)
  979. #define IDirect3DBaseTexture9_SetPriority(p,a) (p)->SetPriority(a)
  980. #define IDirect3DBaseTexture9_GetPriority(p) (p)->GetPriority()
  981. #define IDirect3DBaseTexture9_PreLoad(p) (p)->PreLoad()
  982. #define IDirect3DBaseTexture9_GetType(p) (p)->GetType()
  983. #define IDirect3DBaseTexture9_SetLOD(p,a) (p)->SetLOD(a)
  984. #define IDirect3DBaseTexture9_GetLOD(p) (p)->GetLOD()
  985. #define IDirect3DBaseTexture9_GetLevelCount(p) (p)->GetLevelCount()
  986. #define IDirect3DBaseTexture9_SetAutoGenFilterType(p,a) (p)->SetAutoGenFilterType(a)
  987. #define IDirect3DBaseTexture9_GetAutoGenFilterType(p) (p)->GetAutoGenFilterType()
  988. #define IDirect3DBaseTexture9_GenerateMipSubLevels(p) (p)->GenerateMipSubLevels()
  989. #endif
  990.  
  991.  
  992.  
  993.  
  994.  
  995. #undef INTERFACE
  996. #define INTERFACE IDirect3DTexture9
  997.  
  998. DECLARE_INTERFACE_(IDirect3DTexture9, IDirect3DBaseTexture9)
  999. {
  1000.     /*** IUnknown methods ***/
  1001.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  1002.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  1003.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  1004.  
  1005.     /*** IDirect3DBaseTexture9 methods ***/
  1006.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  1007.     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
  1008.     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
  1009.     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
  1010.     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
  1011.     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
  1012.     STDMETHOD_(void, PreLoad)(THIS) PURE;
  1013.     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
  1014.     STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
  1015.     STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
  1016.     STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
  1017.     STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE;
  1018.     STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE;
  1019.     STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE;
  1020.     STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DSURFACE_DESC *pDesc) PURE;
  1021.     STDMETHOD(GetSurfaceLevel)(THIS_ UINT Level,IDirect3DSurface9** ppSurfaceLevel) PURE;
  1022.     STDMETHOD(LockRect)(THIS_ UINT Level,D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE;
  1023.     STDMETHOD(UnlockRect)(THIS_ UINT Level) PURE;
  1024.     STDMETHOD(AddDirtyRect)(THIS_ CONST RECT* pDirtyRect) PURE;
  1025. };
  1026.  
  1027. typedef struct IDirect3DTexture9 *LPDIRECT3DTEXTURE9, *PDIRECT3DTEXTURE9;
  1028.  
  1029. #if !defined(__cplusplus) || defined(CINTERFACE)
  1030. #define IDirect3DTexture9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  1031. #define IDirect3DTexture9_AddRef(p) (p)->lpVtbl->AddRef(p)
  1032. #define IDirect3DTexture9_Release(p) (p)->lpVtbl->Release(p)
  1033. #define IDirect3DTexture9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  1034. #define IDirect3DTexture9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
  1035. #define IDirect3DTexture9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
  1036. #define IDirect3DTexture9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
  1037. #define IDirect3DTexture9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
  1038. #define IDirect3DTexture9_GetPriority(p) (p)->lpVtbl->GetPriority(p)
  1039. #define IDirect3DTexture9_PreLoad(p) (p)->lpVtbl->PreLoad(p)
  1040. #define IDirect3DTexture9_GetType(p) (p)->lpVtbl->GetType(p)
  1041. #define IDirect3DTexture9_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
  1042. #define IDirect3DTexture9_GetLOD(p) (p)->lpVtbl->GetLOD(p)
  1043. #define IDirect3DTexture9_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
  1044. #define IDirect3DTexture9_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a)
  1045. #define IDirect3DTexture9_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p)
  1046. #define IDirect3DTexture9_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p)
  1047. #define IDirect3DTexture9_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b)
  1048. #define IDirect3DTexture9_GetSurfaceLevel(p,a,b) (p)->lpVtbl->GetSurfaceLevel(p,a,b)
  1049. #define IDirect3DTexture9_LockRect(p,a,b,c,d) (p)->lpVtbl->LockRect(p,a,b,c,d)
  1050. #define IDirect3DTexture9_UnlockRect(p,a) (p)->lpVtbl->UnlockRect(p,a)
  1051. #define IDirect3DTexture9_AddDirtyRect(p,a) (p)->lpVtbl->AddDirtyRect(p,a)
  1052. #else
  1053. #define IDirect3DTexture9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  1054. #define IDirect3DTexture9_AddRef(p) (p)->AddRef()
  1055. #define IDirect3DTexture9_Release(p) (p)->Release()
  1056. #define IDirect3DTexture9_GetDevice(p,a) (p)->GetDevice(a)
  1057. #define IDirect3DTexture9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
  1058. #define IDirect3DTexture9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
  1059. #define IDirect3DTexture9_FreePrivateData(p,a) (p)->FreePrivateData(a)
  1060. #define IDirect3DTexture9_SetPriority(p,a) (p)->SetPriority(a)
  1061. #define IDirect3DTexture9_GetPriority(p) (p)->GetPriority()
  1062. #define IDirect3DTexture9_PreLoad(p) (p)->PreLoad()
  1063. #define IDirect3DTexture9_GetType(p) (p)->GetType()
  1064. #define IDirect3DTexture9_SetLOD(p,a) (p)->SetLOD(a)
  1065. #define IDirect3DTexture9_GetLOD(p) (p)->GetLOD()
  1066. #define IDirect3DTexture9_GetLevelCount(p) (p)->GetLevelCount()
  1067. #define IDirect3DTexture9_SetAutoGenFilterType(p,a) (p)->SetAutoGenFilterType(a)
  1068. #define IDirect3DTexture9_GetAutoGenFilterType(p) (p)->GetAutoGenFilterType()
  1069. #define IDirect3DTexture9_GenerateMipSubLevels(p) (p)->GenerateMipSubLevels()
  1070. #define IDirect3DTexture9_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b)
  1071. #define IDirect3DTexture9_GetSurfaceLevel(p,a,b) (p)->GetSurfaceLevel(a,b)
  1072. #define IDirect3DTexture9_LockRect(p,a,b,c,d) (p)->LockRect(a,b,c,d)
  1073. #define IDirect3DTexture9_UnlockRect(p,a) (p)->UnlockRect(a)
  1074. #define IDirect3DTexture9_AddDirtyRect(p,a) (p)->AddDirtyRect(a)
  1075. #endif
  1076.  
  1077.  
  1078.  
  1079.  
  1080.  
  1081. #undef INTERFACE
  1082. #define INTERFACE IDirect3DVolumeTexture9
  1083.  
  1084. DECLARE_INTERFACE_(IDirect3DVolumeTexture9, IDirect3DBaseTexture9)
  1085. {
  1086.     /*** IUnknown methods ***/
  1087.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  1088.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  1089.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  1090.  
  1091.     /*** IDirect3DBaseTexture9 methods ***/
  1092.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  1093.     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
  1094.     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
  1095.     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
  1096.     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
  1097.     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
  1098.     STDMETHOD_(void, PreLoad)(THIS) PURE;
  1099.     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
  1100.     STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
  1101.     STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
  1102.     STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
  1103.     STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE;
  1104.     STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE;
  1105.     STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE;
  1106.     STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DVOLUME_DESC *pDesc) PURE;
  1107.     STDMETHOD(GetVolumeLevel)(THIS_ UINT Level,IDirect3DVolume9** ppVolumeLevel) PURE;
  1108.     STDMETHOD(LockBox)(THIS_ UINT Level,D3DLOCKED_BOX* pLockedVolume,CONST D3DBOX* pBox,DWORD Flags) PURE;
  1109.     STDMETHOD(UnlockBox)(THIS_ UINT Level) PURE;
  1110.     STDMETHOD(AddDirtyBox)(THIS_ CONST D3DBOX* pDirtyBox) PURE;
  1111. };
  1112.  
  1113. typedef struct IDirect3DVolumeTexture9 *LPDIRECT3DVOLUMETEXTURE9, *PDIRECT3DVOLUMETEXTURE9;
  1114.  
  1115. #if !defined(__cplusplus) || defined(CINTERFACE)
  1116. #define IDirect3DVolumeTexture9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  1117. #define IDirect3DVolumeTexture9_AddRef(p) (p)->lpVtbl->AddRef(p)
  1118. #define IDirect3DVolumeTexture9_Release(p) (p)->lpVtbl->Release(p)
  1119. #define IDirect3DVolumeTexture9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  1120. #define IDirect3DVolumeTexture9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
  1121. #define IDirect3DVolumeTexture9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
  1122. #define IDirect3DVolumeTexture9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
  1123. #define IDirect3DVolumeTexture9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
  1124. #define IDirect3DVolumeTexture9_GetPriority(p) (p)->lpVtbl->GetPriority(p)
  1125. #define IDirect3DVolumeTexture9_PreLoad(p) (p)->lpVtbl->PreLoad(p)
  1126. #define IDirect3DVolumeTexture9_GetType(p) (p)->lpVtbl->GetType(p)
  1127. #define IDirect3DVolumeTexture9_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
  1128. #define IDirect3DVolumeTexture9_GetLOD(p) (p)->lpVtbl->GetLOD(p)
  1129. #define IDirect3DVolumeTexture9_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
  1130. #define IDirect3DVolumeTexture9_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a)
  1131. #define IDirect3DVolumeTexture9_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p)
  1132. #define IDirect3DVolumeTexture9_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p)
  1133. #define IDirect3DVolumeTexture9_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b)
  1134. #define IDirect3DVolumeTexture9_GetVolumeLevel(p,a,b) (p)->lpVtbl->GetVolumeLevel(p,a,b)
  1135. #define IDirect3DVolumeTexture9_LockBox(p,a,b,c,d) (p)->lpVtbl->LockBox(p,a,b,c,d)
  1136. #define IDirect3DVolumeTexture9_UnlockBox(p,a) (p)->lpVtbl->UnlockBox(p,a)
  1137. #define IDirect3DVolumeTexture9_AddDirtyBox(p,a) (p)->lpVtbl->AddDirtyBox(p,a)
  1138. #else
  1139. #define IDirect3DVolumeTexture9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  1140. #define IDirect3DVolumeTexture9_AddRef(p) (p)->AddRef()
  1141. #define IDirect3DVolumeTexture9_Release(p) (p)->Release()
  1142. #define IDirect3DVolumeTexture9_GetDevice(p,a) (p)->GetDevice(a)
  1143. #define IDirect3DVolumeTexture9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
  1144. #define IDirect3DVolumeTexture9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
  1145. #define IDirect3DVolumeTexture9_FreePrivateData(p,a) (p)->FreePrivateData(a)
  1146. #define IDirect3DVolumeTexture9_SetPriority(p,a) (p)->SetPriority(a)
  1147. #define IDirect3DVolumeTexture9_GetPriority(p) (p)->GetPriority()
  1148. #define IDirect3DVolumeTexture9_PreLoad(p) (p)->PreLoad()
  1149. #define IDirect3DVolumeTexture9_GetType(p) (p)->GetType()
  1150. #define IDirect3DVolumeTexture9_SetLOD(p,a) (p)->SetLOD(a)
  1151. #define IDirect3DVolumeTexture9_GetLOD(p) (p)->GetLOD()
  1152. #define IDirect3DVolumeTexture9_GetLevelCount(p) (p)->GetLevelCount()
  1153. #define IDirect3DVolumeTexture9_SetAutoGenFilterType(p,a) (p)->SetAutoGenFilterType(a)
  1154. #define IDirect3DVolumeTexture9_GetAutoGenFilterType(p) (p)->GetAutoGenFilterType()
  1155. #define IDirect3DVolumeTexture9_GenerateMipSubLevels(p) (p)->GenerateMipSubLevels()
  1156. #define IDirect3DVolumeTexture9_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b)
  1157. #define IDirect3DVolumeTexture9_GetVolumeLevel(p,a,b) (p)->GetVolumeLevel(a,b)
  1158. #define IDirect3DVolumeTexture9_LockBox(p,a,b,c,d) (p)->LockBox(a,b,c,d)
  1159. #define IDirect3DVolumeTexture9_UnlockBox(p,a) (p)->UnlockBox(a)
  1160. #define IDirect3DVolumeTexture9_AddDirtyBox(p,a) (p)->AddDirtyBox(a)
  1161. #endif
  1162.  
  1163.  
  1164.  
  1165.  
  1166.  
  1167. #undef INTERFACE
  1168. #define INTERFACE IDirect3DCubeTexture9
  1169.  
  1170. DECLARE_INTERFACE_(IDirect3DCubeTexture9, IDirect3DBaseTexture9)
  1171. {
  1172.     /*** IUnknown methods ***/
  1173.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  1174.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  1175.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  1176.  
  1177.     /*** IDirect3DBaseTexture9 methods ***/
  1178.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  1179.     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
  1180.     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
  1181.     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
  1182.     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
  1183.     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
  1184.     STDMETHOD_(void, PreLoad)(THIS) PURE;
  1185.     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
  1186.     STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
  1187.     STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
  1188.     STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
  1189.     STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE;
  1190.     STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE;
  1191.     STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE;
  1192.     STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DSURFACE_DESC *pDesc) PURE;
  1193.     STDMETHOD(GetCubeMapSurface)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level,IDirect3DSurface9** ppCubeMapSurface) PURE;
  1194.     STDMETHOD(LockRect)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level,D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE;
  1195.     STDMETHOD(UnlockRect)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level) PURE;
  1196.     STDMETHOD(AddDirtyRect)(THIS_ D3DCUBEMAP_FACES FaceType,CONST RECT* pDirtyRect) PURE;
  1197. };
  1198.  
  1199. typedef struct IDirect3DCubeTexture9 *LPDIRECT3DCUBETEXTURE9, *PDIRECT3DCUBETEXTURE9;
  1200.  
  1201. #if !defined(__cplusplus) || defined(CINTERFACE)
  1202. #define IDirect3DCubeTexture9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  1203. #define IDirect3DCubeTexture9_AddRef(p) (p)->lpVtbl->AddRef(p)
  1204. #define IDirect3DCubeTexture9_Release(p) (p)->lpVtbl->Release(p)
  1205. #define IDirect3DCubeTexture9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  1206. #define IDirect3DCubeTexture9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
  1207. #define IDirect3DCubeTexture9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
  1208. #define IDirect3DCubeTexture9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
  1209. #define IDirect3DCubeTexture9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
  1210. #define IDirect3DCubeTexture9_GetPriority(p) (p)->lpVtbl->GetPriority(p)
  1211. #define IDirect3DCubeTexture9_PreLoad(p) (p)->lpVtbl->PreLoad(p)
  1212. #define IDirect3DCubeTexture9_GetType(p) (p)->lpVtbl->GetType(p)
  1213. #define IDirect3DCubeTexture9_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a)
  1214. #define IDirect3DCubeTexture9_GetLOD(p) (p)->lpVtbl->GetLOD(p)
  1215. #define IDirect3DCubeTexture9_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p)
  1216. #define IDirect3DCubeTexture9_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a)
  1217. #define IDirect3DCubeTexture9_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p)
  1218. #define IDirect3DCubeTexture9_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p)
  1219. #define IDirect3DCubeTexture9_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b)
  1220. #define IDirect3DCubeTexture9_GetCubeMapSurface(p,a,b,c) (p)->lpVtbl->GetCubeMapSurface(p,a,b,c)
  1221. #define IDirect3DCubeTexture9_LockRect(p,a,b,c,d,e) (p)->lpVtbl->LockRect(p,a,b,c,d,e)
  1222. #define IDirect3DCubeTexture9_UnlockRect(p,a,b) (p)->lpVtbl->UnlockRect(p,a,b)
  1223. #define IDirect3DCubeTexture9_AddDirtyRect(p,a,b) (p)->lpVtbl->AddDirtyRect(p,a,b)
  1224. #else
  1225. #define IDirect3DCubeTexture9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  1226. #define IDirect3DCubeTexture9_AddRef(p) (p)->AddRef()
  1227. #define IDirect3DCubeTexture9_Release(p) (p)->Release()
  1228. #define IDirect3DCubeTexture9_GetDevice(p,a) (p)->GetDevice(a)
  1229. #define IDirect3DCubeTexture9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
  1230. #define IDirect3DCubeTexture9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
  1231. #define IDirect3DCubeTexture9_FreePrivateData(p,a) (p)->FreePrivateData(a)
  1232. #define IDirect3DCubeTexture9_SetPriority(p,a) (p)->SetPriority(a)
  1233. #define IDirect3DCubeTexture9_GetPriority(p) (p)->GetPriority()
  1234. #define IDirect3DCubeTexture9_PreLoad(p) (p)->PreLoad()
  1235. #define IDirect3DCubeTexture9_GetType(p) (p)->GetType()
  1236. #define IDirect3DCubeTexture9_SetLOD(p,a) (p)->SetLOD(a)
  1237. #define IDirect3DCubeTexture9_GetLOD(p) (p)->GetLOD()
  1238. #define IDirect3DCubeTexture9_GetLevelCount(p) (p)->GetLevelCount()
  1239. #define IDirect3DCubeTexture9_SetAutoGenFilterType(p,a) (p)->SetAutoGenFilterType(a)
  1240. #define IDirect3DCubeTexture9_GetAutoGenFilterType(p) (p)->GetAutoGenFilterType()
  1241. #define IDirect3DCubeTexture9_GenerateMipSubLevels(p) (p)->GenerateMipSubLevels()
  1242. #define IDirect3DCubeTexture9_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b)
  1243. #define IDirect3DCubeTexture9_GetCubeMapSurface(p,a,b,c) (p)->GetCubeMapSurface(a,b,c)
  1244. #define IDirect3DCubeTexture9_LockRect(p,a,b,c,d,e) (p)->LockRect(a,b,c,d,e)
  1245. #define IDirect3DCubeTexture9_UnlockRect(p,a,b) (p)->UnlockRect(a,b)
  1246. #define IDirect3DCubeTexture9_AddDirtyRect(p,a,b) (p)->AddDirtyRect(a,b)
  1247. #endif
  1248.  
  1249.  
  1250.  
  1251.  
  1252. #undef INTERFACE
  1253. #define INTERFACE IDirect3DVertexBuffer9
  1254.  
  1255. DECLARE_INTERFACE_(IDirect3DVertexBuffer9, IDirect3DResource9)
  1256. {
  1257.     /*** IUnknown methods ***/
  1258.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  1259.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  1260.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  1261.  
  1262.     /*** IDirect3DResource9 methods ***/
  1263.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  1264.     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
  1265.     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
  1266.     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
  1267.     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
  1268.     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
  1269.     STDMETHOD_(void, PreLoad)(THIS) PURE;
  1270.     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
  1271.     STDMETHOD(Lock)(THIS_ UINT OffsetToLock,UINT SizeToLock,void** ppbData,DWORD Flags) PURE;
  1272.     STDMETHOD(Unlock)(THIS) PURE;
  1273.     STDMETHOD(GetDesc)(THIS_ D3DVERTEXBUFFER_DESC *pDesc) PURE;
  1274. };
  1275.  
  1276. typedef struct IDirect3DVertexBuffer9 *LPDIRECT3DVERTEXBUFFER9, *PDIRECT3DVERTEXBUFFER9;
  1277.  
  1278. #if !defined(__cplusplus) || defined(CINTERFACE)
  1279. #define IDirect3DVertexBuffer9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  1280. #define IDirect3DVertexBuffer9_AddRef(p) (p)->lpVtbl->AddRef(p)
  1281. #define IDirect3DVertexBuffer9_Release(p) (p)->lpVtbl->Release(p)
  1282. #define IDirect3DVertexBuffer9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  1283. #define IDirect3DVertexBuffer9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
  1284. #define IDirect3DVertexBuffer9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
  1285. #define IDirect3DVertexBuffer9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
  1286. #define IDirect3DVertexBuffer9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
  1287. #define IDirect3DVertexBuffer9_GetPriority(p) (p)->lpVtbl->GetPriority(p)
  1288. #define IDirect3DVertexBuffer9_PreLoad(p) (p)->lpVtbl->PreLoad(p)
  1289. #define IDirect3DVertexBuffer9_GetType(p) (p)->lpVtbl->GetType(p)
  1290. #define IDirect3DVertexBuffer9_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d)
  1291. #define IDirect3DVertexBuffer9_Unlock(p) (p)->lpVtbl->Unlock(p)
  1292. #define IDirect3DVertexBuffer9_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
  1293. #else
  1294. #define IDirect3DVertexBuffer9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  1295. #define IDirect3DVertexBuffer9_AddRef(p) (p)->AddRef()
  1296. #define IDirect3DVertexBuffer9_Release(p) (p)->Release()
  1297. #define IDirect3DVertexBuffer9_GetDevice(p,a) (p)->GetDevice(a)
  1298. #define IDirect3DVertexBuffer9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
  1299. #define IDirect3DVertexBuffer9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
  1300. #define IDirect3DVertexBuffer9_FreePrivateData(p,a) (p)->FreePrivateData(a)
  1301. #define IDirect3DVertexBuffer9_SetPriority(p,a) (p)->SetPriority(a)
  1302. #define IDirect3DVertexBuffer9_GetPriority(p) (p)->GetPriority()
  1303. #define IDirect3DVertexBuffer9_PreLoad(p) (p)->PreLoad()
  1304. #define IDirect3DVertexBuffer9_GetType(p) (p)->GetType()
  1305. #define IDirect3DVertexBuffer9_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d)
  1306. #define IDirect3DVertexBuffer9_Unlock(p) (p)->Unlock()
  1307. #define IDirect3DVertexBuffer9_GetDesc(p,a) (p)->GetDesc(a)
  1308. #endif
  1309.  
  1310.  
  1311.  
  1312.  
  1313. #undef INTERFACE
  1314. #define INTERFACE IDirect3DIndexBuffer9
  1315.  
  1316. DECLARE_INTERFACE_(IDirect3DIndexBuffer9, IDirect3DResource9)
  1317. {
  1318.     /*** IUnknown methods ***/
  1319.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  1320.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  1321.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  1322.  
  1323.     /*** IDirect3DResource9 methods ***/
  1324.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  1325.     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
  1326.     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
  1327.     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
  1328.     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
  1329.     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
  1330.     STDMETHOD_(void, PreLoad)(THIS) PURE;
  1331.     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
  1332.     STDMETHOD(Lock)(THIS_ UINT OffsetToLock,UINT SizeToLock,void** ppbData,DWORD Flags) PURE;
  1333.     STDMETHOD(Unlock)(THIS) PURE;
  1334.     STDMETHOD(GetDesc)(THIS_ D3DINDEXBUFFER_DESC *pDesc) PURE;
  1335. };
  1336.  
  1337. typedef struct IDirect3DIndexBuffer9 *LPDIRECT3DINDEXBUFFER9, *PDIRECT3DINDEXBUFFER9;
  1338.  
  1339. #if !defined(__cplusplus) || defined(CINTERFACE)
  1340. #define IDirect3DIndexBuffer9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  1341. #define IDirect3DIndexBuffer9_AddRef(p) (p)->lpVtbl->AddRef(p)
  1342. #define IDirect3DIndexBuffer9_Release(p) (p)->lpVtbl->Release(p)
  1343. #define IDirect3DIndexBuffer9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  1344. #define IDirect3DIndexBuffer9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
  1345. #define IDirect3DIndexBuffer9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
  1346. #define IDirect3DIndexBuffer9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
  1347. #define IDirect3DIndexBuffer9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
  1348. #define IDirect3DIndexBuffer9_GetPriority(p) (p)->lpVtbl->GetPriority(p)
  1349. #define IDirect3DIndexBuffer9_PreLoad(p) (p)->lpVtbl->PreLoad(p)
  1350. #define IDirect3DIndexBuffer9_GetType(p) (p)->lpVtbl->GetType(p)
  1351. #define IDirect3DIndexBuffer9_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d)
  1352. #define IDirect3DIndexBuffer9_Unlock(p) (p)->lpVtbl->Unlock(p)
  1353. #define IDirect3DIndexBuffer9_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
  1354. #else
  1355. #define IDirect3DIndexBuffer9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  1356. #define IDirect3DIndexBuffer9_AddRef(p) (p)->AddRef()
  1357. #define IDirect3DIndexBuffer9_Release(p) (p)->Release()
  1358. #define IDirect3DIndexBuffer9_GetDevice(p,a) (p)->GetDevice(a)
  1359. #define IDirect3DIndexBuffer9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
  1360. #define IDirect3DIndexBuffer9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
  1361. #define IDirect3DIndexBuffer9_FreePrivateData(p,a) (p)->FreePrivateData(a)
  1362. #define IDirect3DIndexBuffer9_SetPriority(p,a) (p)->SetPriority(a)
  1363. #define IDirect3DIndexBuffer9_GetPriority(p) (p)->GetPriority()
  1364. #define IDirect3DIndexBuffer9_PreLoad(p) (p)->PreLoad()
  1365. #define IDirect3DIndexBuffer9_GetType(p) (p)->GetType()
  1366. #define IDirect3DIndexBuffer9_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d)
  1367. #define IDirect3DIndexBuffer9_Unlock(p) (p)->Unlock()
  1368. #define IDirect3DIndexBuffer9_GetDesc(p,a) (p)->GetDesc(a)
  1369. #endif
  1370.  
  1371.  
  1372.  
  1373.  
  1374. #undef INTERFACE
  1375. #define INTERFACE IDirect3DSurface9
  1376.  
  1377. DECLARE_INTERFACE_(IDirect3DSurface9, IDirect3DResource9)
  1378. {
  1379.     /*** IUnknown methods ***/
  1380.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  1381.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  1382.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  1383.  
  1384.     /*** IDirect3DResource9 methods ***/
  1385.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  1386.     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
  1387.     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
  1388.     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
  1389.     STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
  1390.     STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
  1391.     STDMETHOD_(void, PreLoad)(THIS) PURE;
  1392.     STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;
  1393.     STDMETHOD(GetContainer)(THIS_ REFIID riid,void** ppContainer) PURE;
  1394.     STDMETHOD(GetDesc)(THIS_ D3DSURFACE_DESC *pDesc) PURE;
  1395.     STDMETHOD(LockRect)(THIS_ D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE;
  1396.     STDMETHOD(UnlockRect)(THIS) PURE;
  1397.     STDMETHOD(GetDC)(THIS_ HDC *phdc) PURE;
  1398.     STDMETHOD(ReleaseDC)(THIS_ HDC hdc) PURE;
  1399. };
  1400.  
  1401. typedef struct IDirect3DSurface9 *LPDIRECT3DSURFACE9, *PDIRECT3DSURFACE9;
  1402.  
  1403. #if !defined(__cplusplus) || defined(CINTERFACE)
  1404. #define IDirect3DSurface9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  1405. #define IDirect3DSurface9_AddRef(p) (p)->lpVtbl->AddRef(p)
  1406. #define IDirect3DSurface9_Release(p) (p)->lpVtbl->Release(p)
  1407. #define IDirect3DSurface9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  1408. #define IDirect3DSurface9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
  1409. #define IDirect3DSurface9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
  1410. #define IDirect3DSurface9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
  1411. #define IDirect3DSurface9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a)
  1412. #define IDirect3DSurface9_GetPriority(p) (p)->lpVtbl->GetPriority(p)
  1413. #define IDirect3DSurface9_PreLoad(p) (p)->lpVtbl->PreLoad(p)
  1414. #define IDirect3DSurface9_GetType(p) (p)->lpVtbl->GetType(p)
  1415. #define IDirect3DSurface9_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b)
  1416. #define IDirect3DSurface9_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
  1417. #define IDirect3DSurface9_LockRect(p,a,b,c) (p)->lpVtbl->LockRect(p,a,b,c)
  1418. #define IDirect3DSurface9_UnlockRect(p) (p)->lpVtbl->UnlockRect(p)
  1419. #define IDirect3DSurface9_GetDC(p,a) (p)->lpVtbl->GetDC(p,a)
  1420. #define IDirect3DSurface9_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a)
  1421. #else
  1422. #define IDirect3DSurface9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  1423. #define IDirect3DSurface9_AddRef(p) (p)->AddRef()
  1424. #define IDirect3DSurface9_Release(p) (p)->Release()
  1425. #define IDirect3DSurface9_GetDevice(p,a) (p)->GetDevice(a)
  1426. #define IDirect3DSurface9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
  1427. #define IDirect3DSurface9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
  1428. #define IDirect3DSurface9_FreePrivateData(p,a) (p)->FreePrivateData(a)
  1429. #define IDirect3DSurface9_SetPriority(p,a) (p)->SetPriority(a)
  1430. #define IDirect3DSurface9_GetPriority(p) (p)->GetPriority()
  1431. #define IDirect3DSurface9_PreLoad(p) (p)->PreLoad()
  1432. #define IDirect3DSurface9_GetType(p) (p)->GetType()
  1433. #define IDirect3DSurface9_GetContainer(p,a,b) (p)->GetContainer(a,b)
  1434. #define IDirect3DSurface9_GetDesc(p,a) (p)->GetDesc(a)
  1435. #define IDirect3DSurface9_LockRect(p,a,b,c) (p)->LockRect(a,b,c)
  1436. #define IDirect3DSurface9_UnlockRect(p) (p)->UnlockRect()
  1437. #define IDirect3DSurface9_GetDC(p,a) (p)->GetDC(a)
  1438. #define IDirect3DSurface9_ReleaseDC(p,a) (p)->ReleaseDC(a)
  1439. #endif
  1440.  
  1441.  
  1442.  
  1443.  
  1444. #undef INTERFACE
  1445. #define INTERFACE IDirect3DVolume9
  1446.  
  1447. DECLARE_INTERFACE_(IDirect3DVolume9, IUnknown)
  1448. {
  1449.     /*** IUnknown methods ***/
  1450.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  1451.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  1452.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  1453.  
  1454.     /*** IDirect3DVolume9 methods ***/
  1455.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  1456.     STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
  1457.     STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
  1458.     STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
  1459.     STDMETHOD(GetContainer)(THIS_ REFIID riid,void** ppContainer) PURE;
  1460.     STDMETHOD(GetDesc)(THIS_ D3DVOLUME_DESC *pDesc) PURE;
  1461.     STDMETHOD(LockBox)(THIS_ D3DLOCKED_BOX * pLockedVolume,CONST D3DBOX* pBox,DWORD Flags) PURE;
  1462.     STDMETHOD(UnlockBox)(THIS) PURE;
  1463. };
  1464.  
  1465. typedef struct IDirect3DVolume9 *LPDIRECT3DVOLUME9, *PDIRECT3DVOLUME9;
  1466.  
  1467. #if !defined(__cplusplus) || defined(CINTERFACE)
  1468. #define IDirect3DVolume9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  1469. #define IDirect3DVolume9_AddRef(p) (p)->lpVtbl->AddRef(p)
  1470. #define IDirect3DVolume9_Release(p) (p)->lpVtbl->Release(p)
  1471. #define IDirect3DVolume9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  1472. #define IDirect3DVolume9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d)
  1473. #define IDirect3DVolume9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c)
  1474. #define IDirect3DVolume9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a)
  1475. #define IDirect3DVolume9_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b)
  1476. #define IDirect3DVolume9_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a)
  1477. #define IDirect3DVolume9_LockBox(p,a,b,c) (p)->lpVtbl->LockBox(p,a,b,c)
  1478. #define IDirect3DVolume9_UnlockBox(p) (p)->lpVtbl->UnlockBox(p)
  1479. #else
  1480. #define IDirect3DVolume9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  1481. #define IDirect3DVolume9_AddRef(p) (p)->AddRef()
  1482. #define IDirect3DVolume9_Release(p) (p)->Release()
  1483. #define IDirect3DVolume9_GetDevice(p,a) (p)->GetDevice(a)
  1484. #define IDirect3DVolume9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d)
  1485. #define IDirect3DVolume9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c)
  1486. #define IDirect3DVolume9_FreePrivateData(p,a) (p)->FreePrivateData(a)
  1487. #define IDirect3DVolume9_GetContainer(p,a,b) (p)->GetContainer(a,b)
  1488. #define IDirect3DVolume9_GetDesc(p,a) (p)->GetDesc(a)
  1489. #define IDirect3DVolume9_LockBox(p,a,b,c) (p)->LockBox(a,b,c)
  1490. #define IDirect3DVolume9_UnlockBox(p) (p)->UnlockBox()
  1491. #endif
  1492.  
  1493.  
  1494.  
  1495. #undef INTERFACE
  1496. #define INTERFACE IDirect3DQuery9
  1497.  
  1498. DECLARE_INTERFACE_(IDirect3DQuery9, IUnknown)
  1499. {
  1500.     /*** IUnknown methods ***/
  1501.     STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
  1502.     STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  1503.     STDMETHOD_(ULONG,Release)(THIS) PURE;
  1504.  
  1505.     /*** IDirect3DQuery9 methods ***/
  1506.     STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
  1507.     STDMETHOD_(D3DQUERYTYPE, GetType)(THIS) PURE;
  1508.     STDMETHOD_(DWORD, GetDataSize)(THIS) PURE;
  1509.     STDMETHOD(Issue)(THIS_ DWORD dwIssueFlags) PURE;
  1510.     STDMETHOD(GetData)(THIS_ void* pData,DWORD dwSize,DWORD dwGetDataFlags) PURE;
  1511. };
  1512.  
  1513. typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9;
  1514.  
  1515. #if !defined(__cplusplus) || defined(CINTERFACE)
  1516. #define IDirect3DQuery9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  1517. #define IDirect3DQuery9_AddRef(p) (p)->lpVtbl->AddRef(p)
  1518. #define IDirect3DQuery9_Release(p) (p)->lpVtbl->Release(p)
  1519. #define IDirect3DQuery9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  1520. #define IDirect3DQuery9_GetType(p) (p)->lpVtbl->GetType(p)
  1521. #define IDirect3DQuery9_GetDataSize(p) (p)->lpVtbl->GetDataSize(p)
  1522. #define IDirect3DQuery9_Issue(p,a) (p)->lpVtbl->Issue(p,a)
  1523. #define IDirect3DQuery9_GetData(p,a,b,c) (p)->lpVtbl->GetData(p,a,b,c)
  1524. #else
  1525. #define IDirect3DQuery9_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  1526. #define IDirect3DQuery9_AddRef(p) (p)->AddRef()
  1527. #define IDirect3DQuery9_Release(p) (p)->Release()
  1528. #define IDirect3DQuery9_GetDevice(p,a) (p)->GetDevice(a)
  1529. #define IDirect3DQuery9_GetType(p) (p)->GetType()
  1530. #define IDirect3DQuery9_GetDataSize(p) (p)->GetDataSize()
  1531. #define IDirect3DQuery9_Issue(p,a) (p)->Issue(a)
  1532. #define IDirect3DQuery9_GetData(p,a,b,c) (p)->GetData(a,b,c)
  1533. #endif
  1534.  
  1535.  
  1536. /****************************************************************************
  1537.  * Flags for SetPrivateData method on all D3D9 interfaces
  1538.  *
  1539.  * The passed pointer is an IUnknown ptr. The SizeOfData argument to SetPrivateData
  1540.  * must be set to sizeof(IUnknown*). Direct3D will call AddRef through this
  1541.  * pointer and Release when the private data is destroyed. The data will be
  1542.  * destroyed when another SetPrivateData with the same GUID is set, when
  1543.  * FreePrivateData is called, or when the D3D9 object is freed.
  1544.  ****************************************************************************/
  1545. #define D3DSPD_IUNKNOWN                         0x00000001L
  1546.  
  1547. /****************************************************************************
  1548.  *
  1549.  * Flags for IDirect3D9::CreateDevice's BehaviorFlags
  1550.  *
  1551.  ****************************************************************************/
  1552.  
  1553. #define D3DCREATE_FPU_PRESERVE                  0x00000002L
  1554. #define D3DCREATE_MULTITHREADED                 0x00000004L
  1555.  
  1556. #define D3DCREATE_PUREDEVICE                    0x00000010L
  1557. #define D3DCREATE_SOFTWARE_VERTEXPROCESSING     0x00000020L
  1558. #define D3DCREATE_HARDWARE_VERTEXPROCESSING     0x00000040L
  1559. #define D3DCREATE_MIXED_VERTEXPROCESSING        0x00000080L
  1560.  
  1561. #define D3DCREATE_DISABLE_DRIVER_MANAGEMENT     0x00000100L
  1562. #define D3DCREATE_ADAPTERGROUP_DEVICE           0x00000200L
  1563.  
  1564.  
  1565. /****************************************************************************
  1566.  *
  1567.  * Parameter for IDirect3D9::CreateDevice's iAdapter
  1568.  *
  1569.  ****************************************************************************/
  1570.  
  1571. #define D3DADAPTER_DEFAULT                     0
  1572.  
  1573. /****************************************************************************
  1574.  *
  1575.  * Flags for IDirect3D9::EnumAdapters
  1576.  *
  1577.  ****************************************************************************/
  1578.  
  1579. #define D3DENUM_WHQL_LEVEL                      0x00000002L
  1580.  
  1581. /****************************************************************************
  1582.  *
  1583.  * Maximum number of back-buffers supported in DX8
  1584.  *
  1585.  ****************************************************************************/
  1586.  
  1587. #define D3DPRESENT_BACK_BUFFERS_MAX             3L
  1588.  
  1589. /****************************************************************************
  1590.  *
  1591.  * Flags for IDirect3DDevice9::SetGammaRamp
  1592.  *
  1593.  ****************************************************************************/
  1594.  
  1595. #define D3DSGR_NO_CALIBRATION                  0x00000000L
  1596. #define D3DSGR_CALIBRATE                       0x00000001L
  1597.  
  1598. /****************************************************************************
  1599.  *
  1600.  * Flags for IDirect3DDevice9::SetCursorPosition
  1601.  *
  1602.  ****************************************************************************/
  1603.  
  1604. #define D3DCURSOR_IMMEDIATE_UPDATE             0x00000001L
  1605.  
  1606. /****************************************************************************
  1607.  *
  1608.  * Flags for IDirect3DSwapChain9::Present
  1609.  *
  1610.  ****************************************************************************/
  1611.  
  1612. #define D3DPRESENT_DONOTWAIT                   0x00000001L
  1613. #define D3DPRESENT_LINEAR_CONTENT              0x00000002L
  1614.  
  1615. /****************************************************************************
  1616.  *
  1617.  * Flags for DrawPrimitive/DrawIndexedPrimitive
  1618.  *   Also valid for Begin/BeginIndexed
  1619.  *   Also valid for VertexBuffer::CreateVertexBuffer
  1620.  ****************************************************************************/
  1621.  
  1622.  
  1623. /*
  1624.  *  DirectDraw error codes
  1625.  */
  1626. #define _FACD3D  0x876
  1627. #define MAKE_D3DHRESULT( code )  MAKE_HRESULT( 1, _FACD3D, code )
  1628. #define MAKE_D3DSTATUS( code )  MAKE_HRESULT( 0, _FACD3D, code )
  1629.  
  1630. /*
  1631.  * Direct3D Errors
  1632.  */
  1633. #define D3D_OK                              S_OK
  1634.  
  1635. #define D3DERR_WRONGTEXTUREFORMAT               MAKE_D3DHRESULT(2072)
  1636. #define D3DERR_UNSUPPORTEDCOLOROPERATION        MAKE_D3DHRESULT(2073)
  1637. #define D3DERR_UNSUPPORTEDCOLORARG              MAKE_D3DHRESULT(2074)
  1638. #define D3DERR_UNSUPPORTEDALPHAOPERATION        MAKE_D3DHRESULT(2075)
  1639. #define D3DERR_UNSUPPORTEDALPHAARG              MAKE_D3DHRESULT(2076)
  1640. #define D3DERR_TOOMANYOPERATIONS                MAKE_D3DHRESULT(2077)
  1641. #define D3DERR_CONFLICTINGTEXTUREFILTER         MAKE_D3DHRESULT(2078)
  1642. #define D3DERR_UNSUPPORTEDFACTORVALUE           MAKE_D3DHRESULT(2079)
  1643. #define D3DERR_CONFLICTINGRENDERSTATE           MAKE_D3DHRESULT(2081)
  1644. #define D3DERR_UNSUPPORTEDTEXTUREFILTER         MAKE_D3DHRESULT(2082)
  1645. #define D3DERR_CONFLICTINGTEXTUREPALETTE        MAKE_D3DHRESULT(2086)
  1646. #define D3DERR_DRIVERINTERNALERROR              MAKE_D3DHRESULT(2087)
  1647.  
  1648. #define D3DERR_NOTFOUND                         MAKE_D3DHRESULT(2150)
  1649. #define D3DERR_MOREDATA                         MAKE_D3DHRESULT(2151)
  1650. #define D3DERR_DEVICELOST                       MAKE_D3DHRESULT(2152)
  1651. #define D3DERR_DEVICENOTRESET                   MAKE_D3DHRESULT(2153)
  1652. #define D3DERR_NOTAVAILABLE                     MAKE_D3DHRESULT(2154)
  1653. #define D3DERR_OUTOFVIDEOMEMORY                 MAKE_D3DHRESULT(380)
  1654. #define D3DERR_INVALIDDEVICE                    MAKE_D3DHRESULT(2155)
  1655. #define D3DERR_INVALIDCALL                      MAKE_D3DHRESULT(2156)
  1656. #define D3DERR_DRIVERINVALIDCALL                MAKE_D3DHRESULT(2157)
  1657. #define D3DERR_WASSTILLDRAWING                  MAKE_D3DHRESULT(540)
  1658. #define D3DOK_NOAUTOGEN                         MAKE_D3DSTATUS(2159)
  1659.  
  1660.  
  1661. #ifdef __cplusplus
  1662. };
  1663. #endif
  1664.  
  1665. #endif /* (DIRECT3D_VERSION >= 0x0900) */
  1666. #endif /* _D3D_H_ */
  1667.  
  1668.