From 68d6b7317c1a211a7ebc0c3dd7313da90533cbc4 Mon Sep 17 00:00:00 2001 From: gho tik Date: Wed, 6 Feb 2013 11:19:16 -0500 Subject: [PATCH] v2_02_21_src Former-commit-id: 19a4107c5167d803a3f7d0d58852c52f719c3610 --- Include/d3d8.txt | 1279 ------ Include/d3d9.h | 921 ++++ Include/d3d9.txt | 1870 -------- Include/d3d9caps.h | 93 +- Include/d3d9types.h | 567 ++- Include/dxdiag.txt | 185 - Include/dxwnd.h | 2 + build/dxwnd.dll | 4 +- build/dxwnd.exe | 4 +- build/dxwnd.ini | 4960 +-------------------- build/readme-relnotes.txt | 9 +- dll/dxhook.cpp | 144 +- dll/dxhook.h | 17 +- dll/dxkernel32.cpp | 331 ++ dll/dxole32.cpp | 100 + dll/dxuser32.cpp | 140 + dll/dxwcore.cpp | 63 +- dll/dxwcore.hpp | 31 + dll/dxwnd.cpp | 2 +- dll/dxwnd.vs2008.suo | Bin 58368 -> 108032 bytes dll/dxwnd.vs2008.vcproj | 16 + dll/dxwnd.vs2008.vcproj.User-PC.User.user | 65 - dll/glhook.cpp | 3 + dll/glhook.h | 1 - dll/hd3d.cpp | 518 ++- dll/hddraw.cpp | 108 +- dll/smack.cpp | 52 + dll/syslibs.cpp | 360 +- dll/syslibs.h | 1 + host/MainFrm.cpp | 51 +- host/MainFrm.h | 3 + host/Resource.h | 3 + host/TabCompat.cpp | 1 + host/TabProgram.cpp | 1 + host/TargetDlg.cpp | 2 + host/TargetDlg.h | 2 + host/dxwnd.ini | 5 + host/dxwndhost.aps | Bin 147388 -> 147764 bytes host/dxwndhost.h | 2 - host/dxwndhost.rc | 2 + host/dxwndhost.vs2008.suo | Bin 203776 -> 209920 bytes host/dxwndhostView.cpp | 68 +- host/dxwndhostView.h | 4 + 43 files changed, 3134 insertions(+), 8856 deletions(-) delete mode 100644 Include/d3d8.txt delete mode 100644 Include/d3d9.txt delete mode 100644 Include/dxdiag.txt create mode 100644 dll/dxkernel32.cpp create mode 100644 dll/dxole32.cpp create mode 100644 dll/dxuser32.cpp delete mode 100644 dll/dxwnd.vs2008.vcproj.User-PC.User.user create mode 100644 dll/smack.cpp create mode 100644 host/dxwnd.ini diff --git a/Include/d3d8.txt b/Include/d3d8.txt deleted file mode 100644 index e7a1324..0000000 --- a/Include/d3d8.txt +++ /dev/null @@ -1,1279 +0,0 @@ -/*==========================================================================; - * - * Copyright (C) Microsoft Corporation. All Rights Reserved. - * - * File: d3d8.h - * Content: Direct3D include file - * - ****************************************************************************/ - -#ifndef _D3D8_H_ -#define _D3D8_H_ - -#ifndef DIRECT3D_VERSION -#define DIRECT3D_VERSION 0x0800 -#endif //DIRECT3D_VERSION - -// include this file content only if compiling for DX8 interfaces -#if(DIRECT3D_VERSION >= 0x0800) - - -/* This identifier is passed to Direct3DCreate8 in order to ensure that an - * application was built against the correct header files. This number is - * incremented whenever a header (or other) change would require applications - * to be rebuilt. If the version doesn't match, Direct3DCreate8 will fail. - * (The number itself has no meaning.)*/ - -#define D3D_SDK_VERSION 220 - - -#include - -#define COM_NO_WINDOWS_H -#include - -#include - -#if !defined(HMONITOR_DECLARED) && (WINVER < 0x0500) - #define HMONITOR_DECLARED - DECLARE_HANDLE(HMONITOR); -#endif - -#define D3DAPI WINAPI - -/* - * Interface IID's - */ -#if defined( _WIN32 ) && !defined( _NO_COM) - -/* IID_IDirect3D8 */ -/* {1DD9E8DA-1C77-4d40-B0CF-98FEFDFF9512} */ -DEFINE_GUID(IID_IDirect3D8, 0x1dd9e8da, 0x1c77, 0x4d40, 0xb0, 0xcf, 0x98, 0xfe, 0xfd, 0xff, 0x95, 0x12); - -/* IID_IDirect3DDevice8 */ -/* {7385E5DF-8FE8-41D5-86B6-D7B48547B6CF} */ -DEFINE_GUID(IID_IDirect3DDevice8, 0x7385e5df, 0x8fe8, 0x41d5, 0x86, 0xb6, 0xd7, 0xb4, 0x85, 0x47, 0xb6, 0xcf); - -/* IID_IDirect3DResource8 */ -/* {1B36BB7B-09B7-410a-B445-7D1430D7B33F} */ -DEFINE_GUID(IID_IDirect3DResource8, 0x1b36bb7b, 0x9b7, 0x410a, 0xb4, 0x45, 0x7d, 0x14, 0x30, 0xd7, 0xb3, 0x3f); - -/* IID_IDirect3DBaseTexture8 */ -/* {B4211CFA-51B9-4a9f-AB78-DB99B2BB678E} */ -DEFINE_GUID(IID_IDirect3DBaseTexture8, 0xb4211cfa, 0x51b9, 0x4a9f, 0xab, 0x78, 0xdb, 0x99, 0xb2, 0xbb, 0x67, 0x8e); - -/* IID_IDirect3DTexture8 */ -/* {E4CDD575-2866-4f01-B12E-7EECE1EC9358} */ -DEFINE_GUID(IID_IDirect3DTexture8, 0xe4cdd575, 0x2866, 0x4f01, 0xb1, 0x2e, 0x7e, 0xec, 0xe1, 0xec, 0x93, 0x58); - -/* IID_IDirect3DCubeTexture8 */ -/* {3EE5B968-2ACA-4c34-8BB5-7E0C3D19B750} */ -DEFINE_GUID(IID_IDirect3DCubeTexture8, 0x3ee5b968, 0x2aca, 0x4c34, 0x8b, 0xb5, 0x7e, 0x0c, 0x3d, 0x19, 0xb7, 0x50); - -/* IID_IDirect3DVolumeTexture8 */ -/* {4B8AAAFA-140F-42ba-9131-597EAFAA2EAD} */ -DEFINE_GUID(IID_IDirect3DVolumeTexture8, 0x4b8aaafa, 0x140f, 0x42ba, 0x91, 0x31, 0x59, 0x7e, 0xaf, 0xaa, 0x2e, 0xad); - -/* IID_IDirect3DVertexBuffer8 */ -/* {8AEEEAC7-05F9-44d4-B591-000B0DF1CB95} */ -DEFINE_GUID(IID_IDirect3DVertexBuffer8, 0x8aeeeac7, 0x05f9, 0x44d4, 0xb5, 0x91, 0x00, 0x0b, 0x0d, 0xf1, 0xcb, 0x95); - -/* IID_IDirect3DIndexBuffer8 */ -/* {0E689C9A-053D-44a0-9D92-DB0E3D750F86} */ -DEFINE_GUID(IID_IDirect3DIndexBuffer8, 0x0e689c9a, 0x053d, 0x44a0, 0x9d, 0x92, 0xdb, 0x0e, 0x3d, 0x75, 0x0f, 0x86); - -/* IID_IDirect3DSurface8 */ -/* {B96EEBCA-B326-4ea5-882F-2FF5BAE021DD} */ -DEFINE_GUID(IID_IDirect3DSurface8, 0xb96eebca, 0xb326, 0x4ea5, 0x88, 0x2f, 0x2f, 0xf5, 0xba, 0xe0, 0x21, 0xdd); - -/* IID_IDirect3DVolume8 */ -/* {BD7349F5-14F1-42e4-9C79-972380DB40C0} */ -DEFINE_GUID(IID_IDirect3DVolume8, 0xbd7349f5, 0x14f1, 0x42e4, 0x9c, 0x79, 0x97, 0x23, 0x80, 0xdb, 0x40, 0xc0); - -/* IID_IDirect3DSwapChain8 */ -/* {928C088B-76B9-4C6B-A536-A590853876CD} */ -DEFINE_GUID(IID_IDirect3DSwapChain8, 0x928c088b, 0x76b9, 0x4c6b, 0xa5, 0x36, 0xa5, 0x90, 0x85, 0x38, 0x76, 0xcd); - -#endif - -#ifdef __cplusplus - -interface IDirect3D8; -interface IDirect3DDevice8; - -interface IDirect3DResource8; -interface IDirect3DBaseTexture8; -interface IDirect3DTexture8; -interface IDirect3DVolumeTexture8; -interface IDirect3DCubeTexture8; - -interface IDirect3DVertexBuffer8; -interface IDirect3DIndexBuffer8; - -interface IDirect3DSurface8; -interface IDirect3DVolume8; - -interface IDirect3DSwapChain8; - -#endif - - -typedef interface IDirect3D8 IDirect3D8; -typedef interface IDirect3DDevice8 IDirect3DDevice8; -typedef interface IDirect3DResource8 IDirect3DResource8; -typedef interface IDirect3DBaseTexture8 IDirect3DBaseTexture8; -typedef interface IDirect3DTexture8 IDirect3DTexture8; -typedef interface IDirect3DVolumeTexture8 IDirect3DVolumeTexture8; -typedef interface IDirect3DCubeTexture8 IDirect3DCubeTexture8; -typedef interface IDirect3DVertexBuffer8 IDirect3DVertexBuffer8; -typedef interface IDirect3DIndexBuffer8 IDirect3DIndexBuffer8; -typedef interface IDirect3DSurface8 IDirect3DSurface8; -typedef interface IDirect3DVolume8 IDirect3DVolume8; -typedef interface IDirect3DSwapChain8 IDirect3DSwapChain8; - -#include "d3d8types.h" -#include "d3d8caps.h" - - -#ifdef __cplusplus -extern "C" { -#endif - -/* - * DLL Function for creating a Direct3D8 object. This object supports - * enumeration and allows the creation of Direct3DDevice8 objects. - * Pass the value of the constant D3D_SDK_VERSION to this function, so - * that the run-time can validate that your application was compiled - * against the right headers. - */ - -IDirect3D8 * WINAPI Direct3DCreate8(UINT SDKVersion); - - -/* - * Direct3D interfaces - */ - - - - - - -#undef INTERFACE -#define INTERFACE IDirect3D8 - -DECLARE_INTERFACE_(IDirect3D8, IUnknown) -{ - /*** IUnknown methods ***/ -0 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3D8 methods ***/ - STDMETHOD(RegisterSoftwareDevice)(THIS_ void* pInitializeFunction) PURE; - STDMETHOD_(UINT, GetAdapterCount)(THIS) PURE; - STDMETHOD(GetAdapterIdentifier)(THIS_ UINT Adapter,DWORD Flags,D3DADAPTER_IDENTIFIER8* pIdentifier) PURE; - STDMETHOD_(UINT, GetAdapterModeCount)(THIS_ UINT Adapter) PURE; - STDMETHOD(EnumAdapterModes)(THIS_ UINT Adapter,UINT Mode,D3DDISPLAYMODE* pMode) PURE; - STDMETHOD(GetAdapterDisplayMode)(THIS_ UINT Adapter,D3DDISPLAYMODE* pMode) PURE; - STDMETHOD(CheckDeviceType)(THIS_ UINT Adapter,D3DDEVTYPE CheckType,D3DFORMAT DisplayFormat,D3DFORMAT BackBufferFormat,BOOL Windowed) PURE; -10 STDMETHOD(CheckDeviceFormat)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,DWORD Usage,D3DRESOURCETYPE RType,D3DFORMAT CheckFormat) PURE; - STDMETHOD(CheckDeviceMultiSampleType)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT SurfaceFormat,BOOL Windowed,D3DMULTISAMPLE_TYPE MultiSampleType) PURE; - STDMETHOD(CheckDepthStencilMatch)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,D3DFORMAT RenderTargetFormat,D3DFORMAT DepthStencilFormat) PURE; - STDMETHOD(GetDeviceCaps)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DCAPS8* pCaps) PURE; - STDMETHOD_(HMONITOR, GetAdapterMonitor)(THIS_ UINT Adapter) PURE; -15 STDMETHOD(CreateDevice)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,HWND hFocusWindow,DWORD BehaviorFlags,D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DDevice8** ppReturnedDeviceInterface) PURE; -}; - -typedef struct IDirect3D8 *LPDIRECT3D8, *PDIRECT3D8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3D8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3D8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3D8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3D8_RegisterSoftwareDevice(p,a) (p)->lpVtbl->RegisterSoftwareDevice(p,a) -#define IDirect3D8_GetAdapterCount(p) (p)->lpVtbl->GetAdapterCount(p) -#define IDirect3D8_GetAdapterIdentifier(p,a,b,c) (p)->lpVtbl->GetAdapterIdentifier(p,a,b,c) -#define IDirect3D8_GetAdapterModeCount(p,a) (p)->lpVtbl->GetAdapterModeCount(p,a) -#define IDirect3D8_EnumAdapterModes(p,a,b,c) (p)->lpVtbl->EnumAdapterModes(p,a,b,c) -#define IDirect3D8_GetAdapterDisplayMode(p,a,b) (p)->lpVtbl->GetAdapterDisplayMode(p,a,b) -#define IDirect3D8_CheckDeviceType(p,a,b,c,d,e) (p)->lpVtbl->CheckDeviceType(p,a,b,c,d,e) -#define IDirect3D8_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceFormat(p,a,b,c,d,e,f) -#define IDirect3D8_CheckDeviceMultiSampleType(p,a,b,c,d,e) (p)->lpVtbl->CheckDeviceMultiSampleType(p,a,b,c,d,e) -#define IDirect3D8_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->lpVtbl->CheckDepthStencilMatch(p,a,b,c,d,e) -#define IDirect3D8_GetDeviceCaps(p,a,b,c) (p)->lpVtbl->GetDeviceCaps(p,a,b,c) -#define IDirect3D8_GetAdapterMonitor(p,a) (p)->lpVtbl->GetAdapterMonitor(p,a) -#define IDirect3D8_CreateDevice(p,a,b,c,d,e,f) (p)->lpVtbl->CreateDevice(p,a,b,c,d,e,f) -#else -#define IDirect3D8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3D8_AddRef(p) (p)->AddRef() -#define IDirect3D8_Release(p) (p)->Release() -#define IDirect3D8_RegisterSoftwareDevice(p,a) (p)->RegisterSoftwareDevice(a) -#define IDirect3D8_GetAdapterCount(p) (p)->GetAdapterCount() -#define IDirect3D8_GetAdapterIdentifier(p,a,b,c) (p)->GetAdapterIdentifier(a,b,c) -#define IDirect3D8_GetAdapterModeCount(p,a) (p)->GetAdapterModeCount(a) -#define IDirect3D8_EnumAdapterModes(p,a,b,c) (p)->EnumAdapterModes(a,b,c) -#define IDirect3D8_GetAdapterDisplayMode(p,a,b) (p)->GetAdapterDisplayMode(a,b) -#define IDirect3D8_CheckDeviceType(p,a,b,c,d,e) (p)->CheckDeviceType(a,b,c,d,e) -#define IDirect3D8_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->CheckDeviceFormat(a,b,c,d,e,f) -#define IDirect3D8_CheckDeviceMultiSampleType(p,a,b,c,d,e) (p)->CheckDeviceMultiSampleType(a,b,c,d,e) -#define IDirect3D8_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->CheckDepthStencilMatch(a,b,c,d,e) -#define IDirect3D8_GetDeviceCaps(p,a,b,c) (p)->GetDeviceCaps(a,b,c) -#define IDirect3D8_GetAdapterMonitor(p,a) (p)->GetAdapterMonitor(a) -#define IDirect3D8_CreateDevice(p,a,b,c,d,e,f) (p)->CreateDevice(a,b,c,d,e,f) -#endif - - - - - - - - - - - - - - - - - - - -#undef INTERFACE -#define INTERFACE IDirect3DDevice8 - -DECLARE_INTERFACE_(IDirect3DDevice8, IUnknown) -{ - /*** IUnknown methods ***/ -0 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DDevice8 methods ***/ -3 STDMETHOD(TestCooperativeLevel)(THIS) PURE; - STDMETHOD_(UINT, GetAvailableTextureMem)(THIS) PURE; - STDMETHOD(ResourceManagerDiscardBytes)(THIS_ DWORD Bytes) PURE; - STDMETHOD(GetDirect3D)(THIS_ IDirect3D8** ppD3D8) PURE; - STDMETHOD(GetDeviceCaps)(THIS_ D3DCAPS8* pCaps) PURE; - STDMETHOD(GetDisplayMode)(THIS_ D3DDISPLAYMODE* pMode) PURE; - STDMETHOD(GetCreationParameters)(THIS_ D3DDEVICE_CREATION_PARAMETERS *pParameters) PURE; -10 STDMETHOD(SetCursorProperties)(THIS_ UINT XHotSpot,UINT YHotSpot,IDirect3DSurface8* pCursorBitmap) PURE; - STDMETHOD_(void, SetCursorPosition)(THIS_ int X,int Y,DWORD Flags) PURE; - STDMETHOD_(BOOL, ShowCursor)(THIS_ BOOL bShow) PURE; - STDMETHOD(CreateAdditionalSwapChain)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DSwapChain8** pSwapChain) PURE; - STDMETHOD(Reset)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters) PURE; - STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion) PURE; - STDMETHOD(GetBackBuffer)(THIS_ UINT BackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface8** ppBackBuffer) PURE; - STDMETHOD(GetRasterStatus)(THIS_ D3DRASTER_STATUS* pRasterStatus) PURE; - STDMETHOD_(void, SetGammaRamp)(THIS_ DWORD Flags,CONST D3DGAMMARAMP* pRamp) PURE; - STDMETHOD_(void, GetGammaRamp)(THIS_ D3DGAMMARAMP* pRamp) PURE; -20 STDMETHOD(CreateTexture)(THIS_ UINT Width,UINT Height,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DTexture8** ppTexture) PURE; - STDMETHOD(CreateVolumeTexture)(THIS_ UINT Width,UINT Height,UINT Depth,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DVolumeTexture8** ppVolumeTexture) PURE; - STDMETHOD(CreateCubeTexture)(THIS_ UINT EdgeLength,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DCubeTexture8** ppCubeTexture) PURE; - STDMETHOD(CreateVertexBuffer)(THIS_ UINT Length,DWORD Usage,DWORD FVF,D3DPOOL Pool,IDirect3DVertexBuffer8** ppVertexBuffer) PURE; - STDMETHOD(CreateIndexBuffer)(THIS_ UINT Length,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DIndexBuffer8** ppIndexBuffer) PURE; - STDMETHOD(CreateRenderTarget)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,BOOL Lockable,IDirect3DSurface8** ppSurface) PURE; - STDMETHOD(CreateDepthStencilSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,IDirect3DSurface8** ppSurface) PURE; - STDMETHOD(CreateImageSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,IDirect3DSurface8** ppSurface) PURE; - STDMETHOD(CopyRects)(THIS_ IDirect3DSurface8* pSourceSurface,CONST RECT* pSourceRectsArray,UINT cRects,IDirect3DSurface8* pDestinationSurface,CONST POINT* pDestPointsArray) PURE; - STDMETHOD(UpdateTexture)(THIS_ IDirect3DBaseTexture8* pSourceTexture,IDirect3DBaseTexture8* pDestinationTexture) PURE; -30 STDMETHOD(GetFrontBuffer)(THIS_ IDirect3DSurface8* pDestSurface) PURE; - STDMETHOD(SetRenderTarget)(THIS_ IDirect3DSurface8* pRenderTarget,IDirect3DSurface8* pNewZStencil) PURE; - STDMETHOD(GetRenderTarget)(THIS_ IDirect3DSurface8** ppRenderTarget) PURE; - STDMETHOD(GetDepthStencilSurface)(THIS_ IDirect3DSurface8** ppZStencilSurface) PURE; - STDMETHOD(BeginScene)(THIS) PURE; - STDMETHOD(EndScene)(THIS) PURE; - STDMETHOD(Clear)(THIS_ DWORD Count,CONST D3DRECT* pRects,DWORD Flags,D3DCOLOR Color,float Z,DWORD Stencil) PURE; - STDMETHOD(SetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,CONST D3DMATRIX* pMatrix) PURE; - STDMETHOD(GetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,D3DMATRIX* pMatrix) PURE; - STDMETHOD(MultiplyTransform)(THIS_ D3DTRANSFORMSTATETYPE,CONST D3DMATRIX*) PURE; -40 STDMETHOD(SetViewport)(THIS_ CONST D3DVIEWPORT8* pViewport) PURE; - STDMETHOD(GetViewport)(THIS_ D3DVIEWPORT8* pViewport) PURE; - STDMETHOD(SetMaterial)(THIS_ CONST D3DMATERIAL8* pMaterial) PURE; - STDMETHOD(GetMaterial)(THIS_ D3DMATERIAL8* pMaterial) PURE; - STDMETHOD(SetLight)(THIS_ DWORD Index,CONST D3DLIGHT8*) PURE; - STDMETHOD(GetLight)(THIS_ DWORD Index,D3DLIGHT8*) PURE; - STDMETHOD(LightEnable)(THIS_ DWORD Index,BOOL Enable) PURE; - STDMETHOD(GetLightEnable)(THIS_ DWORD Index,BOOL* pEnable) PURE; - STDMETHOD(SetClipPlane)(THIS_ DWORD Index,CONST float* pPlane) PURE; - STDMETHOD(GetClipPlane)(THIS_ DWORD Index,float* pPlane) PURE; -50 STDMETHOD(SetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD Value) PURE; -51 STDMETHOD(GetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD* pValue) PURE; - STDMETHOD(BeginStateBlock)(THIS) PURE; - STDMETHOD(EndStateBlock)(THIS_ DWORD* pToken) PURE; - STDMETHOD(ApplyStateBlock)(THIS_ DWORD Token) PURE; - STDMETHOD(CaptureStateBlock)(THIS_ DWORD Token) PURE; - STDMETHOD(DeleteStateBlock)(THIS_ DWORD Token) PURE; - STDMETHOD(CreateStateBlock)(THIS_ D3DSTATEBLOCKTYPE Type,DWORD* pToken) PURE; - STDMETHOD(SetClipStatus)(THIS_ CONST D3DCLIPSTATUS8* pClipStatus) PURE; - STDMETHOD(GetClipStatus)(THIS_ D3DCLIPSTATUS8* pClipStatus) PURE; - STDMETHOD(GetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture8** ppTexture) PURE; - STDMETHOD(SetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture8* pTexture) PURE; - STDMETHOD(GetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD* pValue) PURE; - STDMETHOD(SetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD Value) PURE; - STDMETHOD(ValidateDevice)(THIS_ DWORD* pNumPasses) PURE; - STDMETHOD(GetInfo)(THIS_ DWORD DevInfoID,void* pDevInfoStruct,DWORD DevInfoStructSize) PURE; - STDMETHOD(SetPaletteEntries)(THIS_ UINT PaletteNumber,CONST PALETTEENTRY* pEntries) PURE; - STDMETHOD(GetPaletteEntries)(THIS_ UINT PaletteNumber,PALETTEENTRY* pEntries) PURE; - STDMETHOD(SetCurrentTexturePalette)(THIS_ UINT PaletteNumber) PURE; - STDMETHOD(GetCurrentTexturePalette)(THIS_ UINT *PaletteNumber) PURE; - STDMETHOD(DrawPrimitive)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT StartVertex,UINT PrimitiveCount) PURE; - STDMETHOD(DrawIndexedPrimitive)(THIS_ D3DPRIMITIVETYPE,UINT minIndex,UINT NumVertices,UINT startIndex,UINT primCount) PURE; - STDMETHOD(DrawPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT PrimitiveCount,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE; - STDMETHOD(DrawIndexedPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT MinVertexIndex,UINT NumVertexIndices,UINT PrimitiveCount,CONST void* pIndexData,D3DFORMAT IndexDataFormat,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE; - STDMETHOD(ProcessVertices)(THIS_ UINT SrcStartIndex,UINT DestIndex,UINT VertexCount,IDirect3DVertexBuffer8* pDestBuffer,DWORD Flags) PURE; - STDMETHOD(CreateVertexShader)(THIS_ CONST DWORD* pDeclaration,CONST DWORD* pFunction,DWORD* pHandle,DWORD Usage) PURE; - STDMETHOD(SetVertexShader)(THIS_ DWORD Handle) PURE; - STDMETHOD(GetVertexShader)(THIS_ DWORD* pHandle) PURE; - STDMETHOD(DeleteVertexShader)(THIS_ DWORD Handle) PURE; - STDMETHOD(SetVertexShaderConstant)(THIS_ DWORD Register,CONST void* pConstantData,DWORD ConstantCount) PURE; - STDMETHOD(GetVertexShaderConstant)(THIS_ DWORD Register,void* pConstantData,DWORD ConstantCount) PURE; - STDMETHOD(GetVertexShaderDeclaration)(THIS_ DWORD Handle,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(GetVertexShaderFunction)(THIS_ DWORD Handle,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(SetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer8* pStreamData,UINT Stride) PURE; - STDMETHOD(GetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer8** ppStreamData,UINT* pStride) PURE; - STDMETHOD(SetIndices)(THIS_ IDirect3DIndexBuffer8* pIndexData,UINT BaseVertexIndex) PURE; - STDMETHOD(GetIndices)(THIS_ IDirect3DIndexBuffer8** ppIndexData,UINT* pBaseVertexIndex) PURE; - STDMETHOD(CreatePixelShader)(THIS_ CONST DWORD* pFunction,DWORD* pHandle) PURE; - STDMETHOD(SetPixelShader)(THIS_ DWORD Handle) PURE; - STDMETHOD(GetPixelShader)(THIS_ DWORD* pHandle) PURE; - STDMETHOD(DeletePixelShader)(THIS_ DWORD Handle) PURE; - STDMETHOD(SetPixelShaderConstant)(THIS_ DWORD Register,CONST void* pConstantData,DWORD ConstantCount) PURE; - STDMETHOD(GetPixelShaderConstant)(THIS_ DWORD Register,void* pConstantData,DWORD ConstantCount) PURE; - STDMETHOD(GetPixelShaderFunction)(THIS_ DWORD Handle,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(DrawRectPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DRECTPATCH_INFO* pRectPatchInfo) PURE; - STDMETHOD(DrawTriPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DTRIPATCH_INFO* pTriPatchInfo) PURE; - STDMETHOD(DeletePatch)(THIS_ UINT Handle) PURE; -}; - -typedef struct IDirect3DDevice8 *LPDIRECT3DDEVICE8, *PDIRECT3DDEVICE8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DDevice8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DDevice8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DDevice8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DDevice8_TestCooperativeLevel(p) (p)->lpVtbl->TestCooperativeLevel(p) -#define IDirect3DDevice8_GetAvailableTextureMem(p) (p)->lpVtbl->GetAvailableTextureMem(p) -#define IDirect3DDevice8_ResourceManagerDiscardBytes(p,a) (p)->lpVtbl->ResourceManagerDiscardBytes(p,a) -#define IDirect3DDevice8_GetDirect3D(p,a) (p)->lpVtbl->GetDirect3D(p,a) -#define IDirect3DDevice8_GetDeviceCaps(p,a) (p)->lpVtbl->GetDeviceCaps(p,a) -#define IDirect3DDevice8_GetDisplayMode(p,a) (p)->lpVtbl->GetDisplayMode(p,a) -#define IDirect3DDevice8_GetCreationParameters(p,a) (p)->lpVtbl->GetCreationParameters(p,a) -#define IDirect3DDevice8_SetCursorProperties(p,a,b,c) (p)->lpVtbl->SetCursorProperties(p,a,b,c) -#define IDirect3DDevice8_SetCursorPosition(p,a,b,c) (p)->lpVtbl->SetCursorPosition(p,a,b,c) -#define IDirect3DDevice8_ShowCursor(p,a) (p)->lpVtbl->ShowCursor(p,a) -#define IDirect3DDevice8_CreateAdditionalSwapChain(p,a,b) (p)->lpVtbl->CreateAdditionalSwapChain(p,a,b) -#define IDirect3DDevice8_Reset(p,a) (p)->lpVtbl->Reset(p,a) -#define IDirect3DDevice8_Present(p,a,b,c,d) (p)->lpVtbl->Present(p,a,b,c,d) -#define IDirect3DDevice8_GetBackBuffer(p,a,b,c) (p)->lpVtbl->GetBackBuffer(p,a,b,c) -#define IDirect3DDevice8_GetRasterStatus(p,a) (p)->lpVtbl->GetRasterStatus(p,a) -#define IDirect3DDevice8_SetGammaRamp(p,a,b) (p)->lpVtbl->SetGammaRamp(p,a,b) -#define IDirect3DDevice8_GetGammaRamp(p,a) (p)->lpVtbl->GetGammaRamp(p,a) -#define IDirect3DDevice8_CreateTexture(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateTexture(p,a,b,c,d,e,f,g) -#define IDirect3DDevice8_CreateVolumeTexture(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateVolumeTexture(p,a,b,c,d,e,f,g,h) -#define IDirect3DDevice8_CreateCubeTexture(p,a,b,c,d,e,f) (p)->lpVtbl->CreateCubeTexture(p,a,b,c,d,e,f) -#define IDirect3DDevice8_CreateVertexBuffer(p,a,b,c,d,e) (p)->lpVtbl->CreateVertexBuffer(p,a,b,c,d,e) -#define IDirect3DDevice8_CreateIndexBuffer(p,a,b,c,d,e) (p)->lpVtbl->CreateIndexBuffer(p,a,b,c,d,e) -#define IDirect3DDevice8_CreateRenderTarget(p,a,b,c,d,e,f) (p)->lpVtbl->CreateRenderTarget(p,a,b,c,d,e,f) -#define IDirect3DDevice8_CreateDepthStencilSurface(p,a,b,c,d,e) (p)->lpVtbl->CreateDepthStencilSurface(p,a,b,c,d,e) -#define IDirect3DDevice8_CreateImageSurface(p,a,b,c,d) (p)->lpVtbl->CreateImageSurface(p,a,b,c,d) -#define IDirect3DDevice8_CopyRects(p,a,b,c,d,e) (p)->lpVtbl->CopyRects(p,a,b,c,d,e) -#define IDirect3DDevice8_UpdateTexture(p,a,b) (p)->lpVtbl->UpdateTexture(p,a,b) -#define IDirect3DDevice8_GetFrontBuffer(p,a) (p)->lpVtbl->GetFrontBuffer(p,a) -#define IDirect3DDevice8_SetRenderTarget(p,a,b) (p)->lpVtbl->SetRenderTarget(p,a,b) -#define IDirect3DDevice8_GetRenderTarget(p,a) (p)->lpVtbl->GetRenderTarget(p,a) -#define IDirect3DDevice8_GetDepthStencilSurface(p,a) (p)->lpVtbl->GetDepthStencilSurface(p,a) -#define IDirect3DDevice8_BeginScene(p) (p)->lpVtbl->BeginScene(p) -#define IDirect3DDevice8_EndScene(p) (p)->lpVtbl->EndScene(p) -#define IDirect3DDevice8_Clear(p,a,b,c,d,e,f) (p)->lpVtbl->Clear(p,a,b,c,d,e,f) -#define IDirect3DDevice8_SetTransform(p,a,b) (p)->lpVtbl->SetTransform(p,a,b) -#define IDirect3DDevice8_GetTransform(p,a,b) (p)->lpVtbl->GetTransform(p,a,b) -#define IDirect3DDevice8_MultiplyTransform(p,a,b) (p)->lpVtbl->MultiplyTransform(p,a,b) -#define IDirect3DDevice8_SetViewport(p,a) (p)->lpVtbl->SetViewport(p,a) -#define IDirect3DDevice8_GetViewport(p,a) (p)->lpVtbl->GetViewport(p,a) -#define IDirect3DDevice8_SetMaterial(p,a) (p)->lpVtbl->SetMaterial(p,a) -#define IDirect3DDevice8_GetMaterial(p,a) (p)->lpVtbl->GetMaterial(p,a) -#define IDirect3DDevice8_SetLight(p,a,b) (p)->lpVtbl->SetLight(p,a,b) -#define IDirect3DDevice8_GetLight(p,a,b) (p)->lpVtbl->GetLight(p,a,b) -#define IDirect3DDevice8_LightEnable(p,a,b) (p)->lpVtbl->LightEnable(p,a,b) -#define IDirect3DDevice8_GetLightEnable(p,a,b) (p)->lpVtbl->GetLightEnable(p,a,b) -#define IDirect3DDevice8_SetClipPlane(p,a,b) (p)->lpVtbl->SetClipPlane(p,a,b) -#define IDirect3DDevice8_GetClipPlane(p,a,b) (p)->lpVtbl->GetClipPlane(p,a,b) -#define IDirect3DDevice8_SetRenderState(p,a,b) (p)->lpVtbl->SetRenderState(p,a,b) -#define IDirect3DDevice8_GetRenderState(p,a,b) (p)->lpVtbl->GetRenderState(p,a,b) -#define IDirect3DDevice8_BeginStateBlock(p) (p)->lpVtbl->BeginStateBlock(p) -#define IDirect3DDevice8_EndStateBlock(p,a) (p)->lpVtbl->EndStateBlock(p,a) -#define IDirect3DDevice8_ApplyStateBlock(p,a) (p)->lpVtbl->ApplyStateBlock(p,a) -#define IDirect3DDevice8_CaptureStateBlock(p,a) (p)->lpVtbl->CaptureStateBlock(p,a) -#define IDirect3DDevice8_DeleteStateBlock(p,a) (p)->lpVtbl->DeleteStateBlock(p,a) -#define IDirect3DDevice8_CreateStateBlock(p,a,b) (p)->lpVtbl->CreateStateBlock(p,a,b) -#define IDirect3DDevice8_SetClipStatus(p,a) (p)->lpVtbl->SetClipStatus(p,a) -#define IDirect3DDevice8_GetClipStatus(p,a) (p)->lpVtbl->GetClipStatus(p,a) -#define IDirect3DDevice8_GetTexture(p,a,b) (p)->lpVtbl->GetTexture(p,a,b) -#define IDirect3DDevice8_SetTexture(p,a,b) (p)->lpVtbl->SetTexture(p,a,b) -#define IDirect3DDevice8_GetTextureStageState(p,a,b,c) (p)->lpVtbl->GetTextureStageState(p,a,b,c) -#define IDirect3DDevice8_SetTextureStageState(p,a,b,c) (p)->lpVtbl->SetTextureStageState(p,a,b,c) -#define IDirect3DDevice8_ValidateDevice(p,a) (p)->lpVtbl->ValidateDevice(p,a) -#define IDirect3DDevice8_GetInfo(p,a,b,c) (p)->lpVtbl->GetInfo(p,a,b,c) -#define IDirect3DDevice8_SetPaletteEntries(p,a,b) (p)->lpVtbl->SetPaletteEntries(p,a,b) -#define IDirect3DDevice8_GetPaletteEntries(p,a,b) (p)->lpVtbl->GetPaletteEntries(p,a,b) -#define IDirect3DDevice8_SetCurrentTexturePalette(p,a) (p)->lpVtbl->SetCurrentTexturePalette(p,a) -#define IDirect3DDevice8_GetCurrentTexturePalette(p,a) (p)->lpVtbl->GetCurrentTexturePalette(p,a) -#define IDirect3DDevice8_DrawPrimitive(p,a,b,c) (p)->lpVtbl->DrawPrimitive(p,a,b,c) -#define IDirect3DDevice8_DrawIndexedPrimitive(p,a,b,c,d,e) (p)->lpVtbl->DrawIndexedPrimitive(p,a,b,c,d,e) -#define IDirect3DDevice8_DrawPrimitiveUP(p,a,b,c,d) (p)->lpVtbl->DrawPrimitiveUP(p,a,b,c,d) -#define IDirect3DDevice8_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) -#define IDirect3DDevice8_ProcessVertices(p,a,b,c,d,e) (p)->lpVtbl->ProcessVertices(p,a,b,c,d,e) -#define IDirect3DDevice8_CreateVertexShader(p,a,b,c,d) (p)->lpVtbl->CreateVertexShader(p,a,b,c,d) -#define IDirect3DDevice8_SetVertexShader(p,a) (p)->lpVtbl->SetVertexShader(p,a) -#define IDirect3DDevice8_GetVertexShader(p,a) (p)->lpVtbl->GetVertexShader(p,a) -#define IDirect3DDevice8_DeleteVertexShader(p,a) (p)->lpVtbl->DeleteVertexShader(p,a) -#define IDirect3DDevice8_SetVertexShaderConstant(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstant(p,a,b,c) -#define IDirect3DDevice8_GetVertexShaderConstant(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstant(p,a,b,c) -#define IDirect3DDevice8_GetVertexShaderDeclaration(p,a,b,c) (p)->lpVtbl->GetVertexShaderDeclaration(p,a,b,c) -#define IDirect3DDevice8_GetVertexShaderFunction(p,a,b,c) (p)->lpVtbl->GetVertexShaderFunction(p,a,b,c) -#define IDirect3DDevice8_SetStreamSource(p,a,b,c) (p)->lpVtbl->SetStreamSource(p,a,b,c) -#define IDirect3DDevice8_GetStreamSource(p,a,b,c) (p)->lpVtbl->GetStreamSource(p,a,b,c) -#define IDirect3DDevice8_SetIndices(p,a,b) (p)->lpVtbl->SetIndices(p,a,b) -#define IDirect3DDevice8_GetIndices(p,a,b) (p)->lpVtbl->GetIndices(p,a,b) -#define IDirect3DDevice8_CreatePixelShader(p,a,b) (p)->lpVtbl->CreatePixelShader(p,a,b) -#define IDirect3DDevice8_SetPixelShader(p,a) (p)->lpVtbl->SetPixelShader(p,a) -#define IDirect3DDevice8_GetPixelShader(p,a) (p)->lpVtbl->GetPixelShader(p,a) -#define IDirect3DDevice8_DeletePixelShader(p,a) (p)->lpVtbl->DeletePixelShader(p,a) -#define IDirect3DDevice8_SetPixelShaderConstant(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstant(p,a,b,c) -#define IDirect3DDevice8_GetPixelShaderConstant(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstant(p,a,b,c) -#define IDirect3DDevice8_GetPixelShaderFunction(p,a,b,c) (p)->lpVtbl->GetPixelShaderFunction(p,a,b,c) -#define IDirect3DDevice8_DrawRectPatch(p,a,b,c) (p)->lpVtbl->DrawRectPatch(p,a,b,c) -#define IDirect3DDevice8_DrawTriPatch(p,a,b,c) (p)->lpVtbl->DrawTriPatch(p,a,b,c) -#define IDirect3DDevice8_DeletePatch(p,a) (p)->lpVtbl->DeletePatch(p,a) -#else -#define IDirect3DDevice8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DDevice8_AddRef(p) (p)->AddRef() -#define IDirect3DDevice8_Release(p) (p)->Release() -#define IDirect3DDevice8_TestCooperativeLevel(p) (p)->TestCooperativeLevel() -#define IDirect3DDevice8_GetAvailableTextureMem(p) (p)->GetAvailableTextureMem() -#define IDirect3DDevice8_ResourceManagerDiscardBytes(p,a) (p)->ResourceManagerDiscardBytes(a) -#define IDirect3DDevice8_GetDirect3D(p,a) (p)->GetDirect3D(a) -#define IDirect3DDevice8_GetDeviceCaps(p,a) (p)->GetDeviceCaps(a) -#define IDirect3DDevice8_GetDisplayMode(p,a) (p)->GetDisplayMode(a) -#define IDirect3DDevice8_GetCreationParameters(p,a) (p)->GetCreationParameters(a) -#define IDirect3DDevice8_SetCursorProperties(p,a,b,c) (p)->SetCursorProperties(a,b,c) -#define IDirect3DDevice8_SetCursorPosition(p,a,b,c) (p)->SetCursorPosition(a,b,c) -#define IDirect3DDevice8_ShowCursor(p,a) (p)->ShowCursor(a) -#define IDirect3DDevice8_CreateAdditionalSwapChain(p,a,b) (p)->CreateAdditionalSwapChain(a,b) -#define IDirect3DDevice8_Reset(p,a) (p)->Reset(a) -#define IDirect3DDevice8_Present(p,a,b,c,d) (p)->Present(a,b,c,d) -#define IDirect3DDevice8_GetBackBuffer(p,a,b,c) (p)->GetBackBuffer(a,b,c) -#define IDirect3DDevice8_GetRasterStatus(p,a) (p)->GetRasterStatus(a) -#define IDirect3DDevice8_SetGammaRamp(p,a,b) (p)->SetGammaRamp(a,b) -#define IDirect3DDevice8_GetGammaRamp(p,a) (p)->GetGammaRamp(a) -#define IDirect3DDevice8_CreateTexture(p,a,b,c,d,e,f,g) (p)->CreateTexture(a,b,c,d,e,f,g) -#define IDirect3DDevice8_CreateVolumeTexture(p,a,b,c,d,e,f,g,h) (p)->CreateVolumeTexture(a,b,c,d,e,f,g,h) -#define IDirect3DDevice8_CreateCubeTexture(p,a,b,c,d,e,f) (p)->CreateCubeTexture(a,b,c,d,e,f) -#define IDirect3DDevice8_CreateVertexBuffer(p,a,b,c,d,e) (p)->CreateVertexBuffer(a,b,c,d,e) -#define IDirect3DDevice8_CreateIndexBuffer(p,a,b,c,d,e) (p)->CreateIndexBuffer(a,b,c,d,e) -#define IDirect3DDevice8_CreateRenderTarget(p,a,b,c,d,e,f) (p)->CreateRenderTarget(a,b,c,d,e,f) -#define IDirect3DDevice8_CreateDepthStencilSurface(p,a,b,c,d,e) (p)->CreateDepthStencilSurface(a,b,c,d,e) -#define IDirect3DDevice8_CreateImageSurface(p,a,b,c,d) (p)->CreateImageSurface(a,b,c,d) -#define IDirect3DDevice8_CopyRects(p,a,b,c,d,e) (p)->CopyRects(a,b,c,d,e) -#define IDirect3DDevice8_UpdateTexture(p,a,b) (p)->UpdateTexture(a,b) -#define IDirect3DDevice8_GetFrontBuffer(p,a) (p)->GetFrontBuffer(a) -#define IDirect3DDevice8_SetRenderTarget(p,a,b) (p)->SetRenderTarget(a,b) -#define IDirect3DDevice8_GetRenderTarget(p,a) (p)->GetRenderTarget(a) -#define IDirect3DDevice8_GetDepthStencilSurface(p,a) (p)->GetDepthStencilSurface(a) -#define IDirect3DDevice8_BeginScene(p) (p)->BeginScene() -#define IDirect3DDevice8_EndScene(p) (p)->EndScene() -#define IDirect3DDevice8_Clear(p,a,b,c,d,e,f) (p)->Clear(a,b,c,d,e,f) -#define IDirect3DDevice8_SetTransform(p,a,b) (p)->SetTransform(a,b) -#define IDirect3DDevice8_GetTransform(p,a,b) (p)->GetTransform(a,b) -#define IDirect3DDevice8_MultiplyTransform(p,a,b) (p)->MultiplyTransform(a,b) -#define IDirect3DDevice8_SetViewport(p,a) (p)->SetViewport(a) -#define IDirect3DDevice8_GetViewport(p,a) (p)->GetViewport(a) -#define IDirect3DDevice8_SetMaterial(p,a) (p)->SetMaterial(a) -#define IDirect3DDevice8_GetMaterial(p,a) (p)->GetMaterial(a) -#define IDirect3DDevice8_SetLight(p,a,b) (p)->SetLight(a,b) -#define IDirect3DDevice8_GetLight(p,a,b) (p)->GetLight(a,b) -#define IDirect3DDevice8_LightEnable(p,a,b) (p)->LightEnable(a,b) -#define IDirect3DDevice8_GetLightEnable(p,a,b) (p)->GetLightEnable(a,b) -#define IDirect3DDevice8_SetClipPlane(p,a,b) (p)->SetClipPlane(a,b) -#define IDirect3DDevice8_GetClipPlane(p,a,b) (p)->GetClipPlane(a,b) -#define IDirect3DDevice8_SetRenderState(p,a,b) (p)->SetRenderState(a,b) -#define IDirect3DDevice8_GetRenderState(p,a,b) (p)->GetRenderState(a,b) -#define IDirect3DDevice8_BeginStateBlock(p) (p)->BeginStateBlock() -#define IDirect3DDevice8_EndStateBlock(p,a) (p)->EndStateBlock(a) -#define IDirect3DDevice8_ApplyStateBlock(p,a) (p)->ApplyStateBlock(a) -#define IDirect3DDevice8_CaptureStateBlock(p,a) (p)->CaptureStateBlock(a) -#define IDirect3DDevice8_DeleteStateBlock(p,a) (p)->DeleteStateBlock(a) -#define IDirect3DDevice8_CreateStateBlock(p,a,b) (p)->CreateStateBlock(a,b) -#define IDirect3DDevice8_SetClipStatus(p,a) (p)->SetClipStatus(a) -#define IDirect3DDevice8_GetClipStatus(p,a) (p)->GetClipStatus(a) -#define IDirect3DDevice8_GetTexture(p,a,b) (p)->GetTexture(a,b) -#define IDirect3DDevice8_SetTexture(p,a,b) (p)->SetTexture(a,b) -#define IDirect3DDevice8_GetTextureStageState(p,a,b,c) (p)->GetTextureStageState(a,b,c) -#define IDirect3DDevice8_SetTextureStageState(p,a,b,c) (p)->SetTextureStageState(a,b,c) -#define IDirect3DDevice8_ValidateDevice(p,a) (p)->ValidateDevice(a) -#define IDirect3DDevice8_GetInfo(p,a,b,c) (p)->GetInfo(a,b,c) -#define IDirect3DDevice8_SetPaletteEntries(p,a,b) (p)->SetPaletteEntries(a,b) -#define IDirect3DDevice8_GetPaletteEntries(p,a,b) (p)->GetPaletteEntries(a,b) -#define IDirect3DDevice8_SetCurrentTexturePalette(p,a) (p)->SetCurrentTexturePalette(a) -#define IDirect3DDevice8_GetCurrentTexturePalette(p,a) (p)->GetCurrentTexturePalette(a) -#define IDirect3DDevice8_DrawPrimitive(p,a,b,c) (p)->DrawPrimitive(a,b,c) -#define IDirect3DDevice8_DrawIndexedPrimitive(p,a,b,c,d,e) (p)->DrawIndexedPrimitive(a,b,c,d,e) -#define IDirect3DDevice8_DrawPrimitiveUP(p,a,b,c,d) (p)->DrawPrimitiveUP(a,b,c,d) -#define IDirect3DDevice8_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->DrawIndexedPrimitiveUP(a,b,c,d,e,f,g,h) -#define IDirect3DDevice8_ProcessVertices(p,a,b,c,d,e) (p)->ProcessVertices(a,b,c,d,e) -#define IDirect3DDevice8_CreateVertexShader(p,a,b,c,d) (p)->CreateVertexShader(a,b,c,d) -#define IDirect3DDevice8_SetVertexShader(p,a) (p)->SetVertexShader(a) -#define IDirect3DDevice8_GetVertexShader(p,a) (p)->GetVertexShader(a) -#define IDirect3DDevice8_DeleteVertexShader(p,a) (p)->DeleteVertexShader(a) -#define IDirect3DDevice8_SetVertexShaderConstant(p,a,b,c) (p)->SetVertexShaderConstant(a,b,c) -#define IDirect3DDevice8_GetVertexShaderConstant(p,a,b,c) (p)->GetVertexShaderConstant(a,b,c) -#define IDirect3DDevice8_GetVertexShaderDeclaration(p,a,b,c) (p)->GetVertexShaderDeclaration(a,b,c) -#define IDirect3DDevice8_GetVertexShaderFunction(p,a,b,c) (p)->GetVertexShaderFunction(a,b,c) -#define IDirect3DDevice8_SetStreamSource(p,a,b,c) (p)->SetStreamSource(a,b,c) -#define IDirect3DDevice8_GetStreamSource(p,a,b,c) (p)->GetStreamSource(a,b,c) -#define IDirect3DDevice8_SetIndices(p,a,b) (p)->SetIndices(a,b) -#define IDirect3DDevice8_GetIndices(p,a,b) (p)->GetIndices(a,b) -#define IDirect3DDevice8_CreatePixelShader(p,a,b) (p)->CreatePixelShader(a,b) -#define IDirect3DDevice8_SetPixelShader(p,a) (p)->SetPixelShader(a) -#define IDirect3DDevice8_GetPixelShader(p,a) (p)->GetPixelShader(a) -#define IDirect3DDevice8_DeletePixelShader(p,a) (p)->DeletePixelShader(a) -#define IDirect3DDevice8_SetPixelShaderConstant(p,a,b,c) (p)->SetPixelShaderConstant(a,b,c) -#define IDirect3DDevice8_GetPixelShaderConstant(p,a,b,c) (p)->GetPixelShaderConstant(a,b,c) -#define IDirect3DDevice8_GetPixelShaderFunction(p,a,b,c) (p)->GetPixelShaderFunction(a,b,c) -#define IDirect3DDevice8_DrawRectPatch(p,a,b,c) (p)->DrawRectPatch(a,b,c) -#define IDirect3DDevice8_DrawTriPatch(p,a,b,c) (p)->DrawTriPatch(a,b,c) -#define IDirect3DDevice8_DeletePatch(p,a) (p)->DeletePatch(a) -#endif - - - -#undef INTERFACE -#define INTERFACE IDirect3DSwapChain8 - -DECLARE_INTERFACE_(IDirect3DSwapChain8, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DSwapChain8 methods ***/ - STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion) PURE; - STDMETHOD(GetBackBuffer)(THIS_ UINT BackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface8** ppBackBuffer) PURE; -}; - -typedef struct IDirect3DSwapChain8 *LPDIRECT3DSWAPCHAIN8, *PDIRECT3DSWAPCHAIN8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DSwapChain8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DSwapChain8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DSwapChain8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DSwapChain8_Present(p,a,b,c,d) (p)->lpVtbl->Present(p,a,b,c,d) -#define IDirect3DSwapChain8_GetBackBuffer(p,a,b,c) (p)->lpVtbl->GetBackBuffer(p,a,b,c) -#else -#define IDirect3DSwapChain8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DSwapChain8_AddRef(p) (p)->AddRef() -#define IDirect3DSwapChain8_Release(p) (p)->Release() -#define IDirect3DSwapChain8_Present(p,a,b,c,d) (p)->Present(a,b,c,d) -#define IDirect3DSwapChain8_GetBackBuffer(p,a,b,c) (p)->GetBackBuffer(a,b,c) -#endif - - - -#undef INTERFACE -#define INTERFACE IDirect3DResource8 - -DECLARE_INTERFACE_(IDirect3DResource8, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DResource8 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; -}; - -typedef struct IDirect3DResource8 *LPDIRECT3DRESOURCE8, *PDIRECT3DRESOURCE8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DResource8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DResource8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DResource8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DResource8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DResource8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DResource8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DResource8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DResource8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DResource8_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DResource8_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DResource8_GetType(p) (p)->lpVtbl->GetType(p) -#else -#define IDirect3DResource8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DResource8_AddRef(p) (p)->AddRef() -#define IDirect3DResource8_Release(p) (p)->Release() -#define IDirect3DResource8_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DResource8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DResource8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DResource8_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DResource8_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DResource8_GetPriority(p) (p)->GetPriority() -#define IDirect3DResource8_PreLoad(p) (p)->PreLoad() -#define IDirect3DResource8_GetType(p) (p)->GetType() -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DBaseTexture8 - -DECLARE_INTERFACE_(IDirect3DBaseTexture8, IDirect3DResource8) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DResource8 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE; - STDMETHOD_(DWORD, GetLOD)(THIS) PURE; - STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE; -}; - -typedef struct IDirect3DBaseTexture8 *LPDIRECT3DBASETEXTURE8, *PDIRECT3DBASETEXTURE8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DBaseTexture8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DBaseTexture8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DBaseTexture8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DBaseTexture8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DBaseTexture8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DBaseTexture8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DBaseTexture8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DBaseTexture8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DBaseTexture8_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DBaseTexture8_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DBaseTexture8_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DBaseTexture8_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) -#define IDirect3DBaseTexture8_GetLOD(p) (p)->lpVtbl->GetLOD(p) -#define IDirect3DBaseTexture8_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p) -#else -#define IDirect3DBaseTexture8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DBaseTexture8_AddRef(p) (p)->AddRef() -#define IDirect3DBaseTexture8_Release(p) (p)->Release() -#define IDirect3DBaseTexture8_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DBaseTexture8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DBaseTexture8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DBaseTexture8_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DBaseTexture8_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DBaseTexture8_GetPriority(p) (p)->GetPriority() -#define IDirect3DBaseTexture8_PreLoad(p) (p)->PreLoad() -#define IDirect3DBaseTexture8_GetType(p) (p)->GetType() -#define IDirect3DBaseTexture8_SetLOD(p,a) (p)->SetLOD(a) -#define IDirect3DBaseTexture8_GetLOD(p) (p)->GetLOD() -#define IDirect3DBaseTexture8_GetLevelCount(p) (p)->GetLevelCount() -#endif - - - - - -#undef INTERFACE -#define INTERFACE IDirect3DTexture8 - -DECLARE_INTERFACE_(IDirect3DTexture8, IDirect3DBaseTexture8) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DBaseTexture8 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE; - STDMETHOD_(DWORD, GetLOD)(THIS) PURE; - STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE; - STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DSURFACE_DESC *pDesc) PURE; - STDMETHOD(GetSurfaceLevel)(THIS_ UINT Level,IDirect3DSurface8** ppSurfaceLevel) PURE; - STDMETHOD(LockRect)(THIS_ UINT Level,D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE; - STDMETHOD(UnlockRect)(THIS_ UINT Level) PURE; - STDMETHOD(AddDirtyRect)(THIS_ CONST RECT* pDirtyRect) PURE; -}; - -typedef struct IDirect3DTexture8 *LPDIRECT3DTEXTURE8, *PDIRECT3DTEXTURE8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DTexture8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DTexture8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DTexture8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DTexture8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DTexture8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DTexture8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DTexture8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DTexture8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DTexture8_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DTexture8_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DTexture8_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DTexture8_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) -#define IDirect3DTexture8_GetLOD(p) (p)->lpVtbl->GetLOD(p) -#define IDirect3DTexture8_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p) -#define IDirect3DTexture8_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b) -#define IDirect3DTexture8_GetSurfaceLevel(p,a,b) (p)->lpVtbl->GetSurfaceLevel(p,a,b) -#define IDirect3DTexture8_LockRect(p,a,b,c,d) (p)->lpVtbl->LockRect(p,a,b,c,d) -#define IDirect3DTexture8_UnlockRect(p,a) (p)->lpVtbl->UnlockRect(p,a) -#define IDirect3DTexture8_AddDirtyRect(p,a) (p)->lpVtbl->AddDirtyRect(p,a) -#else -#define IDirect3DTexture8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DTexture8_AddRef(p) (p)->AddRef() -#define IDirect3DTexture8_Release(p) (p)->Release() -#define IDirect3DTexture8_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DTexture8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DTexture8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DTexture8_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DTexture8_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DTexture8_GetPriority(p) (p)->GetPriority() -#define IDirect3DTexture8_PreLoad(p) (p)->PreLoad() -#define IDirect3DTexture8_GetType(p) (p)->GetType() -#define IDirect3DTexture8_SetLOD(p,a) (p)->SetLOD(a) -#define IDirect3DTexture8_GetLOD(p) (p)->GetLOD() -#define IDirect3DTexture8_GetLevelCount(p) (p)->GetLevelCount() -#define IDirect3DTexture8_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b) -#define IDirect3DTexture8_GetSurfaceLevel(p,a,b) (p)->GetSurfaceLevel(a,b) -#define IDirect3DTexture8_LockRect(p,a,b,c,d) (p)->LockRect(a,b,c,d) -#define IDirect3DTexture8_UnlockRect(p,a) (p)->UnlockRect(a) -#define IDirect3DTexture8_AddDirtyRect(p,a) (p)->AddDirtyRect(a) -#endif - - - - - -#undef INTERFACE -#define INTERFACE IDirect3DVolumeTexture8 - -DECLARE_INTERFACE_(IDirect3DVolumeTexture8, IDirect3DBaseTexture8) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DBaseTexture8 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE; - STDMETHOD_(DWORD, GetLOD)(THIS) PURE; - STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE; - STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DVOLUME_DESC *pDesc) PURE; - STDMETHOD(GetVolumeLevel)(THIS_ UINT Level,IDirect3DVolume8** ppVolumeLevel) PURE; - STDMETHOD(LockBox)(THIS_ UINT Level,D3DLOCKED_BOX* pLockedVolume,CONST D3DBOX* pBox,DWORD Flags) PURE; - STDMETHOD(UnlockBox)(THIS_ UINT Level) PURE; - STDMETHOD(AddDirtyBox)(THIS_ CONST D3DBOX* pDirtyBox) PURE; -}; - -typedef struct IDirect3DVolumeTexture8 *LPDIRECT3DVOLUMETEXTURE8, *PDIRECT3DVOLUMETEXTURE8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DVolumeTexture8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DVolumeTexture8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DVolumeTexture8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DVolumeTexture8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DVolumeTexture8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DVolumeTexture8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DVolumeTexture8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DVolumeTexture8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DVolumeTexture8_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DVolumeTexture8_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DVolumeTexture8_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DVolumeTexture8_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) -#define IDirect3DVolumeTexture8_GetLOD(p) (p)->lpVtbl->GetLOD(p) -#define IDirect3DVolumeTexture8_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p) -#define IDirect3DVolumeTexture8_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b) -#define IDirect3DVolumeTexture8_GetVolumeLevel(p,a,b) (p)->lpVtbl->GetVolumeLevel(p,a,b) -#define IDirect3DVolumeTexture8_LockBox(p,a,b,c,d) (p)->lpVtbl->LockBox(p,a,b,c,d) -#define IDirect3DVolumeTexture8_UnlockBox(p,a) (p)->lpVtbl->UnlockBox(p,a) -#define IDirect3DVolumeTexture8_AddDirtyBox(p,a) (p)->lpVtbl->AddDirtyBox(p,a) -#else -#define IDirect3DVolumeTexture8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DVolumeTexture8_AddRef(p) (p)->AddRef() -#define IDirect3DVolumeTexture8_Release(p) (p)->Release() -#define IDirect3DVolumeTexture8_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DVolumeTexture8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DVolumeTexture8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DVolumeTexture8_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DVolumeTexture8_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DVolumeTexture8_GetPriority(p) (p)->GetPriority() -#define IDirect3DVolumeTexture8_PreLoad(p) (p)->PreLoad() -#define IDirect3DVolumeTexture8_GetType(p) (p)->GetType() -#define IDirect3DVolumeTexture8_SetLOD(p,a) (p)->SetLOD(a) -#define IDirect3DVolumeTexture8_GetLOD(p) (p)->GetLOD() -#define IDirect3DVolumeTexture8_GetLevelCount(p) (p)->GetLevelCount() -#define IDirect3DVolumeTexture8_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b) -#define IDirect3DVolumeTexture8_GetVolumeLevel(p,a,b) (p)->GetVolumeLevel(a,b) -#define IDirect3DVolumeTexture8_LockBox(p,a,b,c,d) (p)->LockBox(a,b,c,d) -#define IDirect3DVolumeTexture8_UnlockBox(p,a) (p)->UnlockBox(a) -#define IDirect3DVolumeTexture8_AddDirtyBox(p,a) (p)->AddDirtyBox(a) -#endif - - - - - -#undef INTERFACE -#define INTERFACE IDirect3DCubeTexture8 - -DECLARE_INTERFACE_(IDirect3DCubeTexture8, IDirect3DBaseTexture8) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DBaseTexture8 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE; - STDMETHOD_(DWORD, GetLOD)(THIS) PURE; - STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE; - STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DSURFACE_DESC *pDesc) PURE; - STDMETHOD(GetCubeMapSurface)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level,IDirect3DSurface8** ppCubeMapSurface) PURE; - STDMETHOD(LockRect)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level,D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE; - STDMETHOD(UnlockRect)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level) PURE; - STDMETHOD(AddDirtyRect)(THIS_ D3DCUBEMAP_FACES FaceType,CONST RECT* pDirtyRect) PURE; -}; - -typedef struct IDirect3DCubeTexture8 *LPDIRECT3DCUBETEXTURE8, *PDIRECT3DCUBETEXTURE8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DCubeTexture8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DCubeTexture8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DCubeTexture8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DCubeTexture8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DCubeTexture8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DCubeTexture8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DCubeTexture8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DCubeTexture8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DCubeTexture8_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DCubeTexture8_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DCubeTexture8_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DCubeTexture8_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) -#define IDirect3DCubeTexture8_GetLOD(p) (p)->lpVtbl->GetLOD(p) -#define IDirect3DCubeTexture8_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p) -#define IDirect3DCubeTexture8_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b) -#define IDirect3DCubeTexture8_GetCubeMapSurface(p,a,b,c) (p)->lpVtbl->GetCubeMapSurface(p,a,b,c) -#define IDirect3DCubeTexture8_LockRect(p,a,b,c,d,e) (p)->lpVtbl->LockRect(p,a,b,c,d,e) -#define IDirect3DCubeTexture8_UnlockRect(p,a,b) (p)->lpVtbl->UnlockRect(p,a,b) -#define IDirect3DCubeTexture8_AddDirtyRect(p,a,b) (p)->lpVtbl->AddDirtyRect(p,a,b) -#else -#define IDirect3DCubeTexture8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DCubeTexture8_AddRef(p) (p)->AddRef() -#define IDirect3DCubeTexture8_Release(p) (p)->Release() -#define IDirect3DCubeTexture8_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DCubeTexture8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DCubeTexture8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DCubeTexture8_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DCubeTexture8_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DCubeTexture8_GetPriority(p) (p)->GetPriority() -#define IDirect3DCubeTexture8_PreLoad(p) (p)->PreLoad() -#define IDirect3DCubeTexture8_GetType(p) (p)->GetType() -#define IDirect3DCubeTexture8_SetLOD(p,a) (p)->SetLOD(a) -#define IDirect3DCubeTexture8_GetLOD(p) (p)->GetLOD() -#define IDirect3DCubeTexture8_GetLevelCount(p) (p)->GetLevelCount() -#define IDirect3DCubeTexture8_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b) -#define IDirect3DCubeTexture8_GetCubeMapSurface(p,a,b,c) (p)->GetCubeMapSurface(a,b,c) -#define IDirect3DCubeTexture8_LockRect(p,a,b,c,d,e) (p)->LockRect(a,b,c,d,e) -#define IDirect3DCubeTexture8_UnlockRect(p,a,b) (p)->UnlockRect(a,b) -#define IDirect3DCubeTexture8_AddDirtyRect(p,a,b) (p)->AddDirtyRect(a,b) -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DVertexBuffer8 - -DECLARE_INTERFACE_(IDirect3DVertexBuffer8, IDirect3DResource8) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DResource8 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD(Lock)(THIS_ UINT OffsetToLock,UINT SizeToLock,BYTE** ppbData,DWORD Flags) PURE; - STDMETHOD(Unlock)(THIS) PURE; - STDMETHOD(GetDesc)(THIS_ D3DVERTEXBUFFER_DESC *pDesc) PURE; -}; - -typedef struct IDirect3DVertexBuffer8 *LPDIRECT3DVERTEXBUFFER8, *PDIRECT3DVERTEXBUFFER8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DVertexBuffer8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DVertexBuffer8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DVertexBuffer8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DVertexBuffer8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DVertexBuffer8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DVertexBuffer8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DVertexBuffer8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DVertexBuffer8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DVertexBuffer8_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DVertexBuffer8_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DVertexBuffer8_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DVertexBuffer8_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) -#define IDirect3DVertexBuffer8_Unlock(p) (p)->lpVtbl->Unlock(p) -#define IDirect3DVertexBuffer8_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a) -#else -#define IDirect3DVertexBuffer8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DVertexBuffer8_AddRef(p) (p)->AddRef() -#define IDirect3DVertexBuffer8_Release(p) (p)->Release() -#define IDirect3DVertexBuffer8_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DVertexBuffer8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DVertexBuffer8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DVertexBuffer8_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DVertexBuffer8_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DVertexBuffer8_GetPriority(p) (p)->GetPriority() -#define IDirect3DVertexBuffer8_PreLoad(p) (p)->PreLoad() -#define IDirect3DVertexBuffer8_GetType(p) (p)->GetType() -#define IDirect3DVertexBuffer8_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) -#define IDirect3DVertexBuffer8_Unlock(p) (p)->Unlock() -#define IDirect3DVertexBuffer8_GetDesc(p,a) (p)->GetDesc(a) -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DIndexBuffer8 - -DECLARE_INTERFACE_(IDirect3DIndexBuffer8, IDirect3DResource8) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DResource8 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD(Lock)(THIS_ UINT OffsetToLock,UINT SizeToLock,BYTE** ppbData,DWORD Flags) PURE; - STDMETHOD(Unlock)(THIS) PURE; - STDMETHOD(GetDesc)(THIS_ D3DINDEXBUFFER_DESC *pDesc) PURE; -}; - -typedef struct IDirect3DIndexBuffer8 *LPDIRECT3DINDEXBUFFER8, *PDIRECT3DINDEXBUFFER8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DIndexBuffer8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DIndexBuffer8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DIndexBuffer8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DIndexBuffer8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DIndexBuffer8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DIndexBuffer8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DIndexBuffer8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DIndexBuffer8_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DIndexBuffer8_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DIndexBuffer8_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DIndexBuffer8_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DIndexBuffer8_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) -#define IDirect3DIndexBuffer8_Unlock(p) (p)->lpVtbl->Unlock(p) -#define IDirect3DIndexBuffer8_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a) -#else -#define IDirect3DIndexBuffer8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DIndexBuffer8_AddRef(p) (p)->AddRef() -#define IDirect3DIndexBuffer8_Release(p) (p)->Release() -#define IDirect3DIndexBuffer8_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DIndexBuffer8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DIndexBuffer8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DIndexBuffer8_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DIndexBuffer8_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DIndexBuffer8_GetPriority(p) (p)->GetPriority() -#define IDirect3DIndexBuffer8_PreLoad(p) (p)->PreLoad() -#define IDirect3DIndexBuffer8_GetType(p) (p)->GetType() -#define IDirect3DIndexBuffer8_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) -#define IDirect3DIndexBuffer8_Unlock(p) (p)->Unlock() -#define IDirect3DIndexBuffer8_GetDesc(p,a) (p)->GetDesc(a) -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DSurface8 - -DECLARE_INTERFACE_(IDirect3DSurface8, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DSurface8 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD(GetContainer)(THIS_ REFIID riid,void** ppContainer) PURE; - STDMETHOD(GetDesc)(THIS_ D3DSURFACE_DESC *pDesc) PURE; - STDMETHOD(LockRect)(THIS_ D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE; - STDMETHOD(UnlockRect)(THIS) PURE; -}; - -typedef struct IDirect3DSurface8 *LPDIRECT3DSURFACE8, *PDIRECT3DSURFACE8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DSurface8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DSurface8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DSurface8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DSurface8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DSurface8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DSurface8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DSurface8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DSurface8_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b) -#define IDirect3DSurface8_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a) -#define IDirect3DSurface8_LockRect(p,a,b,c) (p)->lpVtbl->LockRect(p,a,b,c) -#define IDirect3DSurface8_UnlockRect(p) (p)->lpVtbl->UnlockRect(p) -#else -#define IDirect3DSurface8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DSurface8_AddRef(p) (p)->AddRef() -#define IDirect3DSurface8_Release(p) (p)->Release() -#define IDirect3DSurface8_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DSurface8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DSurface8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DSurface8_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DSurface8_GetContainer(p,a,b) (p)->GetContainer(a,b) -#define IDirect3DSurface8_GetDesc(p,a) (p)->GetDesc(a) -#define IDirect3DSurface8_LockRect(p,a,b,c) (p)->LockRect(a,b,c) -#define IDirect3DSurface8_UnlockRect(p) (p)->UnlockRect() -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DVolume8 - -DECLARE_INTERFACE_(IDirect3DVolume8, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DVolume8 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice8** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD(GetContainer)(THIS_ REFIID riid,void** ppContainer) PURE; - STDMETHOD(GetDesc)(THIS_ D3DVOLUME_DESC *pDesc) PURE; - STDMETHOD(LockBox)(THIS_ D3DLOCKED_BOX * pLockedVolume,CONST D3DBOX* pBox,DWORD Flags) PURE; - STDMETHOD(UnlockBox)(THIS) PURE; -}; - -typedef struct IDirect3DVolume8 *LPDIRECT3DVOLUME8, *PDIRECT3DVOLUME8; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DVolume8_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DVolume8_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DVolume8_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DVolume8_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DVolume8_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DVolume8_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DVolume8_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DVolume8_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b) -#define IDirect3DVolume8_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a) -#define IDirect3DVolume8_LockBox(p,a,b,c) (p)->lpVtbl->LockBox(p,a,b,c) -#define IDirect3DVolume8_UnlockBox(p) (p)->lpVtbl->UnlockBox(p) -#else -#define IDirect3DVolume8_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DVolume8_AddRef(p) (p)->AddRef() -#define IDirect3DVolume8_Release(p) (p)->Release() -#define IDirect3DVolume8_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DVolume8_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DVolume8_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DVolume8_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DVolume8_GetContainer(p,a,b) (p)->GetContainer(a,b) -#define IDirect3DVolume8_GetDesc(p,a) (p)->GetDesc(a) -#define IDirect3DVolume8_LockBox(p,a,b,c) (p)->LockBox(a,b,c) -#define IDirect3DVolume8_UnlockBox(p) (p)->UnlockBox() -#endif - -/**************************************************************************** - * Flags for SetPrivateData method on all D3D8 interfaces - * - * The passed pointer is an IUnknown ptr. The SizeOfData argument to SetPrivateData - * must be set to sizeof(IUnknown*). Direct3D will call AddRef through this - * pointer and Release when the private data is destroyed. The data will be - * destroyed when another SetPrivateData with the same GUID is set, when - * FreePrivateData is called, or when the D3D8 object is freed. - ****************************************************************************/ -#define D3DSPD_IUNKNOWN 0x00000001L - -/**************************************************************************** - * - * Parameter for IDirect3D8 Enum and GetCaps8 functions to get the info for - * the current mode only. - * - ****************************************************************************/ - -#define D3DCURRENT_DISPLAY_MODE 0x00EFFFFFL - -/**************************************************************************** - * - * Flags for IDirect3D8::CreateDevice's BehaviorFlags - * - ****************************************************************************/ - -#define D3DCREATE_FPU_PRESERVE 0x00000002L -#define D3DCREATE_MULTITHREADED 0x00000004L - -#define D3DCREATE_PUREDEVICE 0x00000010L -#define D3DCREATE_SOFTWARE_VERTEXPROCESSING 0x00000020L -#define D3DCREATE_HARDWARE_VERTEXPROCESSING 0x00000040L -#define D3DCREATE_MIXED_VERTEXPROCESSING 0x00000080L - -#define D3DCREATE_DISABLE_DRIVER_MANAGEMENT 0x00000100L - - -/**************************************************************************** - * - * Parameter for IDirect3D8::CreateDevice's iAdapter - * - ****************************************************************************/ - -#define D3DADAPTER_DEFAULT 0 - -/**************************************************************************** - * - * Flags for IDirect3D8::EnumAdapters - * - ****************************************************************************/ - -#define D3DENUM_NO_WHQL_LEVEL 0x00000002L - -/**************************************************************************** - * - * Maximum number of back-buffers supported in DX8 - * - ****************************************************************************/ - -#define D3DPRESENT_BACK_BUFFERS_MAX 3L - -/**************************************************************************** - * - * Flags for IDirect3DDevice8::SetGammaRamp - * - ****************************************************************************/ - -#define D3DSGR_NO_CALIBRATION 0x00000000L -#define D3DSGR_CALIBRATE 0x00000001L - -/**************************************************************************** - * - * Flags for IDirect3DDevice8::SetCursorPosition - * - ****************************************************************************/ - -#define D3DCURSOR_IMMEDIATE_UPDATE 0x00000001L - -/**************************************************************************** - * - * Flags for DrawPrimitive/DrawIndexedPrimitive - * Also valid for Begin/BeginIndexed - * Also valid for VertexBuffer::CreateVertexBuffer - ****************************************************************************/ - - -/* - * DirectDraw error codes - */ -#define _FACD3D 0x876 -#define MAKE_D3DHRESULT( code ) MAKE_HRESULT( 1, _FACD3D, code ) - -/* - * Direct3D Errors - */ -#define D3D_OK S_OK - -#define D3DERR_WRONGTEXTUREFORMAT MAKE_D3DHRESULT(2072) -#define D3DERR_UNSUPPORTEDCOLOROPERATION MAKE_D3DHRESULT(2073) -#define D3DERR_UNSUPPORTEDCOLORARG MAKE_D3DHRESULT(2074) -#define D3DERR_UNSUPPORTEDALPHAOPERATION MAKE_D3DHRESULT(2075) -#define D3DERR_UNSUPPORTEDALPHAARG MAKE_D3DHRESULT(2076) -#define D3DERR_TOOMANYOPERATIONS MAKE_D3DHRESULT(2077) -#define D3DERR_CONFLICTINGTEXTUREFILTER MAKE_D3DHRESULT(2078) -#define D3DERR_UNSUPPORTEDFACTORVALUE MAKE_D3DHRESULT(2079) -#define D3DERR_CONFLICTINGRENDERSTATE MAKE_D3DHRESULT(2081) -#define D3DERR_UNSUPPORTEDTEXTUREFILTER MAKE_D3DHRESULT(2082) -#define D3DERR_CONFLICTINGTEXTUREPALETTE MAKE_D3DHRESULT(2086) -#define D3DERR_DRIVERINTERNALERROR MAKE_D3DHRESULT(2087) - -#define D3DERR_NOTFOUND MAKE_D3DHRESULT(2150) -#define D3DERR_MOREDATA MAKE_D3DHRESULT(2151) -#define D3DERR_DEVICELOST MAKE_D3DHRESULT(2152) -#define D3DERR_DEVICENOTRESET MAKE_D3DHRESULT(2153) -#define D3DERR_NOTAVAILABLE MAKE_D3DHRESULT(2154) -#define D3DERR_OUTOFVIDEOMEMORY MAKE_D3DHRESULT(380) -#define D3DERR_INVALIDDEVICE MAKE_D3DHRESULT(2155) -#define D3DERR_INVALIDCALL MAKE_D3DHRESULT(2156) -#define D3DERR_DRIVERINVALIDCALL MAKE_D3DHRESULT(2157) - -#ifdef __cplusplus -}; -#endif - -#endif /* (DIRECT3D_VERSION >= 0x0800) */ -#endif /* _D3D_H_ */ - diff --git a/Include/d3d9.h b/Include/d3d9.h index 85bd957..e5c7847 100644 --- a/Include/d3d9.h +++ b/Include/d3d9.h @@ -126,6 +126,40 @@ DEFINE_GUID(IID_IDirect3DQuery9, 0xd9771460, 0xa695, 0x4f26, 0xbb, 0xd3, 0x27, 0 /* {E4A36723-FDFE-4b22-B146-3C04C07F4CC8} */ DEFINE_GUID(IID_HelperName, 0xe4a36723, 0xfdfe, 0x4b22, 0xb1, 0x46, 0x3c, 0x4, 0xc0, 0x7f, 0x4c, 0xc8); +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +/* IID_IDirect3D9Ex */ +/* {02177241-69FC-400C-8FF1-93A44DF6861D} */ +DEFINE_GUID(IID_IDirect3D9Ex, 0x02177241, 0x69FC, 0x400C, 0x8F, 0xF1, 0x93, 0xA4, 0x4D, 0xF6, 0x86, 0x1D); + +/* IID_IDirect3DDevice9Ex */ +// {B18B10CE-2649-405a-870F-95F777D4313A} +DEFINE_GUID(IID_IDirect3DDevice9Ex, 0xb18b10ce, 0x2649, 0x405a, 0x87, 0xf, 0x95, 0xf7, 0x77, 0xd4, 0x31, 0x3a); + +/* IID_IDirect3DSwapChain9Ex */ +/* {91886CAF-1C3D-4d2e-A0AB-3E4C7D8D3303} */ +DEFINE_GUID(IID_IDirect3DSwapChain9Ex, 0x91886caf, 0x1c3d, 0x4d2e, 0xa0, 0xab, 0x3e, 0x4c, 0x7d, 0x8d, 0x33, 0x3); + +/* IID_IDirect3D9ExOverlayExtension */ +/* {187aeb13-aaf5-4c59-876d-e059088c0df8} */ +DEFINE_GUID(IID_IDirect3D9ExOverlayExtension, 0x187aeb13, 0xaaf5, 0x4c59, 0x87, 0x6d, 0xe0, 0x59, 0x8, 0x8c, 0xd, 0xf8); + +/* IID_IDirect3DDevice9Video */ +// {26DC4561-A1EE-4ae7-96DA-118A36C0EC95} +DEFINE_GUID(IID_IDirect3DDevice9Video, 0x26dc4561, 0xa1ee, 0x4ae7, 0x96, 0xda, 0x11, 0x8a, 0x36, 0xc0, 0xec, 0x95); + +/* IID_IDirect3D9AuthenticatedChannel */ +// {FF24BEEE-DA21-4beb-98B5-D2F899F98AF9} +DEFINE_GUID(IID_IDirect3DAuthenticatedChannel9, 0xff24beee, 0xda21, 0x4beb, 0x98, 0xb5, 0xd2, 0xf8, 0x99, 0xf9, 0x8a, 0xf9); + +/* IID_IDirect3DCryptoSession9 */ +// {FA0AB799-7A9C-48ca-8C5B-237E71A54434} +DEFINE_GUID(IID_IDirect3DCryptoSession9, 0xfa0ab799, 0x7a9c, 0x48ca, 0x8c, 0x5b, 0x23, 0x7e, 0x71, 0xa5, 0x44, 0x34); + + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ #endif @@ -162,6 +196,20 @@ interface DECLSPEC_UUID("794950F2-ADFC-458a-905E-10A10B0B503B") IDirect3DSwapCha interface DECLSPEC_UUID("d9771460-a695-4f26-bbd3-27b840b541cc") IDirect3DQuery9; +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +interface DECLSPEC_UUID("02177241-69FC-400C-8FF1-93A44DF6861D") IDirect3D9Ex; +interface DECLSPEC_UUID("B18B10CE-2649-405a-870F-95F777D4313A") IDirect3DDevice9Ex; +interface DECLSPEC_UUID("91886CAF-1C3D-4d2e-A0AB-3E4C7D8D3303") IDirect3DSwapChain9Ex; +interface DECLSPEC_UUID("187AEB13-AAF5-4C59-876D-E059088C0DF8") IDirect3D9ExOverlayExtension; +interface DECLSPEC_UUID("26DC4561-A1EE-4ae7-96DA-118A36C0EC95") IDirect3DDevice9Video; +interface DECLSPEC_UUID("FF24BEEE-DA21-4beb-98B5-D2F899F98AF9") IDirect3DAuthenticatedChannel9; +interface DECLSPEC_UUID("FA0AB799-7A9C-48CA-8C5B-237E71A54434") IDirect3DCryptoSession9; + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + #if defined(_COM_SMARTPTR_TYPEDEF) _COM_SMARTPTR_TYPEDEF(IDirect3D9, __uuidof(IDirect3D9)); _COM_SMARTPTR_TYPEDEF(IDirect3DDevice9, __uuidof(IDirect3DDevice9)); @@ -185,7 +233,23 @@ _COM_SMARTPTR_TYPEDEF(IDirect3DVolume9, __uuidof(IDirect3DVolume9)); _COM_SMARTPTR_TYPEDEF(IDirect3DSwapChain9, __uuidof(IDirect3DSwapChain9)); _COM_SMARTPTR_TYPEDEF(IDirect3DQuery9, __uuidof(IDirect3DQuery9)); + +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +_COM_SMARTPTR_TYPEDEF(IDirect3D9Ex, __uuidof(IDirect3D9Ex)); +_COM_SMARTPTR_TYPEDEF(IDirect3DDevice9Ex, __uuidof(IDirect3DDevice9Ex)); +_COM_SMARTPTR_TYPEDEF(IDirect3DSwapChain9Ex, __uuidof(IDirect3DSwapChain9Ex)); +_COM_SMARTPTR_TYPEDEF(IDirect3D9ExOverlayExtension, __uuidof(IDirect3D9ExOverlayExtension)); +_COM_SMARTPTR_TYPEDEF(IDirect3DDevice9Video, __uuidof(IDirect3DDevice9Video)); +_COM_SMARTPTR_TYPEDEF(IDirect3DAuthenticatedChannel9, __uuidof(IDirect3DAuthenticatedChannel9)); +_COM_SMARTPTR_TYPEDEF(IDirect3DCryptoSession9, __uuidof(IDirect3DCryptoSession9)); + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + #endif + #endif @@ -208,6 +272,21 @@ typedef interface IDirect3DSwapChain9 IDirect3DSwapChain9; typedef interface IDirect3DQuery9 IDirect3DQuery9; +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + + +typedef interface IDirect3D9Ex IDirect3D9Ex; +typedef interface IDirect3DDevice9Ex IDirect3DDevice9Ex; +typedef interface IDirect3DSwapChain9Ex IDirect3DSwapChain9Ex; +typedef interface IDirect3D9ExOverlayExtension IDirect3D9ExOverlayExtension; +typedef interface IDirect3DDevice9Video IDirect3DDevice9Video; +typedef interface IDirect3DAuthenticatedChannel9 IDirect3DAuthenticatedChannel9; +typedef interface IDirect3DCryptoSession9 IDirect3DCryptoSession9; + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + #include "d3d9types.h" #include "d3d9caps.h" @@ -750,6 +829,9 @@ typedef struct IDirect3DDevice9 *LPDIRECT3DDEVICE9, *PDIRECT3DDEVICE9; #endif + + + #undef INTERFACE #define INTERFACE IDirect3DStateBlock9 @@ -1764,6 +1846,23 @@ typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; // mode, etc.) should be coded. #define D3DCREATE_NOWINDOWCHANGES 0x00000800L +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +// Disable multithreading for software vertex processing +#define D3DCREATE_DISABLE_PSGP_THREADING 0x00002000L +// This flag enables present statistics on device. +#define D3DCREATE_ENABLE_PRESENTSTATS 0x00004000L +// This flag disables printscreen support in the runtime for this device +#define D3DCREATE_DISABLE_PRINTSCREEN 0x00008000L + +#define D3DCREATE_SCREENSAVER 0x10000000L + + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + + /**************************************************************************** * @@ -1779,8 +1878,24 @@ typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; * ****************************************************************************/ +/* + * The D3DENUM_WHQL_LEVEL value has been retired for 9Ex and future versions, + * but it needs to be defined here for compatibility with DX9 and earlier versions. + * See the DirectX SDK for sample code on discovering driver signatures. + */ #define D3DENUM_WHQL_LEVEL 0x00000002L +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +/* NO_DRIVERVERSION will not fill out the DriverVersion field, nor will the + DriverVersion be incorporated into the DeviceIdentifier GUID. WINNT only */ +#define D3DENUM_NO_DRIVERVERSION 0x00000004L + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + + /**************************************************************************** * * Maximum number of back-buffers supported in DX9 @@ -1789,6 +1904,20 @@ typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; #define D3DPRESENT_BACK_BUFFERS_MAX 3L +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +/**************************************************************************** + * + * Maximum number of back-buffers supported when apps use CreateDeviceEx + * + ****************************************************************************/ + +#define D3DPRESENT_BACK_BUFFERS_MAX_EX 30L + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + /**************************************************************************** * * Flags for IDirect3DDevice9::SetGammaRamp @@ -1815,6 +1944,21 @@ typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; #define D3DPRESENT_DONOTWAIT 0x00000001L #define D3DPRESENT_LINEAR_CONTENT 0x00000002L +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +#define D3DPRESENT_DONOTFLIP 0x00000004L +#define D3DPRESENT_FLIPRESTART 0x00000008L +#define D3DPRESENT_VIDEO_RESTRICT_TO_MONITOR 0x00000010L +#define D3DPRESENT_UPDATEOVERLAYONLY 0x00000020L +#define D3DPRESENT_HIDEOVERLAY 0x00000040L +#define D3DPRESENT_UPDATECOLORKEY 0x00000080L +#define D3DPRESENT_FORCEIMMEDIATE 0x00000100L + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + + /**************************************************************************** * * Flags for DrawPrimitive/DrawIndexedPrimitive @@ -1860,6 +2004,783 @@ typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; #define D3DERR_WASSTILLDRAWING MAKE_D3DHRESULT(540) #define D3DOK_NOAUTOGEN MAKE_D3DSTATUS(2159) +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + + +#define D3DERR_DEVICEREMOVED MAKE_D3DHRESULT(2160) +#define S_NOT_RESIDENT MAKE_D3DSTATUS(2165) +#define S_RESIDENT_IN_SHARED_MEMORY MAKE_D3DSTATUS(2166) +#define S_PRESENT_MODE_CHANGED MAKE_D3DSTATUS(2167) +#define S_PRESENT_OCCLUDED MAKE_D3DSTATUS(2168) +#define D3DERR_DEVICEHUNG MAKE_D3DHRESULT(2164) +#define D3DERR_UNSUPPORTEDOVERLAY MAKE_D3DHRESULT(2171) +#define D3DERR_UNSUPPORTEDOVERLAYFORMAT MAKE_D3DHRESULT(2172) +#define D3DERR_CANNOTPROTECTCONTENT MAKE_D3DHRESULT(2173) +#define D3DERR_UNSUPPORTEDCRYPTO MAKE_D3DHRESULT(2174) +#define D3DERR_PRESENT_STATISTICS_DISJOINT MAKE_D3DHRESULT(2180) + + +/********************* +/* D3D9Ex interfaces +/*********************/ + +HRESULT WINAPI Direct3DCreate9Ex(UINT SDKVersion, IDirect3D9Ex**); + + + + +#undef INTERFACE +#define INTERFACE IDirect3D9Ex + +DECLARE_INTERFACE_(IDirect3D9Ex, IDirect3D9) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirect3D9 methods ***/ + STDMETHOD_(UINT, GetAdapterCount)(THIS) PURE; + STDMETHOD(GetAdapterIdentifier)(THIS_ UINT Adapter,DWORD Flags,D3DADAPTER_IDENTIFIER9* pIdentifier) PURE; + STDMETHOD_(UINT, GetAdapterModeCount)(THIS_ UINT Adapter,D3DFORMAT Format) PURE; + STDMETHOD(EnumAdapterModes)(THIS_ UINT Adapter,D3DFORMAT Format,UINT Mode,D3DDISPLAYMODE* pMode) PURE; + STDMETHOD(GetAdapterDisplayMode)(THIS_ UINT Adapter,D3DDISPLAYMODE* pMode) PURE; + STDMETHOD(CheckDeviceType)(THIS_ UINT Adapter,D3DDEVTYPE DevType,D3DFORMAT AdapterFormat,D3DFORMAT BackBufferFormat,BOOL bWindowed) PURE; + STDMETHOD(CheckDeviceFormat)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,DWORD Usage,D3DRESOURCETYPE RType,D3DFORMAT CheckFormat) PURE; + STDMETHOD(CheckDeviceMultiSampleType)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT SurfaceFormat,BOOL Windowed,D3DMULTISAMPLE_TYPE MultiSampleType,DWORD* pQualityLevels) PURE; + STDMETHOD(CheckDepthStencilMatch)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,D3DFORMAT RenderTargetFormat,D3DFORMAT DepthStencilFormat) PURE; + STDMETHOD(CheckDeviceFormatConversion)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT SourceFormat,D3DFORMAT TargetFormat) PURE; + STDMETHOD(GetDeviceCaps)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DCAPS9* pCaps) PURE; + STDMETHOD_(HMONITOR, GetAdapterMonitor)(THIS_ UINT Adapter) PURE; + STDMETHOD(CreateDevice)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,HWND hFocusWindow,DWORD BehaviorFlags,D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DDevice9** ppReturnedDeviceInterface) PURE; + STDMETHOD_(UINT, GetAdapterModeCountEx)(THIS_ UINT Adapter,CONST D3DDISPLAYMODEFILTER* pFilter ) PURE; + STDMETHOD(EnumAdapterModesEx)(THIS_ UINT Adapter,CONST D3DDISPLAYMODEFILTER* pFilter,UINT Mode,D3DDISPLAYMODEEX* pMode) PURE; + STDMETHOD(GetAdapterDisplayModeEx)(THIS_ UINT Adapter,D3DDISPLAYMODEEX* pMode,D3DDISPLAYROTATION* pRotation) PURE; + STDMETHOD(CreateDeviceEx)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,HWND hFocusWindow,DWORD BehaviorFlags,D3DPRESENT_PARAMETERS* pPresentationParameters,D3DDISPLAYMODEEX* pFullscreenDisplayMode,IDirect3DDevice9Ex** ppReturnedDeviceInterface) PURE; + STDMETHOD(GetAdapterLUID)(THIS_ UINT Adapter,LUID * pLUID) PURE; +}; + +typedef struct IDirect3D9Ex *LPDIRECT3D9EX, *PDIRECT3D9EX; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirect3D9Ex_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirect3D9Ex_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirect3D9Ex_Release(p) (p)->lpVtbl->Release(p) +#define IDirect3D9Ex_GetAdapterCount(p) (p)->lpVtbl->GetAdapterCount(p) +#define IDirect3D9Ex_GetAdapterIdentifier(p,a,b,c) (p)->lpVtbl->GetAdapterIdentifier(p,a,b,c) +#define IDirect3D9Ex_GetAdapterModeCount(p,a,b) (p)->lpVtbl->GetAdapterModeCount(p,a,b) +#define IDirect3D9Ex_EnumAdapterModes(p,a,b,c,d) (p)->lpVtbl->EnumAdapterModes(p,a,b,c,d) +#define IDirect3D9Ex_GetAdapterDisplayMode(p,a,b) (p)->lpVtbl->GetAdapterDisplayMode(p,a,b) +#define IDirect3D9Ex_CheckDeviceType(p,a,b,c,d,e) (p)->lpVtbl->CheckDeviceType(p,a,b,c,d,e) +#define IDirect3D9Ex_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceFormat(p,a,b,c,d,e,f) +#define IDirect3D9Ex_CheckDeviceMultiSampleType(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceMultiSampleType(p,a,b,c,d,e,f) +#define IDirect3D9Ex_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->lpVtbl->CheckDepthStencilMatch(p,a,b,c,d,e) +#define IDirect3D9Ex_CheckDeviceFormatConversion(p,a,b,c,d) (p)->lpVtbl->CheckDeviceFormatConversion(p,a,b,c,d) +#define IDirect3D9Ex_GetDeviceCaps(p,a,b,c) (p)->lpVtbl->GetDeviceCaps(p,a,b,c) +#define IDirect3D9Ex_GetAdapterMonitor(p,a) (p)->lpVtbl->GetAdapterMonitor(p,a) +#define IDirect3D9Ex_CreateDevice(p,a,b,c,d,e,f) (p)->lpVtbl->CreateDevice(p,a,b,c,d,e,f) +#define IDirect3D9Ex_GetAdapterModeCountEx(p,a,b) (p)->lpVtbl->GetAdapterModeCountEx(p,a,b) +#define IDirect3D9Ex_EnumAdapterModesEx(p,a,b,c,d) (p)->lpVtbl->EnumAdapterModesEx(p,a,b,c,d) +#define IDirect3D9Ex_GetAdapterDisplayModeEx(p,a,b,c) (p)->lpVtbl->GetAdapterDisplayModeEx(p,a,b,c) +#define IDirect3D9Ex_CreateDeviceEx(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateDeviceEx(p,a,b,c,d,e,f,g) +#define IDirect3D9Ex_GetAdapterLUID(p,a,b) (p)->lpVtbl->GetAdapterLUID(p,a,b) +#else +#define IDirect3D9Ex_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirect3D9Ex_AddRef(p) (p)->AddRef() +#define IDirect3D9Ex_Release(p) (p)->Release() +#define IDirect3D9Ex_GetAdapterCount(p) (p)->GetAdapterCount() +#define IDirect3D9Ex_GetAdapterIdentifier(p,a,b,c) (p)->GetAdapterIdentifier(a,b,c) +#define IDirect3D9Ex_GetAdapterModeCount(p,a,b) (p)->GetAdapterModeCount(a,b) +#define IDirect3D9Ex_EnumAdapterModes(p,a,b,c,d) (p)->EnumAdapterModes(a,b,c,d) +#define IDirect3D9Ex_GetAdapterDisplayMode(p,a,b) (p)->GetAdapterDisplayMode(a,b) +#define IDirect3D9Ex_CheckDeviceType(p,a,b,c,d,e) (p)->CheckDeviceType(a,b,c,d,e) +#define IDirect3D9Ex_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->CheckDeviceFormat(a,b,c,d,e,f) +#define IDirect3D9Ex_CheckDeviceMultiSampleType(p,a,b,c,d,e,f) (p)->CheckDeviceMultiSampleType(a,b,c,d,e,f) +#define IDirect3D9Ex_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->CheckDepthStencilMatch(a,b,c,d,e) +#define IDirect3D9Ex_CheckDeviceFormatConversion(p,a,b,c,d) (p)->CheckDeviceFormatConversion(a,b,c,d) +#define IDirect3D9Ex_GetDeviceCaps(p,a,b,c) (p)->GetDeviceCaps(a,b,c) +#define IDirect3D9Ex_GetAdapterMonitor(p,a) (p)->GetAdapterMonitor(a) +#define IDirect3D9Ex_CreateDevice(p,a,b,c,d,e,f) (p)->CreateDevice(a,b,c,d,e,f) +#define IDirect3D9Ex_GetAdapterModeCountEx(p,a,b) (p)->GetAdapterModeCountEx(a,b) +#define IDirect3D9Ex_EnumAdapterModesEx(p,a,b,c,d) (p)->EnumAdapterModesEx(a,b,c,d) +#define IDirect3D9Ex_GetAdapterDisplayModeEx(p,a,b,c) (p)->GetAdapterDisplayModeEx(a,b,c) +#define IDirect3D9Ex_CreateDeviceEx(p,a,b,c,d,e,f,g) (p)->CreateDeviceEx(a,b,c,d,e,f,g) +#define IDirect3D9Ex_GetAdapterLUID(p,a,b) (p)->GetAdapterLUID(a,b) +#endif + + + + + + + + + + + + + + + + + + + + + + + + +#undef INTERFACE +#define INTERFACE IDirect3DDevice9Ex + +DECLARE_INTERFACE_(IDirect3DDevice9Ex, IDirect3DDevice9) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirect3DDevice9 methods ***/ + STDMETHOD(TestCooperativeLevel)(THIS) PURE; + STDMETHOD_(UINT, GetAvailableTextureMem)(THIS) PURE; + STDMETHOD(EvictManagedResources)(THIS) PURE; + STDMETHOD(GetDirect3D)(THIS_ IDirect3D9** ppD3D9) PURE; + STDMETHOD(GetDeviceCaps)(THIS_ D3DCAPS9* pCaps) PURE; + STDMETHOD(GetDisplayMode)(THIS_ UINT iSwapChain,D3DDISPLAYMODE* pMode) PURE; + STDMETHOD(GetCreationParameters)(THIS_ D3DDEVICE_CREATION_PARAMETERS *pParameters) PURE; + STDMETHOD(SetCursorProperties)(THIS_ UINT XHotSpot,UINT YHotSpot,IDirect3DSurface9* pCursorBitmap) PURE; + STDMETHOD_(void, SetCursorPosition)(THIS_ int X,int Y,DWORD Flags) PURE; + STDMETHOD_(BOOL, ShowCursor)(THIS_ BOOL bShow) PURE; + STDMETHOD(CreateAdditionalSwapChain)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DSwapChain9** pSwapChain) PURE; + STDMETHOD(GetSwapChain)(THIS_ UINT iSwapChain,IDirect3DSwapChain9** pSwapChain) PURE; + STDMETHOD_(UINT, GetNumberOfSwapChains)(THIS) PURE; + STDMETHOD(Reset)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters) PURE; + STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion) PURE; + STDMETHOD(GetBackBuffer)(THIS_ UINT iSwapChain,UINT iBackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface9** ppBackBuffer) PURE; + STDMETHOD(GetRasterStatus)(THIS_ UINT iSwapChain,D3DRASTER_STATUS* pRasterStatus) PURE; + STDMETHOD(SetDialogBoxMode)(THIS_ BOOL bEnableDialogs) PURE; + STDMETHOD_(void, SetGammaRamp)(THIS_ UINT iSwapChain,DWORD Flags,CONST D3DGAMMARAMP* pRamp) PURE; + STDMETHOD_(void, GetGammaRamp)(THIS_ UINT iSwapChain,D3DGAMMARAMP* pRamp) PURE; + STDMETHOD(CreateTexture)(THIS_ UINT Width,UINT Height,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DTexture9** ppTexture,HANDLE* pSharedHandle) PURE; + STDMETHOD(CreateVolumeTexture)(THIS_ UINT Width,UINT Height,UINT Depth,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DVolumeTexture9** ppVolumeTexture,HANDLE* pSharedHandle) PURE; + STDMETHOD(CreateCubeTexture)(THIS_ UINT EdgeLength,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DCubeTexture9** ppCubeTexture,HANDLE* pSharedHandle) PURE; + STDMETHOD(CreateVertexBuffer)(THIS_ UINT Length,DWORD Usage,DWORD FVF,D3DPOOL Pool,IDirect3DVertexBuffer9** ppVertexBuffer,HANDLE* pSharedHandle) PURE; + STDMETHOD(CreateIndexBuffer)(THIS_ UINT Length,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DIndexBuffer9** ppIndexBuffer,HANDLE* pSharedHandle) PURE; + STDMETHOD(CreateRenderTarget)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,DWORD MultisampleQuality,BOOL Lockable,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle) PURE; + STDMETHOD(CreateDepthStencilSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,DWORD MultisampleQuality,BOOL Discard,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle) PURE; + STDMETHOD(UpdateSurface)(THIS_ IDirect3DSurface9* pSourceSurface,CONST RECT* pSourceRect,IDirect3DSurface9* pDestinationSurface,CONST POINT* pDestPoint) PURE; + STDMETHOD(UpdateTexture)(THIS_ IDirect3DBaseTexture9* pSourceTexture,IDirect3DBaseTexture9* pDestinationTexture) PURE; + STDMETHOD(GetRenderTargetData)(THIS_ IDirect3DSurface9* pRenderTarget,IDirect3DSurface9* pDestSurface) PURE; + STDMETHOD(GetFrontBufferData)(THIS_ UINT iSwapChain,IDirect3DSurface9* pDestSurface) PURE; + STDMETHOD(StretchRect)(THIS_ IDirect3DSurface9* pSourceSurface,CONST RECT* pSourceRect,IDirect3DSurface9* pDestSurface,CONST RECT* pDestRect,D3DTEXTUREFILTERTYPE Filter) PURE; + STDMETHOD(ColorFill)(THIS_ IDirect3DSurface9* pSurface,CONST RECT* pRect,D3DCOLOR color) PURE; + STDMETHOD(CreateOffscreenPlainSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DPOOL Pool,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle) PURE; + STDMETHOD(SetRenderTarget)(THIS_ DWORD RenderTargetIndex,IDirect3DSurface9* pRenderTarget) PURE; + STDMETHOD(GetRenderTarget)(THIS_ DWORD RenderTargetIndex,IDirect3DSurface9** ppRenderTarget) PURE; + STDMETHOD(SetDepthStencilSurface)(THIS_ IDirect3DSurface9* pNewZStencil) PURE; + STDMETHOD(GetDepthStencilSurface)(THIS_ IDirect3DSurface9** ppZStencilSurface) PURE; + STDMETHOD(BeginScene)(THIS) PURE; + STDMETHOD(EndScene)(THIS) PURE; + STDMETHOD(Clear)(THIS_ DWORD Count,CONST D3DRECT* pRects,DWORD Flags,D3DCOLOR Color,float Z,DWORD Stencil) PURE; + STDMETHOD(SetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,CONST D3DMATRIX* pMatrix) PURE; + STDMETHOD(GetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,D3DMATRIX* pMatrix) PURE; + STDMETHOD(MultiplyTransform)(THIS_ D3DTRANSFORMSTATETYPE,CONST D3DMATRIX*) PURE; + STDMETHOD(SetViewport)(THIS_ CONST D3DVIEWPORT9* pViewport) PURE; + STDMETHOD(GetViewport)(THIS_ D3DVIEWPORT9* pViewport) PURE; + STDMETHOD(SetMaterial)(THIS_ CONST D3DMATERIAL9* pMaterial) PURE; + STDMETHOD(GetMaterial)(THIS_ D3DMATERIAL9* pMaterial) PURE; + STDMETHOD(SetLight)(THIS_ DWORD Index,CONST D3DLIGHT9*) PURE; + STDMETHOD(GetLight)(THIS_ DWORD Index,D3DLIGHT9*) PURE; + STDMETHOD(LightEnable)(THIS_ DWORD Index,BOOL Enable) PURE; + STDMETHOD(GetLightEnable)(THIS_ DWORD Index,BOOL* pEnable) PURE; + STDMETHOD(SetClipPlane)(THIS_ DWORD Index,CONST float* pPlane) PURE; + STDMETHOD(GetClipPlane)(THIS_ DWORD Index,float* pPlane) PURE; + STDMETHOD(SetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD Value) PURE; + STDMETHOD(GetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD* pValue) PURE; + STDMETHOD(CreateStateBlock)(THIS_ D3DSTATEBLOCKTYPE Type,IDirect3DStateBlock9** ppSB) PURE; + STDMETHOD(BeginStateBlock)(THIS) PURE; + STDMETHOD(EndStateBlock)(THIS_ IDirect3DStateBlock9** ppSB) PURE; + STDMETHOD(SetClipStatus)(THIS_ CONST D3DCLIPSTATUS9* pClipStatus) PURE; + STDMETHOD(GetClipStatus)(THIS_ D3DCLIPSTATUS9* pClipStatus) PURE; + STDMETHOD(GetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture9** ppTexture) PURE; + STDMETHOD(SetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture9* pTexture) PURE; + STDMETHOD(GetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD* pValue) PURE; + STDMETHOD(SetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD Value) PURE; + STDMETHOD(GetSamplerState)(THIS_ DWORD Sampler,D3DSAMPLERSTATETYPE Type,DWORD* pValue) PURE; + STDMETHOD(SetSamplerState)(THIS_ DWORD Sampler,D3DSAMPLERSTATETYPE Type,DWORD Value) PURE; + STDMETHOD(ValidateDevice)(THIS_ DWORD* pNumPasses) PURE; + STDMETHOD(SetPaletteEntries)(THIS_ UINT PaletteNumber,CONST PALETTEENTRY* pEntries) PURE; + STDMETHOD(GetPaletteEntries)(THIS_ UINT PaletteNumber,PALETTEENTRY* pEntries) PURE; + STDMETHOD(SetCurrentTexturePalette)(THIS_ UINT PaletteNumber) PURE; + STDMETHOD(GetCurrentTexturePalette)(THIS_ UINT *PaletteNumber) PURE; + STDMETHOD(SetScissorRect)(THIS_ CONST RECT* pRect) PURE; + STDMETHOD(GetScissorRect)(THIS_ RECT* pRect) PURE; + STDMETHOD(SetSoftwareVertexProcessing)(THIS_ BOOL bSoftware) PURE; + STDMETHOD_(BOOL, GetSoftwareVertexProcessing)(THIS) PURE; + STDMETHOD(SetNPatchMode)(THIS_ float nSegments) PURE; + STDMETHOD_(float, GetNPatchMode)(THIS) PURE; + STDMETHOD(DrawPrimitive)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT StartVertex,UINT PrimitiveCount) PURE; + STDMETHOD(DrawIndexedPrimitive)(THIS_ D3DPRIMITIVETYPE,INT BaseVertexIndex,UINT MinVertexIndex,UINT NumVertices,UINT startIndex,UINT primCount) PURE; + STDMETHOD(DrawPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT PrimitiveCount,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE; + STDMETHOD(DrawIndexedPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT MinVertexIndex,UINT NumVertices,UINT PrimitiveCount,CONST void* pIndexData,D3DFORMAT IndexDataFormat,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE; + STDMETHOD(ProcessVertices)(THIS_ UINT SrcStartIndex,UINT DestIndex,UINT VertexCount,IDirect3DVertexBuffer9* pDestBuffer,IDirect3DVertexDeclaration9* pVertexDecl,DWORD Flags) PURE; + STDMETHOD(CreateVertexDeclaration)(THIS_ CONST D3DVERTEXELEMENT9* pVertexElements,IDirect3DVertexDeclaration9** ppDecl) PURE; + STDMETHOD(SetVertexDeclaration)(THIS_ IDirect3DVertexDeclaration9* pDecl) PURE; + STDMETHOD(GetVertexDeclaration)(THIS_ IDirect3DVertexDeclaration9** ppDecl) PURE; + STDMETHOD(SetFVF)(THIS_ DWORD FVF) PURE; + STDMETHOD(GetFVF)(THIS_ DWORD* pFVF) PURE; + STDMETHOD(CreateVertexShader)(THIS_ CONST DWORD* pFunction,IDirect3DVertexShader9** ppShader) PURE; + STDMETHOD(SetVertexShader)(THIS_ IDirect3DVertexShader9* pShader) PURE; + STDMETHOD(GetVertexShader)(THIS_ IDirect3DVertexShader9** ppShader) PURE; + STDMETHOD(SetVertexShaderConstantF)(THIS_ UINT StartRegister,CONST float* pConstantData,UINT Vector4fCount) PURE; + STDMETHOD(GetVertexShaderConstantF)(THIS_ UINT StartRegister,float* pConstantData,UINT Vector4fCount) PURE; + STDMETHOD(SetVertexShaderConstantI)(THIS_ UINT StartRegister,CONST int* pConstantData,UINT Vector4iCount) PURE; + STDMETHOD(GetVertexShaderConstantI)(THIS_ UINT StartRegister,int* pConstantData,UINT Vector4iCount) PURE; + STDMETHOD(SetVertexShaderConstantB)(THIS_ UINT StartRegister,CONST BOOL* pConstantData,UINT BoolCount) PURE; + STDMETHOD(GetVertexShaderConstantB)(THIS_ UINT StartRegister,BOOL* pConstantData,UINT BoolCount) PURE; + STDMETHOD(SetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer9* pStreamData,UINT OffsetInBytes,UINT Stride) PURE; + STDMETHOD(GetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer9** ppStreamData,UINT* pOffsetInBytes,UINT* pStride) PURE; + STDMETHOD(SetStreamSourceFreq)(THIS_ UINT StreamNumber,UINT Setting) PURE; + STDMETHOD(GetStreamSourceFreq)(THIS_ UINT StreamNumber,UINT* pSetting) PURE; + STDMETHOD(SetIndices)(THIS_ IDirect3DIndexBuffer9* pIndexData) PURE; + STDMETHOD(GetIndices)(THIS_ IDirect3DIndexBuffer9** ppIndexData) PURE; + STDMETHOD(CreatePixelShader)(THIS_ CONST DWORD* pFunction,IDirect3DPixelShader9** ppShader) PURE; + STDMETHOD(SetPixelShader)(THIS_ IDirect3DPixelShader9* pShader) PURE; + STDMETHOD(GetPixelShader)(THIS_ IDirect3DPixelShader9** ppShader) PURE; + STDMETHOD(SetPixelShaderConstantF)(THIS_ UINT StartRegister,CONST float* pConstantData,UINT Vector4fCount) PURE; + STDMETHOD(GetPixelShaderConstantF)(THIS_ UINT StartRegister,float* pConstantData,UINT Vector4fCount) PURE; + STDMETHOD(SetPixelShaderConstantI)(THIS_ UINT StartRegister,CONST int* pConstantData,UINT Vector4iCount) PURE; + STDMETHOD(GetPixelShaderConstantI)(THIS_ UINT StartRegister,int* pConstantData,UINT Vector4iCount) PURE; + STDMETHOD(SetPixelShaderConstantB)(THIS_ UINT StartRegister,CONST BOOL* pConstantData,UINT BoolCount) PURE; + STDMETHOD(GetPixelShaderConstantB)(THIS_ UINT StartRegister,BOOL* pConstantData,UINT BoolCount) PURE; + STDMETHOD(DrawRectPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DRECTPATCH_INFO* pRectPatchInfo) PURE; + STDMETHOD(DrawTriPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DTRIPATCH_INFO* pTriPatchInfo) PURE; + STDMETHOD(DeletePatch)(THIS_ UINT Handle) PURE; + STDMETHOD(CreateQuery)(THIS_ D3DQUERYTYPE Type,IDirect3DQuery9** ppQuery) PURE; + STDMETHOD(SetConvolutionMonoKernel)(THIS_ UINT width,UINT height,float* rows,float* columns) PURE; + STDMETHOD(ComposeRects)(THIS_ IDirect3DSurface9* pSrc,IDirect3DSurface9* pDst,IDirect3DVertexBuffer9* pSrcRectDescs,UINT NumRects,IDirect3DVertexBuffer9* pDstRectDescs,D3DCOMPOSERECTSOP Operation,int Xoffset,int Yoffset) PURE; + STDMETHOD(PresentEx)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion,DWORD dwFlags) PURE; + STDMETHOD(GetGPUThreadPriority)(THIS_ INT* pPriority) PURE; + STDMETHOD(SetGPUThreadPriority)(THIS_ INT Priority) PURE; + STDMETHOD(WaitForVBlank)(THIS_ UINT iSwapChain) PURE; + STDMETHOD(CheckResourceResidency)(THIS_ IDirect3DResource9** pResourceArray,UINT32 NumResources) PURE; + STDMETHOD(SetMaximumFrameLatency)(THIS_ UINT MaxLatency) PURE; + STDMETHOD(GetMaximumFrameLatency)(THIS_ UINT* pMaxLatency) PURE; + STDMETHOD(CheckDeviceState)(THIS_ HWND hDestinationWindow) PURE; + STDMETHOD(CreateRenderTargetEx)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,DWORD MultisampleQuality,BOOL Lockable,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle,DWORD Usage) PURE; + STDMETHOD(CreateOffscreenPlainSurfaceEx)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DPOOL Pool,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle,DWORD Usage) PURE; + STDMETHOD(CreateDepthStencilSurfaceEx)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,DWORD MultisampleQuality,BOOL Discard,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle,DWORD Usage) PURE; + STDMETHOD(ResetEx)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters,D3DDISPLAYMODEEX *pFullscreenDisplayMode) PURE; + STDMETHOD(GetDisplayModeEx)(THIS_ UINT iSwapChain,D3DDISPLAYMODEEX* pMode,D3DDISPLAYROTATION* pRotation) PURE; +}; + +typedef struct IDirect3DDevice9Ex *LPDIRECT3DDEVICE9EX, *PDIRECT3DDEVICE9EX; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirect3DDevice9Ex_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirect3DDevice9Ex_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirect3DDevice9Ex_Release(p) (p)->lpVtbl->Release(p) +#define IDirect3DDevice9Ex_TestCooperativeLevel(p) (p)->lpVtbl->TestCooperativeLevel(p) +#define IDirect3DDevice9Ex_GetAvailableTextureMem(p) (p)->lpVtbl->GetAvailableTextureMem(p) +#define IDirect3DDevice9Ex_EvictManagedResources(p) (p)->lpVtbl->EvictManagedResources(p) +#define IDirect3DDevice9Ex_GetDirect3D(p,a) (p)->lpVtbl->GetDirect3D(p,a) +#define IDirect3DDevice9Ex_GetDeviceCaps(p,a) (p)->lpVtbl->GetDeviceCaps(p,a) +#define IDirect3DDevice9Ex_GetDisplayMode(p,a,b) (p)->lpVtbl->GetDisplayMode(p,a,b) +#define IDirect3DDevice9Ex_GetCreationParameters(p,a) (p)->lpVtbl->GetCreationParameters(p,a) +#define IDirect3DDevice9Ex_SetCursorProperties(p,a,b,c) (p)->lpVtbl->SetCursorProperties(p,a,b,c) +#define IDirect3DDevice9Ex_SetCursorPosition(p,a,b,c) (p)->lpVtbl->SetCursorPosition(p,a,b,c) +#define IDirect3DDevice9Ex_ShowCursor(p,a) (p)->lpVtbl->ShowCursor(p,a) +#define IDirect3DDevice9Ex_CreateAdditionalSwapChain(p,a,b) (p)->lpVtbl->CreateAdditionalSwapChain(p,a,b) +#define IDirect3DDevice9Ex_GetSwapChain(p,a,b) (p)->lpVtbl->GetSwapChain(p,a,b) +#define IDirect3DDevice9Ex_GetNumberOfSwapChains(p) (p)->lpVtbl->GetNumberOfSwapChains(p) +#define IDirect3DDevice9Ex_Reset(p,a) (p)->lpVtbl->Reset(p,a) +#define IDirect3DDevice9Ex_Present(p,a,b,c,d) (p)->lpVtbl->Present(p,a,b,c,d) +#define IDirect3DDevice9Ex_GetBackBuffer(p,a,b,c,d) (p)->lpVtbl->GetBackBuffer(p,a,b,c,d) +#define IDirect3DDevice9Ex_GetRasterStatus(p,a,b) (p)->lpVtbl->GetRasterStatus(p,a,b) +#define IDirect3DDevice9Ex_SetDialogBoxMode(p,a) (p)->lpVtbl->SetDialogBoxMode(p,a) +#define IDirect3DDevice9Ex_SetGammaRamp(p,a,b,c) (p)->lpVtbl->SetGammaRamp(p,a,b,c) +#define IDirect3DDevice9Ex_GetGammaRamp(p,a,b) (p)->lpVtbl->GetGammaRamp(p,a,b) +#define IDirect3DDevice9Ex_CreateTexture(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateTexture(p,a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_CreateVolumeTexture(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CreateVolumeTexture(p,a,b,c,d,e,f,g,h,i) +#define IDirect3DDevice9Ex_CreateCubeTexture(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateCubeTexture(p,a,b,c,d,e,f,g) +#define IDirect3DDevice9Ex_CreateVertexBuffer(p,a,b,c,d,e,f) (p)->lpVtbl->CreateVertexBuffer(p,a,b,c,d,e,f) +#define IDirect3DDevice9Ex_CreateIndexBuffer(p,a,b,c,d,e,f) (p)->lpVtbl->CreateIndexBuffer(p,a,b,c,d,e,f) +#define IDirect3DDevice9Ex_CreateRenderTarget(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateRenderTarget(p,a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_CreateDepthStencilSurface(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateDepthStencilSurface(p,a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_UpdateSurface(p,a,b,c,d) (p)->lpVtbl->UpdateSurface(p,a,b,c,d) +#define IDirect3DDevice9Ex_UpdateTexture(p,a,b) (p)->lpVtbl->UpdateTexture(p,a,b) +#define IDirect3DDevice9Ex_GetRenderTargetData(p,a,b) (p)->lpVtbl->GetRenderTargetData(p,a,b) +#define IDirect3DDevice9Ex_GetFrontBufferData(p,a,b) (p)->lpVtbl->GetFrontBufferData(p,a,b) +#define IDirect3DDevice9Ex_StretchRect(p,a,b,c,d,e) (p)->lpVtbl->StretchRect(p,a,b,c,d,e) +#define IDirect3DDevice9Ex_ColorFill(p,a,b,c) (p)->lpVtbl->ColorFill(p,a,b,c) +#define IDirect3DDevice9Ex_CreateOffscreenPlainSurface(p,a,b,c,d,e,f) (p)->lpVtbl->CreateOffscreenPlainSurface(p,a,b,c,d,e,f) +#define IDirect3DDevice9Ex_SetRenderTarget(p,a,b) (p)->lpVtbl->SetRenderTarget(p,a,b) +#define IDirect3DDevice9Ex_GetRenderTarget(p,a,b) (p)->lpVtbl->GetRenderTarget(p,a,b) +#define IDirect3DDevice9Ex_SetDepthStencilSurface(p,a) (p)->lpVtbl->SetDepthStencilSurface(p,a) +#define IDirect3DDevice9Ex_GetDepthStencilSurface(p,a) (p)->lpVtbl->GetDepthStencilSurface(p,a) +#define IDirect3DDevice9Ex_BeginScene(p) (p)->lpVtbl->BeginScene(p) +#define IDirect3DDevice9Ex_EndScene(p) (p)->lpVtbl->EndScene(p) +#define IDirect3DDevice9Ex_Clear(p,a,b,c,d,e,f) (p)->lpVtbl->Clear(p,a,b,c,d,e,f) +#define IDirect3DDevice9Ex_SetTransform(p,a,b) (p)->lpVtbl->SetTransform(p,a,b) +#define IDirect3DDevice9Ex_GetTransform(p,a,b) (p)->lpVtbl->GetTransform(p,a,b) +#define IDirect3DDevice9Ex_MultiplyTransform(p,a,b) (p)->lpVtbl->MultiplyTransform(p,a,b) +#define IDirect3DDevice9Ex_SetViewport(p,a) (p)->lpVtbl->SetViewport(p,a) +#define IDirect3DDevice9Ex_GetViewport(p,a) (p)->lpVtbl->GetViewport(p,a) +#define IDirect3DDevice9Ex_SetMaterial(p,a) (p)->lpVtbl->SetMaterial(p,a) +#define IDirect3DDevice9Ex_GetMaterial(p,a) (p)->lpVtbl->GetMaterial(p,a) +#define IDirect3DDevice9Ex_SetLight(p,a,b) (p)->lpVtbl->SetLight(p,a,b) +#define IDirect3DDevice9Ex_GetLight(p,a,b) (p)->lpVtbl->GetLight(p,a,b) +#define IDirect3DDevice9Ex_LightEnable(p,a,b) (p)->lpVtbl->LightEnable(p,a,b) +#define IDirect3DDevice9Ex_GetLightEnable(p,a,b) (p)->lpVtbl->GetLightEnable(p,a,b) +#define IDirect3DDevice9Ex_SetClipPlane(p,a,b) (p)->lpVtbl->SetClipPlane(p,a,b) +#define IDirect3DDevice9Ex_GetClipPlane(p,a,b) (p)->lpVtbl->GetClipPlane(p,a,b) +#define IDirect3DDevice9Ex_SetRenderState(p,a,b) (p)->lpVtbl->SetRenderState(p,a,b) +#define IDirect3DDevice9Ex_GetRenderState(p,a,b) (p)->lpVtbl->GetRenderState(p,a,b) +#define IDirect3DDevice9Ex_CreateStateBlock(p,a,b) (p)->lpVtbl->CreateStateBlock(p,a,b) +#define IDirect3DDevice9Ex_BeginStateBlock(p) (p)->lpVtbl->BeginStateBlock(p) +#define IDirect3DDevice9Ex_EndStateBlock(p,a) (p)->lpVtbl->EndStateBlock(p,a) +#define IDirect3DDevice9Ex_SetClipStatus(p,a) (p)->lpVtbl->SetClipStatus(p,a) +#define IDirect3DDevice9Ex_GetClipStatus(p,a) (p)->lpVtbl->GetClipStatus(p,a) +#define IDirect3DDevice9Ex_GetTexture(p,a,b) (p)->lpVtbl->GetTexture(p,a,b) +#define IDirect3DDevice9Ex_SetTexture(p,a,b) (p)->lpVtbl->SetTexture(p,a,b) +#define IDirect3DDevice9Ex_GetTextureStageState(p,a,b,c) (p)->lpVtbl->GetTextureStageState(p,a,b,c) +#define IDirect3DDevice9Ex_SetTextureStageState(p,a,b,c) (p)->lpVtbl->SetTextureStageState(p,a,b,c) +#define IDirect3DDevice9Ex_GetSamplerState(p,a,b,c) (p)->lpVtbl->GetSamplerState(p,a,b,c) +#define IDirect3DDevice9Ex_SetSamplerState(p,a,b,c) (p)->lpVtbl->SetSamplerState(p,a,b,c) +#define IDirect3DDevice9Ex_ValidateDevice(p,a) (p)->lpVtbl->ValidateDevice(p,a) +#define IDirect3DDevice9Ex_SetPaletteEntries(p,a,b) (p)->lpVtbl->SetPaletteEntries(p,a,b) +#define IDirect3DDevice9Ex_GetPaletteEntries(p,a,b) (p)->lpVtbl->GetPaletteEntries(p,a,b) +#define IDirect3DDevice9Ex_SetCurrentTexturePalette(p,a) (p)->lpVtbl->SetCurrentTexturePalette(p,a) +#define IDirect3DDevice9Ex_GetCurrentTexturePalette(p,a) (p)->lpVtbl->GetCurrentTexturePalette(p,a) +#define IDirect3DDevice9Ex_SetScissorRect(p,a) (p)->lpVtbl->SetScissorRect(p,a) +#define IDirect3DDevice9Ex_GetScissorRect(p,a) (p)->lpVtbl->GetScissorRect(p,a) +#define IDirect3DDevice9Ex_SetSoftwareVertexProcessing(p,a) (p)->lpVtbl->SetSoftwareVertexProcessing(p,a) +#define IDirect3DDevice9Ex_GetSoftwareVertexProcessing(p) (p)->lpVtbl->GetSoftwareVertexProcessing(p) +#define IDirect3DDevice9Ex_SetNPatchMode(p,a) (p)->lpVtbl->SetNPatchMode(p,a) +#define IDirect3DDevice9Ex_GetNPatchMode(p) (p)->lpVtbl->GetNPatchMode(p) +#define IDirect3DDevice9Ex_DrawPrimitive(p,a,b,c) (p)->lpVtbl->DrawPrimitive(p,a,b,c) +#define IDirect3DDevice9Ex_DrawIndexedPrimitive(p,a,b,c,d,e,f) (p)->lpVtbl->DrawIndexedPrimitive(p,a,b,c,d,e,f) +#define IDirect3DDevice9Ex_DrawPrimitiveUP(p,a,b,c,d) (p)->lpVtbl->DrawPrimitiveUP(p,a,b,c,d) +#define IDirect3DDevice9Ex_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_ProcessVertices(p,a,b,c,d,e,f) (p)->lpVtbl->ProcessVertices(p,a,b,c,d,e,f) +#define IDirect3DDevice9Ex_CreateVertexDeclaration(p,a,b) (p)->lpVtbl->CreateVertexDeclaration(p,a,b) +#define IDirect3DDevice9Ex_SetVertexDeclaration(p,a) (p)->lpVtbl->SetVertexDeclaration(p,a) +#define IDirect3DDevice9Ex_GetVertexDeclaration(p,a) (p)->lpVtbl->GetVertexDeclaration(p,a) +#define IDirect3DDevice9Ex_SetFVF(p,a) (p)->lpVtbl->SetFVF(p,a) +#define IDirect3DDevice9Ex_GetFVF(p,a) (p)->lpVtbl->GetFVF(p,a) +#define IDirect3DDevice9Ex_CreateVertexShader(p,a,b) (p)->lpVtbl->CreateVertexShader(p,a,b) +#define IDirect3DDevice9Ex_SetVertexShader(p,a) (p)->lpVtbl->SetVertexShader(p,a) +#define IDirect3DDevice9Ex_GetVertexShader(p,a) (p)->lpVtbl->GetVertexShader(p,a) +#define IDirect3DDevice9Ex_SetVertexShaderConstantF(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstantF(p,a,b,c) +#define IDirect3DDevice9Ex_GetVertexShaderConstantF(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstantF(p,a,b,c) +#define IDirect3DDevice9Ex_SetVertexShaderConstantI(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstantI(p,a,b,c) +#define IDirect3DDevice9Ex_GetVertexShaderConstantI(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstantI(p,a,b,c) +#define IDirect3DDevice9Ex_SetVertexShaderConstantB(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstantB(p,a,b,c) +#define IDirect3DDevice9Ex_GetVertexShaderConstantB(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstantB(p,a,b,c) +#define IDirect3DDevice9Ex_SetStreamSource(p,a,b,c,d) (p)->lpVtbl->SetStreamSource(p,a,b,c,d) +#define IDirect3DDevice9Ex_GetStreamSource(p,a,b,c,d) (p)->lpVtbl->GetStreamSource(p,a,b,c,d) +#define IDirect3DDevice9Ex_SetStreamSourceFreq(p,a,b) (p)->lpVtbl->SetStreamSourceFreq(p,a,b) +#define IDirect3DDevice9Ex_GetStreamSourceFreq(p,a,b) (p)->lpVtbl->GetStreamSourceFreq(p,a,b) +#define IDirect3DDevice9Ex_SetIndices(p,a) (p)->lpVtbl->SetIndices(p,a) +#define IDirect3DDevice9Ex_GetIndices(p,a) (p)->lpVtbl->GetIndices(p,a) +#define IDirect3DDevice9Ex_CreatePixelShader(p,a,b) (p)->lpVtbl->CreatePixelShader(p,a,b) +#define IDirect3DDevice9Ex_SetPixelShader(p,a) (p)->lpVtbl->SetPixelShader(p,a) +#define IDirect3DDevice9Ex_GetPixelShader(p,a) (p)->lpVtbl->GetPixelShader(p,a) +#define IDirect3DDevice9Ex_SetPixelShaderConstantF(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstantF(p,a,b,c) +#define IDirect3DDevice9Ex_GetPixelShaderConstantF(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstantF(p,a,b,c) +#define IDirect3DDevice9Ex_SetPixelShaderConstantI(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstantI(p,a,b,c) +#define IDirect3DDevice9Ex_GetPixelShaderConstantI(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstantI(p,a,b,c) +#define IDirect3DDevice9Ex_SetPixelShaderConstantB(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstantB(p,a,b,c) +#define IDirect3DDevice9Ex_GetPixelShaderConstantB(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstantB(p,a,b,c) +#define IDirect3DDevice9Ex_DrawRectPatch(p,a,b,c) (p)->lpVtbl->DrawRectPatch(p,a,b,c) +#define IDirect3DDevice9Ex_DrawTriPatch(p,a,b,c) (p)->lpVtbl->DrawTriPatch(p,a,b,c) +#define IDirect3DDevice9Ex_DeletePatch(p,a) (p)->lpVtbl->DeletePatch(p,a) +#define IDirect3DDevice9Ex_CreateQuery(p,a,b) (p)->lpVtbl->CreateQuery(p,a,b) +#define IDirect3DDevice9Ex_SetConvolutionMonoKernel(p,a,b,c,d) (p)->lpVtbl->SetConvolutionMonoKernel(p,a,b,c,d) +#define IDirect3DDevice9Ex_ComposeRects(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->ComposeRects(p,a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_PresentEx(p,a,b,c,d,e) (p)->lpVtbl->PresentEx(p,a,b,c,d,e) +#define IDirect3DDevice9Ex_GetGPUThreadPriority(p,a) (p)->lpVtbl->GetGPUThreadPriority(p,a) +#define IDirect3DDevice9Ex_SetGPUThreadPriority(p,a) (p)->lpVtbl->SetGPUThreadPriority(p,a) +#define IDirect3DDevice9Ex_WaitForVBlank(p,a) (p)->lpVtbl->WaitForVBlank(p,a) +#define IDirect3DDevice9Ex_CheckResourceResidency(p,a,b) (p)->lpVtbl->CheckResourceResidency(p,a,b) +#define IDirect3DDevice9Ex_SetMaximumFrameLatency(p,a) (p)->lpVtbl->SetMaximumFrameLatency(p,a) +#define IDirect3DDevice9Ex_GetMaximumFrameLatency(p,a) (p)->lpVtbl->GetMaximumFrameLatency(p,a) +#define IDirect3DDevice9Ex_CheckDeviceState(p,a) (p)->lpVtbl->CheckDeviceState(p,a) +#define IDirect3DDevice9Ex_CreateRenderTargetEx(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CreateRenderTargetEx(p,a,b,c,d,e,f,g,h,i) +#define IDirect3DDevice9Ex_CreateOffscreenPlainSurfaceEx(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateOffscreenPlainSurfaceEx(p,a,b,c,d,e,f,g) +#define IDirect3DDevice9Ex_CreateDepthStencilSurfaceEx(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CreateDepthStencilSurfaceEx(p,a,b,c,d,e,f,g,h,i) +#define IDirect3DDevice9Ex_ResetEx(p,a,b) (p)->lpVtbl->ResetEx(p,a,b) +#define IDirect3DDevice9Ex_GetDisplayModeEx(p,a,b,c) (p)->lpVtbl->GetDisplayModeEx(p,a,b,c) +#else +#define IDirect3DDevice9Ex_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirect3DDevice9Ex_AddRef(p) (p)->AddRef() +#define IDirect3DDevice9Ex_Release(p) (p)->Release() +#define IDirect3DDevice9Ex_TestCooperativeLevel(p) (p)->TestCooperativeLevel() +#define IDirect3DDevice9Ex_GetAvailableTextureMem(p) (p)->GetAvailableTextureMem() +#define IDirect3DDevice9Ex_EvictManagedResources(p) (p)->EvictManagedResources() +#define IDirect3DDevice9Ex_GetDirect3D(p,a) (p)->GetDirect3D(a) +#define IDirect3DDevice9Ex_GetDeviceCaps(p,a) (p)->GetDeviceCaps(a) +#define IDirect3DDevice9Ex_GetDisplayMode(p,a,b) (p)->GetDisplayMode(a,b) +#define IDirect3DDevice9Ex_GetCreationParameters(p,a) (p)->GetCreationParameters(a) +#define IDirect3DDevice9Ex_SetCursorProperties(p,a,b,c) (p)->SetCursorProperties(a,b,c) +#define IDirect3DDevice9Ex_SetCursorPosition(p,a,b,c) (p)->SetCursorPosition(a,b,c) +#define IDirect3DDevice9Ex_ShowCursor(p,a) (p)->ShowCursor(a) +#define IDirect3DDevice9Ex_CreateAdditionalSwapChain(p,a,b) (p)->CreateAdditionalSwapChain(a,b) +#define IDirect3DDevice9Ex_GetSwapChain(p,a,b) (p)->GetSwapChain(a,b) +#define IDirect3DDevice9Ex_GetNumberOfSwapChains(p) (p)->GetNumberOfSwapChains() +#define IDirect3DDevice9Ex_Reset(p,a) (p)->Reset(a) +#define IDirect3DDevice9Ex_Present(p,a,b,c,d) (p)->Present(a,b,c,d) +#define IDirect3DDevice9Ex_GetBackBuffer(p,a,b,c,d) (p)->GetBackBuffer(a,b,c,d) +#define IDirect3DDevice9Ex_GetRasterStatus(p,a,b) (p)->GetRasterStatus(a,b) +#define IDirect3DDevice9Ex_SetDialogBoxMode(p,a) (p)->SetDialogBoxMode(a) +#define IDirect3DDevice9Ex_SetGammaRamp(p,a,b,c) (p)->SetGammaRamp(a,b,c) +#define IDirect3DDevice9Ex_GetGammaRamp(p,a,b) (p)->GetGammaRamp(a,b) +#define IDirect3DDevice9Ex_CreateTexture(p,a,b,c,d,e,f,g,h) (p)->CreateTexture(a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_CreateVolumeTexture(p,a,b,c,d,e,f,g,h,i) (p)->CreateVolumeTexture(a,b,c,d,e,f,g,h,i) +#define IDirect3DDevice9Ex_CreateCubeTexture(p,a,b,c,d,e,f,g) (p)->CreateCubeTexture(a,b,c,d,e,f,g) +#define IDirect3DDevice9Ex_CreateVertexBuffer(p,a,b,c,d,e,f) (p)->CreateVertexBuffer(a,b,c,d,e,f) +#define IDirect3DDevice9Ex_CreateIndexBuffer(p,a,b,c,d,e,f) (p)->CreateIndexBuffer(a,b,c,d,e,f) +#define IDirect3DDevice9Ex_CreateRenderTarget(p,a,b,c,d,e,f,g,h) (p)->CreateRenderTarget(a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_CreateDepthStencilSurface(p,a,b,c,d,e,f,g,h) (p)->CreateDepthStencilSurface(a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_UpdateSurface(p,a,b,c,d) (p)->UpdateSurface(a,b,c,d) +#define IDirect3DDevice9Ex_UpdateTexture(p,a,b) (p)->UpdateTexture(a,b) +#define IDirect3DDevice9Ex_GetRenderTargetData(p,a,b) (p)->GetRenderTargetData(a,b) +#define IDirect3DDevice9Ex_GetFrontBufferData(p,a,b) (p)->GetFrontBufferData(a,b) +#define IDirect3DDevice9Ex_StretchRect(p,a,b,c,d,e) (p)->StretchRect(a,b,c,d,e) +#define IDirect3DDevice9Ex_ColorFill(p,a,b,c) (p)->ColorFill(a,b,c) +#define IDirect3DDevice9Ex_CreateOffscreenPlainSurface(p,a,b,c,d,e,f) (p)->CreateOffscreenPlainSurface(a,b,c,d,e,f) +#define IDirect3DDevice9Ex_SetRenderTarget(p,a,b) (p)->SetRenderTarget(a,b) +#define IDirect3DDevice9Ex_GetRenderTarget(p,a,b) (p)->GetRenderTarget(a,b) +#define IDirect3DDevice9Ex_SetDepthStencilSurface(p,a) (p)->SetDepthStencilSurface(a) +#define IDirect3DDevice9Ex_GetDepthStencilSurface(p,a) (p)->GetDepthStencilSurface(a) +#define IDirect3DDevice9Ex_BeginScene(p) (p)->BeginScene() +#define IDirect3DDevice9Ex_EndScene(p) (p)->EndScene() +#define IDirect3DDevice9Ex_Clear(p,a,b,c,d,e,f) (p)->Clear(a,b,c,d,e,f) +#define IDirect3DDevice9Ex_SetTransform(p,a,b) (p)->SetTransform(a,b) +#define IDirect3DDevice9Ex_GetTransform(p,a,b) (p)->GetTransform(a,b) +#define IDirect3DDevice9Ex_MultiplyTransform(p,a,b) (p)->MultiplyTransform(a,b) +#define IDirect3DDevice9Ex_SetViewport(p,a) (p)->SetViewport(a) +#define IDirect3DDevice9Ex_GetViewport(p,a) (p)->GetViewport(a) +#define IDirect3DDevice9Ex_SetMaterial(p,a) (p)->SetMaterial(a) +#define IDirect3DDevice9Ex_GetMaterial(p,a) (p)->GetMaterial(a) +#define IDirect3DDevice9Ex_SetLight(p,a,b) (p)->SetLight(a,b) +#define IDirect3DDevice9Ex_GetLight(p,a,b) (p)->GetLight(a,b) +#define IDirect3DDevice9Ex_LightEnable(p,a,b) (p)->LightEnable(a,b) +#define IDirect3DDevice9Ex_GetLightEnable(p,a,b) (p)->GetLightEnable(a,b) +#define IDirect3DDevice9Ex_SetClipPlane(p,a,b) (p)->SetClipPlane(a,b) +#define IDirect3DDevice9Ex_GetClipPlane(p,a,b) (p)->GetClipPlane(a,b) +#define IDirect3DDevice9Ex_SetRenderState(p,a,b) (p)->SetRenderState(a,b) +#define IDirect3DDevice9Ex_GetRenderState(p,a,b) (p)->GetRenderState(a,b) +#define IDirect3DDevice9Ex_CreateStateBlock(p,a,b) (p)->CreateStateBlock(a,b) +#define IDirect3DDevice9Ex_BeginStateBlock(p) (p)->BeginStateBlock() +#define IDirect3DDevice9Ex_EndStateBlock(p,a) (p)->EndStateBlock(a) +#define IDirect3DDevice9Ex_SetClipStatus(p,a) (p)->SetClipStatus(a) +#define IDirect3DDevice9Ex_GetClipStatus(p,a) (p)->GetClipStatus(a) +#define IDirect3DDevice9Ex_GetTexture(p,a,b) (p)->GetTexture(a,b) +#define IDirect3DDevice9Ex_SetTexture(p,a,b) (p)->SetTexture(a,b) +#define IDirect3DDevice9Ex_GetTextureStageState(p,a,b,c) (p)->GetTextureStageState(a,b,c) +#define IDirect3DDevice9Ex_SetTextureStageState(p,a,b,c) (p)->SetTextureStageState(a,b,c) +#define IDirect3DDevice9Ex_GetSamplerState(p,a,b,c) (p)->GetSamplerState(a,b,c) +#define IDirect3DDevice9Ex_SetSamplerState(p,a,b,c) (p)->SetSamplerState(a,b,c) +#define IDirect3DDevice9Ex_ValidateDevice(p,a) (p)->ValidateDevice(a) +#define IDirect3DDevice9Ex_SetPaletteEntries(p,a,b) (p)->SetPaletteEntries(a,b) +#define IDirect3DDevice9Ex_GetPaletteEntries(p,a,b) (p)->GetPaletteEntries(a,b) +#define IDirect3DDevice9Ex_SetCurrentTexturePalette(p,a) (p)->SetCurrentTexturePalette(a) +#define IDirect3DDevice9Ex_GetCurrentTexturePalette(p,a) (p)->GetCurrentTexturePalette(a) +#define IDirect3DDevice9Ex_SetScissorRect(p,a) (p)->SetScissorRect(a) +#define IDirect3DDevice9Ex_GetScissorRect(p,a) (p)->GetScissorRect(a) +#define IDirect3DDevice9Ex_SetSoftwareVertexProcessing(p,a) (p)->SetSoftwareVertexProcessing(a) +#define IDirect3DDevice9Ex_GetSoftwareVertexProcessing(p) (p)->GetSoftwareVertexProcessing() +#define IDirect3DDevice9Ex_SetNPatchMode(p,a) (p)->SetNPatchMode(a) +#define IDirect3DDevice9Ex_GetNPatchMode(p) (p)->GetNPatchMode() +#define IDirect3DDevice9Ex_DrawPrimitive(p,a,b,c) (p)->DrawPrimitive(a,b,c) +#define IDirect3DDevice9Ex_DrawIndexedPrimitive(p,a,b,c,d,e,f) (p)->DrawIndexedPrimitive(a,b,c,d,e,f) +#define IDirect3DDevice9Ex_DrawPrimitiveUP(p,a,b,c,d) (p)->DrawPrimitiveUP(a,b,c,d) +#define IDirect3DDevice9Ex_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->DrawIndexedPrimitiveUP(a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_ProcessVertices(p,a,b,c,d,e,f) (p)->ProcessVertices(a,b,c,d,e,f) +#define IDirect3DDevice9Ex_CreateVertexDeclaration(p,a,b) (p)->CreateVertexDeclaration(a,b) +#define IDirect3DDevice9Ex_SetVertexDeclaration(p,a) (p)->SetVertexDeclaration(a) +#define IDirect3DDevice9Ex_GetVertexDeclaration(p,a) (p)->GetVertexDeclaration(a) +#define IDirect3DDevice9Ex_SetFVF(p,a) (p)->SetFVF(a) +#define IDirect3DDevice9Ex_GetFVF(p,a) (p)->GetFVF(a) +#define IDirect3DDevice9Ex_CreateVertexShader(p,a,b) (p)->CreateVertexShader(a,b) +#define IDirect3DDevice9Ex_SetVertexShader(p,a) (p)->SetVertexShader(a) +#define IDirect3DDevice9Ex_GetVertexShader(p,a) (p)->GetVertexShader(a) +#define IDirect3DDevice9Ex_SetVertexShaderConstantF(p,a,b,c) (p)->SetVertexShaderConstantF(a,b,c) +#define IDirect3DDevice9Ex_GetVertexShaderConstantF(p,a,b,c) (p)->GetVertexShaderConstantF(a,b,c) +#define IDirect3DDevice9Ex_SetVertexShaderConstantI(p,a,b,c) (p)->SetVertexShaderConstantI(a,b,c) +#define IDirect3DDevice9Ex_GetVertexShaderConstantI(p,a,b,c) (p)->GetVertexShaderConstantI(a,b,c) +#define IDirect3DDevice9Ex_SetVertexShaderConstantB(p,a,b,c) (p)->SetVertexShaderConstantB(a,b,c) +#define IDirect3DDevice9Ex_GetVertexShaderConstantB(p,a,b,c) (p)->GetVertexShaderConstantB(a,b,c) +#define IDirect3DDevice9Ex_SetStreamSource(p,a,b,c,d) (p)->SetStreamSource(a,b,c,d) +#define IDirect3DDevice9Ex_GetStreamSource(p,a,b,c,d) (p)->GetStreamSource(a,b,c,d) +#define IDirect3DDevice9Ex_SetStreamSourceFreq(p,a,b) (p)->SetStreamSourceFreq(a,b) +#define IDirect3DDevice9Ex_GetStreamSourceFreq(p,a,b) (p)->GetStreamSourceFreq(a,b) +#define IDirect3DDevice9Ex_SetIndices(p,a) (p)->SetIndices(a) +#define IDirect3DDevice9Ex_GetIndices(p,a) (p)->GetIndices(a) +#define IDirect3DDevice9Ex_CreatePixelShader(p,a,b) (p)->CreatePixelShader(a,b) +#define IDirect3DDevice9Ex_SetPixelShader(p,a) (p)->SetPixelShader(a) +#define IDirect3DDevice9Ex_GetPixelShader(p,a) (p)->GetPixelShader(a) +#define IDirect3DDevice9Ex_SetPixelShaderConstantF(p,a,b,c) (p)->SetPixelShaderConstantF(a,b,c) +#define IDirect3DDevice9Ex_GetPixelShaderConstantF(p,a,b,c) (p)->GetPixelShaderConstantF(a,b,c) +#define IDirect3DDevice9Ex_SetPixelShaderConstantI(p,a,b,c) (p)->SetPixelShaderConstantI(a,b,c) +#define IDirect3DDevice9Ex_GetPixelShaderConstantI(p,a,b,c) (p)->GetPixelShaderConstantI(a,b,c) +#define IDirect3DDevice9Ex_SetPixelShaderConstantB(p,a,b,c) (p)->SetPixelShaderConstantB(a,b,c) +#define IDirect3DDevice9Ex_GetPixelShaderConstantB(p,a,b,c) (p)->GetPixelShaderConstantB(a,b,c) +#define IDirect3DDevice9Ex_DrawRectPatch(p,a,b,c) (p)->DrawRectPatch(a,b,c) +#define IDirect3DDevice9Ex_DrawTriPatch(p,a,b,c) (p)->DrawTriPatch(a,b,c) +#define IDirect3DDevice9Ex_DeletePatch(p,a) (p)->DeletePatch(a) +#define IDirect3DDevice9Ex_CreateQuery(p,a,b) (p)->CreateQuery(a,b) +#define IDirect3DDevice9Ex_SetConvolutionMonoKernel(p,a,b,c,d) (p)->SetConvolutionMonoKernel(a,b,c,d) +#define IDirect3DDevice9Ex_ComposeRects(p,a,b,c,d,e,f,g,h) (p)->ComposeRects(a,b,c,d,e,f,g,h) +#define IDirect3DDevice9Ex_PresentEx(p,a,b,c,d,e) (p)->PresentEx(a,b,c,d,e) +#define IDirect3DDevice9Ex_GetGPUThreadPriority(p,a) (p)->GetGPUThreadPriority(a) +#define IDirect3DDevice9Ex_SetGPUThreadPriority(p,a) (p)->SetGPUThreadPriority(a) +#define IDirect3DDevice9Ex_WaitForVBlank(p,a) (p)->WaitForVBlank(a) +#define IDirect3DDevice9Ex_CheckResourceResidency(p,a,b) (p)->CheckResourceResidency(a,b) +#define IDirect3DDevice9Ex_SetMaximumFrameLatency(p,a) (p)->SetMaximumFrameLatency(a) +#define IDirect3DDevice9Ex_GetMaximumFrameLatency(p,a) (p)->GetMaximumFrameLatency(a) +#define IDirect3DDevice9Ex_CheckDeviceState(p,a) (p)->CheckDeviceState(a) +#define IDirect3DDevice9Ex_CreateRenderTargetEx(p,a,b,c,d,e,f,g,h,i) (p)->CreateRenderTargetEx(a,b,c,d,e,f,g,h,i) +#define IDirect3DDevice9Ex_CreateOffscreenPlainSurfaceEx(p,a,b,c,d,e,f,g) (p)->CreateOffscreenPlainSurfaceEx(a,b,c,d,e,f,g) +#define IDirect3DDevice9Ex_CreateDepthStencilSurfaceEx(p,a,b,c,d,e,f,g,h,i) (p)->CreateDepthStencilSurfaceEx(a,b,c,d,e,f,g,h,i) +#define IDirect3DDevice9Ex_ResetEx(p,a,b) (p)->ResetEx(a,b) +#define IDirect3DDevice9Ex_GetDisplayModeEx(p,a,b,c) (p)->GetDisplayModeEx(a,b,c) +#endif + + + +#undef INTERFACE +#define INTERFACE IDirect3DSwapChain9Ex + +DECLARE_INTERFACE_(IDirect3DSwapChain9Ex, IDirect3DSwapChain9) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirect3DSwapChain9 methods ***/ + STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion,DWORD dwFlags) PURE; + STDMETHOD(GetFrontBufferData)(THIS_ IDirect3DSurface9* pDestSurface) PURE; + STDMETHOD(GetBackBuffer)(THIS_ UINT iBackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface9** ppBackBuffer) PURE; + STDMETHOD(GetRasterStatus)(THIS_ D3DRASTER_STATUS* pRasterStatus) PURE; + STDMETHOD(GetDisplayMode)(THIS_ D3DDISPLAYMODE* pMode) PURE; + STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; + STDMETHOD(GetPresentParameters)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters) PURE; + STDMETHOD(GetLastPresentCount)(THIS_ UINT* pLastPresentCount) PURE; + STDMETHOD(GetPresentStats)(THIS_ D3DPRESENTSTATS* pPresentationStatistics) PURE; + STDMETHOD(GetDisplayModeEx)(THIS_ D3DDISPLAYMODEEX* pMode,D3DDISPLAYROTATION* pRotation) PURE; +}; + +typedef struct IDirect3DSwapChain9Ex *LPDIRECT3DSWAPCHAIN9EX, *PDIRECT3DSWAPCHAIN9EX; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirect3DSwapChain9Ex_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirect3DSwapChain9Ex_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirect3DSwapChain9Ex_Release(p) (p)->lpVtbl->Release(p) +#define IDirect3DSwapChain9Ex_Present(p,a,b,c,d,e) (p)->lpVtbl->Present(p,a,b,c,d,e) +#define IDirect3DSwapChain9Ex_GetFrontBufferData(p,a) (p)->lpVtbl->GetFrontBufferData(p,a) +#define IDirect3DSwapChain9Ex_GetBackBuffer(p,a,b,c) (p)->lpVtbl->GetBackBuffer(p,a,b,c) +#define IDirect3DSwapChain9Ex_GetRasterStatus(p,a) (p)->lpVtbl->GetRasterStatus(p,a) +#define IDirect3DSwapChain9Ex_GetDisplayMode(p,a) (p)->lpVtbl->GetDisplayMode(p,a) +#define IDirect3DSwapChain9Ex_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) +#define IDirect3DSwapChain9Ex_GetPresentParameters(p,a) (p)->lpVtbl->GetPresentParameters(p,a) +#define IDirect3DSwapChain9Ex_GetLastPresentCount(p,a) (p)->lpVtbl->GetLastPresentCount(p,a) +#define IDirect3DSwapChain9Ex_GetPresentStats(p,a) (p)->lpVtbl->GetPresentStats(p,a) +#define IDirect3DSwapChain9Ex_GetDisplayModeEx(p,a,b) (p)->lpVtbl->GetDisplayModeEx(p,a,b) +#else +#define IDirect3DSwapChain9Ex_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirect3DSwapChain9Ex_AddRef(p) (p)->AddRef() +#define IDirect3DSwapChain9Ex_Release(p) (p)->Release() +#define IDirect3DSwapChain9Ex_Present(p,a,b,c,d,e) (p)->Present(a,b,c,d,e) +#define IDirect3DSwapChain9Ex_GetFrontBufferData(p,a) (p)->GetFrontBufferData(a) +#define IDirect3DSwapChain9Ex_GetBackBuffer(p,a,b,c) (p)->GetBackBuffer(a,b,c) +#define IDirect3DSwapChain9Ex_GetRasterStatus(p,a) (p)->GetRasterStatus(a) +#define IDirect3DSwapChain9Ex_GetDisplayMode(p,a) (p)->GetDisplayMode(a) +#define IDirect3DSwapChain9Ex_GetDevice(p,a) (p)->GetDevice(a) +#define IDirect3DSwapChain9Ex_GetPresentParameters(p,a) (p)->GetPresentParameters(a) +#define IDirect3DSwapChain9Ex_GetLastPresentCount(p,a) (p)->GetLastPresentCount(a) +#define IDirect3DSwapChain9Ex_GetPresentStats(p,a) (p)->GetPresentStats(a) +#define IDirect3DSwapChain9Ex_GetDisplayModeEx(p,a,b) (p)->GetDisplayModeEx(a,b) +#endif + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + + + +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + + + +#undef INTERFACE +#define INTERFACE IDirect3D9ExOverlayExtension + +DECLARE_INTERFACE_(IDirect3D9ExOverlayExtension, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirect3D9ExOverlayExtension methods ***/ + STDMETHOD(CheckDeviceOverlayType)(THIS_ UINT Adapter,D3DDEVTYPE DevType,UINT OverlayWidth,UINT OverlayHeight,D3DFORMAT OverlayFormat,D3DDISPLAYMODEEX* pDisplayMode,D3DDISPLAYROTATION DisplayRotation,D3DOVERLAYCAPS* pOverlayCaps) PURE; +}; + +typedef struct IDirect3D9ExOverlayExtension *LPDIRECT3D9EXOVERLAYEXTENSION, *PDIRECT3D9EXOVERLAYEXTENSION; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirect3D9ExOverlayExtension_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirect3D9ExOverlayExtension_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirect3D9ExOverlayExtension_Release(p) (p)->lpVtbl->Release(p) +#define IDirect3D9ExOverlayExtension_CheckDeviceOverlayType(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CheckDeviceOverlayType(p,a,b,c,d,e,f,g,h) +#else +#define IDirect3D9ExOverlayExtension_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirect3D9ExOverlayExtension_AddRef(p) (p)->AddRef() +#define IDirect3D9ExOverlayExtension_Release(p) (p)->Release() +#define IDirect3D9ExOverlayExtension_CheckDeviceOverlayType(p,a,b,c,d,e,f,g,h) (p)->CheckDeviceOverlayType(a,b,c,d,e,f,g,h) +#endif + + + +#undef INTERFACE +#define INTERFACE IDirect3DDevice9Video + +DECLARE_INTERFACE_(IDirect3DDevice9Video, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirect3DDevice9Video methods ***/ + STDMETHOD(GetContentProtectionCaps)(THIS_ CONST GUID* pCryptoType,CONST GUID* pDecodeProfile,D3DCONTENTPROTECTIONCAPS* pCaps) PURE; + STDMETHOD(CreateAuthenticatedChannel)(THIS_ D3DAUTHENTICATEDCHANNELTYPE ChannelType,IDirect3DAuthenticatedChannel9** ppAuthenticatedChannel,HANDLE* pChannelHandle) PURE; + STDMETHOD(CreateCryptoSession)(THIS_ CONST GUID* pCryptoType,CONST GUID* pDecodeProfile,IDirect3DCryptoSession9** ppCryptoSession,HANDLE* pCryptoHandle) PURE; +}; + +typedef struct IDirect3DDevice9Video *LPDIRECT3DDEVICE9VIDEO, *PDIRECT3DDEVICE9VIDEO; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirect3DDevice9Video_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirect3DDevice9Video_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirect3DDevice9Video_Release(p) (p)->lpVtbl->Release(p) +#define IDirect3DDevice9Video_GetContentProtectionCaps(p,a,b,c) (p)->lpVtbl->GetContentProtectionCaps(p,a,b,c) +#define IDirect3DDevice9Video_CreateAuthenticatedChannel(p,a,b,c) (p)->lpVtbl->CreateAuthenticatedChannel(p,a,b,c) +#define IDirect3DDevice9Video_CreateCryptoSession(p,a,b,c,d) (p)->lpVtbl->CreateCryptoSession(p,a,b,c,d) +#else +#define IDirect3DDevice9Video_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirect3DDevice9Video_AddRef(p) (p)->AddRef() +#define IDirect3DDevice9Video_Release(p) (p)->Release() +#define IDirect3DDevice9Video_GetContentProtectionCaps(p,a,b,c) (p)->GetContentProtectionCaps(a,b,c) +#define IDirect3DDevice9Video_CreateAuthenticatedChannel(p,a,b,c) (p)->CreateAuthenticatedChannel(a,b,c) +#define IDirect3DDevice9Video_CreateCryptoSession(p,a,b,c,d) (p)->CreateCryptoSession(a,b,c,d) +#endif + + + + +#undef INTERFACE +#define INTERFACE IDirect3DAuthenticatedChannel9 + +DECLARE_INTERFACE_(IDirect3DAuthenticatedChannel9, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirect3DAuthenticatedChannel9 methods ***/ + STDMETHOD(GetCertificateSize)(THIS_ UINT* pCertificateSize) PURE; + STDMETHOD(GetCertificate)(THIS_ UINT CertifacteSize,BYTE* ppCertificate) PURE; + STDMETHOD(NegotiateKeyExchange)(THIS_ UINT DataSize,VOID* pData) PURE; + STDMETHOD(Query)(THIS_ UINT InputSize,CONST VOID* pInput,UINT OutputSize,VOID* pOutput) PURE; + STDMETHOD(Configure)(THIS_ UINT InputSize,CONST VOID* pInput,D3DAUTHENTICATEDCHANNEL_CONFIGURE_OUTPUT* pOutput) PURE; +}; + +typedef struct IDirect3DAuthenticatedChannel9 *LPDIRECT3DAUTHENTICATEDCHANNEL9, *PDIRECT3DAUTHENTICATEDCHANNEL9; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirect3DAuthenticatedChannel9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirect3DAuthenticatedChannel9_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirect3DAuthenticatedChannel9_Release(p) (p)->lpVtbl->Release(p) +#define IDirect3DAuthenticatedChannel9_GetCertificateSize(p,a) (p)->lpVtbl->GetCertificateSize(p,a) +#define IDirect3DAuthenticatedChannel9_GetCertificate(p,a,b) (p)->lpVtbl->GetCertificate(p,a,b) +#define IDirect3DAuthenticatedChannel9_NegotiateKeyExchange(p,a,b) (p)->lpVtbl->NegotiateKeyExchange(p,a,b) +#define IDirect3DAuthenticatedChannel9_Query(p,a,b,c,d) (p)->lpVtbl->Query(p,a,b,c,d) +#define IDirect3DAuthenticatedChannel9_Configure(p,a,b,c) (p)->lpVtbl->Configure(p,a,b,c) +#else +#define IDirect3DAuthenticatedChannel9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirect3DAuthenticatedChannel9_AddRef(p) (p)->AddRef() +#define IDirect3DAuthenticatedChannel9_Release(p) (p)->Release() +#define IDirect3DAuthenticatedChannel9_GetCertificateSize(p,a) (p)->GetCertificateSize(a) +#define IDirect3DAuthenticatedChannel9_GetCertificate(p,a,b) (p)->GetCertificate(a,b) +#define IDirect3DAuthenticatedChannel9_NegotiateKeyExchange(p,a,b) (p)->NegotiateKeyExchange(a,b) +#define IDirect3DAuthenticatedChannel9_Query(p,a,b,c,d) (p)->Query(a,b,c,d) +#define IDirect3DAuthenticatedChannel9_Configure(p,a,b,c) (p)->Configure(a,b,c) +#endif + + + +#undef INTERFACE +#define INTERFACE IDirect3DCryptoSession9 + +DECLARE_INTERFACE_(IDirect3DCryptoSession9, IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + + /*** IDirect3DCryptoSession9 methods ***/ + STDMETHOD(GetCertificateSize)(THIS_ UINT* pCertificateSize) PURE; + STDMETHOD(GetCertificate)(THIS_ UINT CertifacteSize,BYTE* ppCertificate) PURE; + STDMETHOD(NegotiateKeyExchange)(THIS_ UINT DataSize,VOID* pData) PURE; + STDMETHOD(EncryptionBlt)(THIS_ IDirect3DSurface9* pSrcSurface,IDirect3DSurface9* pDstSurface,UINT DstSurfaceSize,VOID* pIV) PURE; + STDMETHOD(DecryptionBlt)(THIS_ IDirect3DSurface9* pSrcSurface,IDirect3DSurface9* pDstSurface,UINT SrcSurfaceSize,D3DENCRYPTED_BLOCK_INFO* pEncryptedBlockInfo,VOID* pContentKey,VOID* pIV) PURE; + STDMETHOD(GetSurfacePitch)(THIS_ IDirect3DSurface9* pSrcSurface,UINT* pSurfacePitch) PURE; + STDMETHOD(StartSessionKeyRefresh)(THIS_ VOID* pRandomNumber,UINT RandomNumberSize) PURE; + STDMETHOD(FinishSessionKeyRefresh)(THIS) PURE; + STDMETHOD(GetEncryptionBltKey)(THIS_ VOID* pReadbackKey,UINT KeySize) PURE; +}; + +typedef struct IDirect3DCryptoSession9 *LPDIRECT3DCRYPTOSESSION9, *PDIRECT3DCRYPTOSESSION9; + +#if !defined(__cplusplus) || defined(CINTERFACE) +#define IDirect3DCryptoSession9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define IDirect3DCryptoSession9_AddRef(p) (p)->lpVtbl->AddRef(p) +#define IDirect3DCryptoSession9_Release(p) (p)->lpVtbl->Release(p) +#define IDirect3DCryptoSession9_GetCertificateSize(p,a) (p)->lpVtbl->GetCertificateSize(p,a) +#define IDirect3DCryptoSession9_GetCertificate(p,a,b) (p)->lpVtbl->GetCertificate(p,a,b) +#define IDirect3DCryptoSession9_NegotiateKeyExchange(p,a,b) (p)->lpVtbl->NegotiateKeyExchange(p,a,b) +#define IDirect3DCryptoSession9_EncryptionBlt(p,a,b,c,d) (p)->lpVtbl->EncryptionBlt(p,a,b,c,d) +#define IDirect3DCryptoSession9_DecryptionBlt(p,a,b,c,d,e,f) (p)->lpVtbl->DecryptionBlt(p,a,b,c,d,e,f) +#define IDirect3DCryptoSession9_GetSurfacePitch(p,a,b) (p)->lpVtbl->GetSurfacePitch(p,a,b) +#define IDirect3DCryptoSession9_StartSessionKeyRefresh(p,a,b) (p)->lpVtbl->StartSessionKeyRefresh(p,a,b) +#define IDirect3DCryptoSession9_FinishSessionKeyRefresh(p) (p)->lpVtbl->FinishSessionKeyRefresh(p) +#define IDirect3DCryptoSession9_GetEncryptionBltKey(p,a,b) (p)->lpVtbl->GetEncryptionBltKey(p,a,b) +#else +#define IDirect3DCryptoSession9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) +#define IDirect3DCryptoSession9_AddRef(p) (p)->AddRef() +#define IDirect3DCryptoSession9_Release(p) (p)->Release() +#define IDirect3DCryptoSession9_GetCertificateSize(p,a) (p)->GetCertificateSize(a) +#define IDirect3DCryptoSession9_GetCertificate(p,a,b) (p)->GetCertificate(a,b) +#define IDirect3DCryptoSession9_NegotiateKeyExchange(p,a,b) (p)->NegotiateKeyExchange(a,b) +#define IDirect3DCryptoSession9_EncryptionBlt(p,a,b,c,d) (p)->EncryptionBlt(a,b,c,d) +#define IDirect3DCryptoSession9_DecryptionBlt(p,a,b,c,d,e,f) (p)->DecryptionBlt(a,b,c,d,e,f) +#define IDirect3DCryptoSession9_GetSurfacePitch(p,a,b) (p)->GetSurfacePitch(a,b) +#define IDirect3DCryptoSession9_StartSessionKeyRefresh(p,a,b) (p)->StartSessionKeyRefresh(a,b) +#define IDirect3DCryptoSession9_FinishSessionKeyRefresh(p) (p)->FinishSessionKeyRefresh() +#define IDirect3DCryptoSession9_GetEncryptionBltKey(p,a,b) (p)->GetEncryptionBltKey(a,b) +#endif + +/* -- D3D9Ex only */ +#endif // !D3D_DISABLE_9EX + #ifdef __cplusplus }; diff --git a/Include/d3d9.txt b/Include/d3d9.txt deleted file mode 100644 index 300c725..0000000 --- a/Include/d3d9.txt +++ /dev/null @@ -1,1870 +0,0 @@ -/*==========================================================================; - * - * Copyright (C) Microsoft Corporation. All Rights Reserved. - * - * File: d3d9.h - * Content: Direct3D include file - * - ****************************************************************************/ - -#ifndef _D3D9_H_ -#define _D3D9_H_ - -#ifndef DIRECT3D_VERSION -#define DIRECT3D_VERSION 0x0900 -#endif //DIRECT3D_VERSION - -// include this file content only if compiling for DX9 interfaces -#if(DIRECT3D_VERSION >= 0x0900) - - -/* This identifier is passed to Direct3DCreate9 in order to ensure that an - * application was built against the correct header files. This number is - * incremented whenever a header (or other) change would require applications - * to be rebuilt. If the version doesn't match, Direct3DCreate9 will fail. - * (The number itself has no meaning.)*/ - -#ifdef D3D_DEBUG_INFO -#define D3D_SDK_VERSION (32 | 0x80000000) -#define D3D9b_SDK_VERSION (31 | 0x80000000) - -#else -#define D3D_SDK_VERSION 32 -#define D3D9b_SDK_VERSION 31 -#endif - - -#include - -#define COM_NO_WINDOWS_H -#include - -#include - -#if !defined(HMONITOR_DECLARED) && (WINVER < 0x0500) - #define HMONITOR_DECLARED - DECLARE_HANDLE(HMONITOR); -#endif - -#define D3DAPI WINAPI - -/* - * Interface IID's - */ -#if defined( _WIN32 ) && !defined( _NO_COM) - -/* IID_IDirect3D9 */ -/* {81BDCBCA-64D4-426d-AE8D-AD0147F4275C} */ -DEFINE_GUID(IID_IDirect3D9, 0x81bdcbca, 0x64d4, 0x426d, 0xae, 0x8d, 0xad, 0x1, 0x47, 0xf4, 0x27, 0x5c); - -/* IID_IDirect3DDevice9 */ -// {D0223B96-BF7A-43fd-92BD-A43B0D82B9EB} */ -DEFINE_GUID(IID_IDirect3DDevice9, 0xd0223b96, 0xbf7a, 0x43fd, 0x92, 0xbd, 0xa4, 0x3b, 0xd, 0x82, 0xb9, 0xeb); - -/* IID_IDirect3DResource9 */ -// {05EEC05D-8F7D-4362-B999-D1BAF357C704} -DEFINE_GUID(IID_IDirect3DResource9, 0x5eec05d, 0x8f7d, 0x4362, 0xb9, 0x99, 0xd1, 0xba, 0xf3, 0x57, 0xc7, 0x4); - -/* IID_IDirect3DBaseTexture9 */ -/* {580CA87E-1D3C-4d54-991D-B7D3E3C298CE} */ -DEFINE_GUID(IID_IDirect3DBaseTexture9, 0x580ca87e, 0x1d3c, 0x4d54, 0x99, 0x1d, 0xb7, 0xd3, 0xe3, 0xc2, 0x98, 0xce); - -/* IID_IDirect3DTexture9 */ -/* {85C31227-3DE5-4f00-9B3A-F11AC38C18B5} */ -DEFINE_GUID(IID_IDirect3DTexture9, 0x85c31227, 0x3de5, 0x4f00, 0x9b, 0x3a, 0xf1, 0x1a, 0xc3, 0x8c, 0x18, 0xb5); - -/* IID_IDirect3DCubeTexture9 */ -/* {FFF32F81-D953-473a-9223-93D652ABA93F} */ -DEFINE_GUID(IID_IDirect3DCubeTexture9, 0xfff32f81, 0xd953, 0x473a, 0x92, 0x23, 0x93, 0xd6, 0x52, 0xab, 0xa9, 0x3f); - -/* IID_IDirect3DVolumeTexture9 */ -/* {2518526C-E789-4111-A7B9-47EF328D13E6} */ -DEFINE_GUID(IID_IDirect3DVolumeTexture9, 0x2518526c, 0xe789, 0x4111, 0xa7, 0xb9, 0x47, 0xef, 0x32, 0x8d, 0x13, 0xe6); - -/* IID_IDirect3DVertexBuffer9 */ -/* {B64BB1B5-FD70-4df6-BF91-19D0A12455E3} */ -DEFINE_GUID(IID_IDirect3DVertexBuffer9, 0xb64bb1b5, 0xfd70, 0x4df6, 0xbf, 0x91, 0x19, 0xd0, 0xa1, 0x24, 0x55, 0xe3); - -/* IID_IDirect3DIndexBuffer9 */ -/* {7C9DD65E-D3F7-4529-ACEE-785830ACDE35} */ -DEFINE_GUID(IID_IDirect3DIndexBuffer9, 0x7c9dd65e, 0xd3f7, 0x4529, 0xac, 0xee, 0x78, 0x58, 0x30, 0xac, 0xde, 0x35); - -/* IID_IDirect3DSurface9 */ -/* {0CFBAF3A-9FF6-429a-99B3-A2796AF8B89B} */ -DEFINE_GUID(IID_IDirect3DSurface9, 0xcfbaf3a, 0x9ff6, 0x429a, 0x99, 0xb3, 0xa2, 0x79, 0x6a, 0xf8, 0xb8, 0x9b); - -/* IID_IDirect3DVolume9 */ -/* {24F416E6-1F67-4aa7-B88E-D33F6F3128A1} */ -DEFINE_GUID(IID_IDirect3DVolume9, 0x24f416e6, 0x1f67, 0x4aa7, 0xb8, 0x8e, 0xd3, 0x3f, 0x6f, 0x31, 0x28, 0xa1); - -/* IID_IDirect3DSwapChain9 */ -/* {794950F2-ADFC-458a-905E-10A10B0B503B} */ -DEFINE_GUID(IID_IDirect3DSwapChain9, 0x794950f2, 0xadfc, 0x458a, 0x90, 0x5e, 0x10, 0xa1, 0xb, 0xb, 0x50, 0x3b); - -/* IID_IDirect3DVertexDeclaration9 */ -/* {DD13C59C-36FA-4098-A8FB-C7ED39DC8546} */ -DEFINE_GUID(IID_IDirect3DVertexDeclaration9, 0xdd13c59c, 0x36fa, 0x4098, 0xa8, 0xfb, 0xc7, 0xed, 0x39, 0xdc, 0x85, 0x46); - -/* IID_IDirect3DVertexShader9 */ -/* {EFC5557E-6265-4613-8A94-43857889EB36} */ -DEFINE_GUID(IID_IDirect3DVertexShader9, 0xefc5557e, 0x6265, 0x4613, 0x8a, 0x94, 0x43, 0x85, 0x78, 0x89, 0xeb, 0x36); - -/* IID_IDirect3DPixelShader9 */ -/* {6D3BDBDC-5B02-4415-B852-CE5E8BCCB289} */ -DEFINE_GUID(IID_IDirect3DPixelShader9, 0x6d3bdbdc, 0x5b02, 0x4415, 0xb8, 0x52, 0xce, 0x5e, 0x8b, 0xcc, 0xb2, 0x89); - -/* IID_IDirect3DStateBlock9 */ -/* {B07C4FE5-310D-4ba8-A23C-4F0F206F218B} */ -DEFINE_GUID(IID_IDirect3DStateBlock9, 0xb07c4fe5, 0x310d, 0x4ba8, 0xa2, 0x3c, 0x4f, 0xf, 0x20, 0x6f, 0x21, 0x8b); - -/* IID_IDirect3DQuery9 */ -/* {d9771460-a695-4f26-bbd3-27b840b541cc} */ -DEFINE_GUID(IID_IDirect3DQuery9, 0xd9771460, 0xa695, 0x4f26, 0xbb, 0xd3, 0x27, 0xb8, 0x40, 0xb5, 0x41, 0xcc); - - -/* IID_HelperName */ -/* {E4A36723-FDFE-4b22-B146-3C04C07F4CC8} */ -DEFINE_GUID(IID_HelperName, 0xe4a36723, 0xfdfe, 0x4b22, 0xb1, 0x46, 0x3c, 0x4, 0xc0, 0x7f, 0x4c, 0xc8); - - -#endif - -#ifdef __cplusplus - -#ifndef DECLSPEC_UUID -#if _MSC_VER >= 1100 -#define DECLSPEC_UUID(x) __declspec(uuid(x)) -#else -#define DECLSPEC_UUID(x) -#endif -#endif - -interface DECLSPEC_UUID("81BDCBCA-64D4-426d-AE8D-AD0147F4275C") IDirect3D9; -interface DECLSPEC_UUID("D0223B96-BF7A-43fd-92BD-A43B0D82B9EB") IDirect3DDevice9; - -interface DECLSPEC_UUID("B07C4FE5-310D-4ba8-A23C-4F0F206F218B") IDirect3DStateBlock9; -interface DECLSPEC_UUID("05EEC05D-8F7D-4362-B999-D1BAF357C704") IDirect3DResource9; -interface DECLSPEC_UUID("DD13C59C-36FA-4098-A8FB-C7ED39DC8546") IDirect3DVertexDeclaration9; -interface DECLSPEC_UUID("EFC5557E-6265-4613-8A94-43857889EB36") IDirect3DVertexShader9; -interface DECLSPEC_UUID("6D3BDBDC-5B02-4415-B852-CE5E8BCCB289") IDirect3DPixelShader9; -interface DECLSPEC_UUID("580CA87E-1D3C-4d54-991D-B7D3E3C298CE") IDirect3DBaseTexture9; -interface DECLSPEC_UUID("85C31227-3DE5-4f00-9B3A-F11AC38C18B5") IDirect3DTexture9; -interface DECLSPEC_UUID("2518526C-E789-4111-A7B9-47EF328D13E6") IDirect3DVolumeTexture9; -interface DECLSPEC_UUID("FFF32F81-D953-473a-9223-93D652ABA93F") IDirect3DCubeTexture9; - -interface DECLSPEC_UUID("B64BB1B5-FD70-4df6-BF91-19D0A12455E3") IDirect3DVertexBuffer9; -interface DECLSPEC_UUID("7C9DD65E-D3F7-4529-ACEE-785830ACDE35") IDirect3DIndexBuffer9; - -interface DECLSPEC_UUID("0CFBAF3A-9FF6-429a-99B3-A2796AF8B89B") IDirect3DSurface9; -interface DECLSPEC_UUID("24F416E6-1F67-4aa7-B88E-D33F6F3128A1") IDirect3DVolume9; - -interface DECLSPEC_UUID("794950F2-ADFC-458a-905E-10A10B0B503B") IDirect3DSwapChain9; -interface DECLSPEC_UUID("d9771460-a695-4f26-bbd3-27b840b541cc") IDirect3DQuery9; - - -#if defined(_COM_SMARTPTR_TYPEDEF) -_COM_SMARTPTR_TYPEDEF(IDirect3D9, __uuidof(IDirect3D9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DDevice9, __uuidof(IDirect3DDevice9)); - -_COM_SMARTPTR_TYPEDEF(IDirect3DStateBlock9, __uuidof(IDirect3DStateBlock9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DResource9, __uuidof(IDirect3DResource9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DVertexDeclaration9, __uuidof(IDirect3DVertexDeclaration9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DVertexShader9, __uuidof(IDirect3DVertexShader9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DPixelShader9, __uuidof(IDirect3DPixelShader9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DBaseTexture9, __uuidof(IDirect3DBaseTexture9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DTexture9, __uuidof(IDirect3DTexture9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DVolumeTexture9, __uuidof(IDirect3DVolumeTexture9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DCubeTexture9, __uuidof(IDirect3DCubeTexture9)); - -_COM_SMARTPTR_TYPEDEF(IDirect3DVertexBuffer9, __uuidof(IDirect3DVertexBuffer9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DIndexBuffer9, __uuidof(IDirect3DIndexBuffer9)); - -_COM_SMARTPTR_TYPEDEF(IDirect3DSurface9, __uuidof(IDirect3DSurface9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DVolume9, __uuidof(IDirect3DVolume9)); - -_COM_SMARTPTR_TYPEDEF(IDirect3DSwapChain9, __uuidof(IDirect3DSwapChain9)); -_COM_SMARTPTR_TYPEDEF(IDirect3DQuery9, __uuidof(IDirect3DQuery9)); - -#endif -#endif - - -typedef interface IDirect3D9 IDirect3D9; -typedef interface IDirect3DDevice9 IDirect3DDevice9; -typedef interface IDirect3DStateBlock9 IDirect3DStateBlock9; -typedef interface IDirect3DVertexDeclaration9 IDirect3DVertexDeclaration9; -typedef interface IDirect3DVertexShader9 IDirect3DVertexShader9; -typedef interface IDirect3DPixelShader9 IDirect3DPixelShader9; -typedef interface IDirect3DResource9 IDirect3DResource9; -typedef interface IDirect3DBaseTexture9 IDirect3DBaseTexture9; -typedef interface IDirect3DTexture9 IDirect3DTexture9; -typedef interface IDirect3DVolumeTexture9 IDirect3DVolumeTexture9; -typedef interface IDirect3DCubeTexture9 IDirect3DCubeTexture9; -typedef interface IDirect3DVertexBuffer9 IDirect3DVertexBuffer9; -typedef interface IDirect3DIndexBuffer9 IDirect3DIndexBuffer9; -typedef interface IDirect3DSurface9 IDirect3DSurface9; -typedef interface IDirect3DVolume9 IDirect3DVolume9; -typedef interface IDirect3DSwapChain9 IDirect3DSwapChain9; -typedef interface IDirect3DQuery9 IDirect3DQuery9; - - -#include "d3d9types.h" -#include "d3d9caps.h" - - -#ifdef __cplusplus -extern "C" { -#endif - -/* - * DLL Function for creating a Direct3D9 object. This object supports - * enumeration and allows the creation of Direct3DDevice9 objects. - * Pass the value of the constant D3D_SDK_VERSION to this function, so - * that the run-time can validate that your application was compiled - * against the right headers. - */ - -IDirect3D9 * WINAPI Direct3DCreate9(UINT SDKVersion); - -/* - * Stubs for graphics profiling. - */ - -int WINAPI D3DPERF_BeginEvent( D3DCOLOR col, LPCWSTR wszName ); -int WINAPI D3DPERF_EndEvent( void ); -void WINAPI D3DPERF_SetMarker( D3DCOLOR col, LPCWSTR wszName ); -void WINAPI D3DPERF_SetRegion( D3DCOLOR col, LPCWSTR wszName ); -BOOL WINAPI D3DPERF_QueryRepeatFrame( void ); - -void WINAPI D3DPERF_SetOptions( DWORD dwOptions ); -DWORD WINAPI D3DPERF_GetStatus( void ); - -/* - * Direct3D interfaces - */ - - - - - - -#undef INTERFACE -#define INTERFACE IDirect3D9 - -DECLARE_INTERFACE_(IDirect3D9, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3D9 methods ***/ - STDMETHOD(RegisterSoftwareDevice)(THIS_ void* pInitializeFunction) PURE; - STDMETHOD_(UINT, GetAdapterCount)(THIS) PURE; - STDMETHOD(GetAdapterIdentifier)(THIS_ UINT Adapter,DWORD Flags,D3DADAPTER_IDENTIFIER9* pIdentifier) PURE; - STDMETHOD_(UINT, GetAdapterModeCount)(THIS_ UINT Adapter,D3DFORMAT Format) PURE; - STDMETHOD(EnumAdapterModes)(THIS_ UINT Adapter,D3DFORMAT Format,UINT Mode,D3DDISPLAYMODE* pMode) PURE; - STDMETHOD(GetAdapterDisplayMode)(THIS_ UINT Adapter,D3DDISPLAYMODE* pMode) PURE; - STDMETHOD(CheckDeviceType)(THIS_ UINT Adapter,D3DDEVTYPE DevType,D3DFORMAT AdapterFormat,D3DFORMAT BackBufferFormat,BOOL bWindowed) PURE; - STDMETHOD(CheckDeviceFormat)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,DWORD Usage,D3DRESOURCETYPE RType,D3DFORMAT CheckFormat) PURE; - STDMETHOD(CheckDeviceMultiSampleType)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT SurfaceFormat,BOOL Windowed,D3DMULTISAMPLE_TYPE MultiSampleType,DWORD* pQualityLevels) PURE; - STDMETHOD(CheckDepthStencilMatch)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT AdapterFormat,D3DFORMAT RenderTargetFormat,D3DFORMAT DepthStencilFormat) PURE; - STDMETHOD(CheckDeviceFormatConversion)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DFORMAT SourceFormat,D3DFORMAT TargetFormat) PURE; - STDMETHOD(GetDeviceCaps)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,D3DCAPS9* pCaps) PURE; - STDMETHOD_(HMONITOR, GetAdapterMonitor)(THIS_ UINT Adapter) PURE; - STDMETHOD(CreateDevice)(THIS_ UINT Adapter,D3DDEVTYPE DeviceType,HWND hFocusWindow,DWORD BehaviorFlags,D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DDevice9** ppReturnedDeviceInterface) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR Version; - #endif -}; - -typedef struct IDirect3D9 *LPDIRECT3D9, *PDIRECT3D9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3D9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3D9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3D9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3D9_RegisterSoftwareDevice(p,a) (p)->lpVtbl->RegisterSoftwareDevice(p,a) -#define IDirect3D9_GetAdapterCount(p) (p)->lpVtbl->GetAdapterCount(p) -#define IDirect3D9_GetAdapterIdentifier(p,a,b,c) (p)->lpVtbl->GetAdapterIdentifier(p,a,b,c) -#define IDirect3D9_GetAdapterModeCount(p,a,b) (p)->lpVtbl->GetAdapterModeCount(p,a,b) -#define IDirect3D9_EnumAdapterModes(p,a,b,c,d) (p)->lpVtbl->EnumAdapterModes(p,a,b,c,d) -#define IDirect3D9_GetAdapterDisplayMode(p,a,b) (p)->lpVtbl->GetAdapterDisplayMode(p,a,b) -#define IDirect3D9_CheckDeviceType(p,a,b,c,d,e) (p)->lpVtbl->CheckDeviceType(p,a,b,c,d,e) -#define IDirect3D9_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceFormat(p,a,b,c,d,e,f) -#define IDirect3D9_CheckDeviceMultiSampleType(p,a,b,c,d,e,f) (p)->lpVtbl->CheckDeviceMultiSampleType(p,a,b,c,d,e,f) -#define IDirect3D9_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->lpVtbl->CheckDepthStencilMatch(p,a,b,c,d,e) -#define IDirect3D9_CheckDeviceFormatConversion(p,a,b,c,d) (p)->lpVtbl->CheckDeviceFormatConversion(p,a,b,c,d) -#define IDirect3D9_GetDeviceCaps(p,a,b,c) (p)->lpVtbl->GetDeviceCaps(p,a,b,c) -#define IDirect3D9_GetAdapterMonitor(p,a) (p)->lpVtbl->GetAdapterMonitor(p,a) -#define IDirect3D9_CreateDevice(p,a,b,c,d,e,f) (p)->lpVtbl->CreateDevice(p,a,b,c,d,e,f) -#else -#define IDirect3D9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3D9_AddRef(p) (p)->AddRef() -#define IDirect3D9_Release(p) (p)->Release() -#define IDirect3D9_RegisterSoftwareDevice(p,a) (p)->RegisterSoftwareDevice(a) -#define IDirect3D9_GetAdapterCount(p) (p)->GetAdapterCount() -#define IDirect3D9_GetAdapterIdentifier(p,a,b,c) (p)->GetAdapterIdentifier(a,b,c) -#define IDirect3D9_GetAdapterModeCount(p,a,b) (p)->GetAdapterModeCount(a,b) -#define IDirect3D9_EnumAdapterModes(p,a,b,c,d) (p)->EnumAdapterModes(a,b,c,d) -#define IDirect3D9_GetAdapterDisplayMode(p,a,b) (p)->GetAdapterDisplayMode(a,b) -#define IDirect3D9_CheckDeviceType(p,a,b,c,d,e) (p)->CheckDeviceType(a,b,c,d,e) -#define IDirect3D9_CheckDeviceFormat(p,a,b,c,d,e,f) (p)->CheckDeviceFormat(a,b,c,d,e,f) -#define IDirect3D9_CheckDeviceMultiSampleType(p,a,b,c,d,e,f) (p)->CheckDeviceMultiSampleType(a,b,c,d,e,f) -#define IDirect3D9_CheckDepthStencilMatch(p,a,b,c,d,e) (p)->CheckDepthStencilMatch(a,b,c,d,e) -#define IDirect3D9_CheckDeviceFormatConversion(p,a,b,c,d) (p)->CheckDeviceFormatConversion(a,b,c,d) -#define IDirect3D9_GetDeviceCaps(p,a,b,c) (p)->GetDeviceCaps(a,b,c) -#define IDirect3D9_GetAdapterMonitor(p,a) (p)->GetAdapterMonitor(a) -#define IDirect3D9_CreateDevice(p,a,b,c,d,e,f) (p)->CreateDevice(a,b,c,d,e,f) -#endif - - - - - - - -/* SwapChain */ - - - - - - - - - - - - - - - -#undef INTERFACE -#define INTERFACE IDirect3DDevice9 - -DECLARE_INTERFACE_(IDirect3DDevice9, IUnknown) -{ - /*** IUnknown methods ***/ -0 STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DDevice9 methods ***/ - STDMETHOD(TestCooperativeLevel)(THIS) PURE; - STDMETHOD_(UINT, GetAvailableTextureMem)(THIS) PURE; - STDMETHOD(EvictManagedResources)(THIS) PURE; - STDMETHOD(GetDirect3D)(THIS_ IDirect3D9** ppD3D9) PURE; - STDMETHOD(GetDeviceCaps)(THIS_ D3DCAPS9* pCaps) PURE; - STDMETHOD(GetDisplayMode)(THIS_ UINT iSwapChain,D3DDISPLAYMODE* pMode) PURE; - STDMETHOD(GetCreationParameters)(THIS_ D3DDEVICE_CREATION_PARAMETERS *pParameters) PURE; -10 STDMETHOD(SetCursorProperties)(THIS_ UINT XHotSpot,UINT YHotSpot,IDirect3DSurface9* pCursorBitmap) PURE; - STDMETHOD_(void, SetCursorPosition)(THIS_ int X,int Y,DWORD Flags) PURE; - STDMETHOD_(BOOL, ShowCursor)(THIS_ BOOL bShow) PURE; - STDMETHOD(CreateAdditionalSwapChain)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters,IDirect3DSwapChain9** pSwapChain) PURE; - STDMETHOD(GetSwapChain)(THIS_ UINT iSwapChain,IDirect3DSwapChain9** pSwapChain) PURE; - STDMETHOD_(UINT, GetNumberOfSwapChains)(THIS) PURE; - STDMETHOD(Reset)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters) PURE; - STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion) PURE; - STDMETHOD(GetBackBuffer)(THIS_ UINT iSwapChain,UINT iBackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface9** ppBackBuffer) PURE; - STDMETHOD(GetRasterStatus)(THIS_ UINT iSwapChain,D3DRASTER_STATUS* pRasterStatus) PURE; -20 STDMETHOD(SetDialogBoxMode)(THIS_ BOOL bEnableDialogs) PURE; - STDMETHOD_(void, SetGammaRamp)(THIS_ UINT iSwapChain,DWORD Flags,CONST D3DGAMMARAMP* pRamp) PURE; - STDMETHOD_(void, GetGammaRamp)(THIS_ UINT iSwapChain,D3DGAMMARAMP* pRamp) PURE; - STDMETHOD(CreateTexture)(THIS_ UINT Width,UINT Height,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DTexture9** ppTexture,HANDLE* pSharedHandle) PURE; - STDMETHOD(CreateVolumeTexture)(THIS_ UINT Width,UINT Height,UINT Depth,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DVolumeTexture9** ppVolumeTexture,HANDLE* pSharedHandle) PURE; - STDMETHOD(CreateCubeTexture)(THIS_ UINT EdgeLength,UINT Levels,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DCubeTexture9** ppCubeTexture,HANDLE* pSharedHandle) PURE; - STDMETHOD(CreateVertexBuffer)(THIS_ UINT Length,DWORD Usage,DWORD FVF,D3DPOOL Pool,IDirect3DVertexBuffer9** ppVertexBuffer,HANDLE* pSharedHandle) PURE; - STDMETHOD(CreateIndexBuffer)(THIS_ UINT Length,DWORD Usage,D3DFORMAT Format,D3DPOOL Pool,IDirect3DIndexBuffer9** ppIndexBuffer,HANDLE* pSharedHandle) PURE; - STDMETHOD(CreateRenderTarget)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,DWORD MultisampleQuality,BOOL Lockable,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle) PURE; - STDMETHOD(CreateDepthStencilSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DMULTISAMPLE_TYPE MultiSample,DWORD MultisampleQuality,BOOL Discard,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle) PURE; -30 STDMETHOD(UpdateSurface)(THIS_ IDirect3DSurface9* pSourceSurface,CONST RECT* pSourceRect,IDirect3DSurface9* pDestinationSurface,CONST POINT* pDestPoint) PURE; - STDMETHOD(UpdateTexture)(THIS_ IDirect3DBaseTexture9* pSourceTexture,IDirect3DBaseTexture9* pDestinationTexture) PURE; - STDMETHOD(GetRenderTargetData)(THIS_ IDirect3DSurface9* pRenderTarget,IDirect3DSurface9* pDestSurface) PURE; - STDMETHOD(GetFrontBufferData)(THIS_ UINT iSwapChain,IDirect3DSurface9* pDestSurface) PURE; - STDMETHOD(StretchRect)(THIS_ IDirect3DSurface9* pSourceSurface,CONST RECT* pSourceRect,IDirect3DSurface9* pDestSurface,CONST RECT* pDestRect,D3DTEXTUREFILTERTYPE Filter) PURE; - STDMETHOD(ColorFill)(THIS_ IDirect3DSurface9* pSurface,CONST RECT* pRect,D3DCOLOR color) PURE; - STDMETHOD(CreateOffscreenPlainSurface)(THIS_ UINT Width,UINT Height,D3DFORMAT Format,D3DPOOL Pool,IDirect3DSurface9** ppSurface,HANDLE* pSharedHandle) PURE; - STDMETHOD(SetRenderTarget)(THIS_ DWORD RenderTargetIndex,IDirect3DSurface9* pRenderTarget) PURE; - STDMETHOD(GetRenderTarget)(THIS_ DWORD RenderTargetIndex,IDirect3DSurface9** ppRenderTarget) PURE; - STDMETHOD(SetDepthStencilSurface)(THIS_ IDirect3DSurface9* pNewZStencil) PURE; -40 STDMETHOD(GetDepthStencilSurface)(THIS_ IDirect3DSurface9** ppZStencilSurface) PURE; - STDMETHOD(BeginScene)(THIS) PURE; - STDMETHOD(EndScene)(THIS) PURE; - STDMETHOD(Clear)(THIS_ DWORD Count,CONST D3DRECT* pRects,DWORD Flags,D3DCOLOR Color,float Z,DWORD Stencil) PURE; - STDMETHOD(SetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,CONST D3DMATRIX* pMatrix) PURE; - STDMETHOD(GetTransform)(THIS_ D3DTRANSFORMSTATETYPE State,D3DMATRIX* pMatrix) PURE; - STDMETHOD(MultiplyTransform)(THIS_ D3DTRANSFORMSTATETYPE,CONST D3DMATRIX*) PURE; - STDMETHOD(SetViewport)(THIS_ CONST D3DVIEWPORT9* pViewport) PURE; - STDMETHOD(GetViewport)(THIS_ D3DVIEWPORT9* pViewport) PURE; - STDMETHOD(SetMaterial)(THIS_ CONST D3DMATERIAL9* pMaterial) PURE; -50 STDMETHOD(GetMaterial)(THIS_ D3DMATERIAL9* pMaterial) PURE; - STDMETHOD(SetLight)(THIS_ DWORD Index,CONST D3DLIGHT9*) PURE; - STDMETHOD(GetLight)(THIS_ DWORD Index,D3DLIGHT9*) PURE; - STDMETHOD(LightEnable)(THIS_ DWORD Index,BOOL Enable) PURE; - STDMETHOD(GetLightEnable)(THIS_ DWORD Index,BOOL* pEnable) PURE; - STDMETHOD(SetClipPlane)(THIS_ DWORD Index,CONST float* pPlane) PURE; - STDMETHOD(GetClipPlane)(THIS_ DWORD Index,float* pPlane) PURE; -57 STDMETHOD(SetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD Value) PURE; -58 STDMETHOD(GetRenderState)(THIS_ D3DRENDERSTATETYPE State,DWORD* pValue) PURE; - STDMETHOD(CreateStateBlock)(THIS_ D3DSTATEBLOCKTYPE Type,IDirect3DStateBlock9** ppSB) PURE; -60 STDMETHOD(BeginStateBlock)(THIS) PURE; - STDMETHOD(EndStateBlock)(THIS_ IDirect3DStateBlock9** ppSB) PURE; - STDMETHOD(SetClipStatus)(THIS_ CONST D3DCLIPSTATUS9* pClipStatus) PURE; - STDMETHOD(GetClipStatus)(THIS_ D3DCLIPSTATUS9* pClipStatus) PURE; - STDMETHOD(GetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture9** ppTexture) PURE; - STDMETHOD(SetTexture)(THIS_ DWORD Stage,IDirect3DBaseTexture9* pTexture) PURE; - STDMETHOD(GetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD* pValue) PURE; - STDMETHOD(SetTextureStageState)(THIS_ DWORD Stage,D3DTEXTURESTAGESTATETYPE Type,DWORD Value) PURE; - STDMETHOD(GetSamplerState)(THIS_ DWORD Sampler,D3DSAMPLERSTATETYPE Type,DWORD* pValue) PURE; - STDMETHOD(SetSamplerState)(THIS_ DWORD Sampler,D3DSAMPLERSTATETYPE Type,DWORD Value) PURE; - STDMETHOD(ValidateDevice)(THIS_ DWORD* pNumPasses) PURE; - STDMETHOD(SetPaletteEntries)(THIS_ UINT PaletteNumber,CONST PALETTEENTRY* pEntries) PURE; - STDMETHOD(GetPaletteEntries)(THIS_ UINT PaletteNumber,PALETTEENTRY* pEntries) PURE; - STDMETHOD(SetCurrentTexturePalette)(THIS_ UINT PaletteNumber) PURE; - STDMETHOD(GetCurrentTexturePalette)(THIS_ UINT *PaletteNumber) PURE; - STDMETHOD(SetScissorRect)(THIS_ CONST RECT* pRect) PURE; - STDMETHOD(GetScissorRect)(THIS_ RECT* pRect) PURE; - STDMETHOD(SetSoftwareVertexProcessing)(THIS_ BOOL bSoftware) PURE; - STDMETHOD_(BOOL, GetSoftwareVertexProcessing)(THIS) PURE; - STDMETHOD(SetNPatchMode)(THIS_ float nSegments) PURE; - STDMETHOD_(float, GetNPatchMode)(THIS) PURE; - STDMETHOD(DrawPrimitive)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT StartVertex,UINT PrimitiveCount) PURE; - STDMETHOD(DrawIndexedPrimitive)(THIS_ D3DPRIMITIVETYPE,INT BaseVertexIndex,UINT MinVertexIndex,UINT NumVertices,UINT startIndex,UINT primCount) PURE; - STDMETHOD(DrawPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT PrimitiveCount,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE; - STDMETHOD(DrawIndexedPrimitiveUP)(THIS_ D3DPRIMITIVETYPE PrimitiveType,UINT MinVertexIndex,UINT NumVertices,UINT PrimitiveCount,CONST void* pIndexData,D3DFORMAT IndexDataFormat,CONST void* pVertexStreamZeroData,UINT VertexStreamZeroStride) PURE; - STDMETHOD(ProcessVertices)(THIS_ UINT SrcStartIndex,UINT DestIndex,UINT VertexCount,IDirect3DVertexBuffer9* pDestBuffer,IDirect3DVertexDeclaration9* pVertexDecl,DWORD Flags) PURE; - STDMETHOD(CreateVertexDeclaration)(THIS_ CONST D3DVERTEXELEMENT9* pVertexElements,IDirect3DVertexDeclaration9** ppDecl) PURE; - STDMETHOD(SetVertexDeclaration)(THIS_ IDirect3DVertexDeclaration9* pDecl) PURE; - STDMETHOD(GetVertexDeclaration)(THIS_ IDirect3DVertexDeclaration9** ppDecl) PURE; - STDMETHOD(SetFVF)(THIS_ DWORD FVF) PURE; - STDMETHOD(GetFVF)(THIS_ DWORD* pFVF) PURE; - STDMETHOD(CreateVertexShader)(THIS_ CONST DWORD* pFunction,IDirect3DVertexShader9** ppShader) PURE; - STDMETHOD(SetVertexShader)(THIS_ IDirect3DVertexShader9* pShader) PURE; - STDMETHOD(GetVertexShader)(THIS_ IDirect3DVertexShader9** ppShader) PURE; - STDMETHOD(SetVertexShaderConstantF)(THIS_ UINT StartRegister,CONST float* pConstantData,UINT Vector4fCount) PURE; - STDMETHOD(GetVertexShaderConstantF)(THIS_ UINT StartRegister,float* pConstantData,UINT Vector4fCount) PURE; - STDMETHOD(SetVertexShaderConstantI)(THIS_ UINT StartRegister,CONST int* pConstantData,UINT Vector4iCount) PURE; - STDMETHOD(GetVertexShaderConstantI)(THIS_ UINT StartRegister,int* pConstantData,UINT Vector4iCount) PURE; - STDMETHOD(SetVertexShaderConstantB)(THIS_ UINT StartRegister,CONST BOOL* pConstantData,UINT BoolCount) PURE; - STDMETHOD(GetVertexShaderConstantB)(THIS_ UINT StartRegister,BOOL* pConstantData,UINT BoolCount) PURE; - STDMETHOD(SetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer9* pStreamData,UINT OffsetInBytes,UINT Stride) PURE; - STDMETHOD(GetStreamSource)(THIS_ UINT StreamNumber,IDirect3DVertexBuffer9** ppStreamData,UINT* pOffsetInBytes,UINT* pStride) PURE; - STDMETHOD(SetStreamSourceFreq)(THIS_ UINT StreamNumber,UINT Setting) PURE; - STDMETHOD(GetStreamSourceFreq)(THIS_ UINT StreamNumber,UINT* pSetting) PURE; - STDMETHOD(SetIndices)(THIS_ IDirect3DIndexBuffer9* pIndexData) PURE; - STDMETHOD(GetIndices)(THIS_ IDirect3DIndexBuffer9** ppIndexData) PURE; - STDMETHOD(CreatePixelShader)(THIS_ CONST DWORD* pFunction,IDirect3DPixelShader9** ppShader) PURE; - STDMETHOD(SetPixelShader)(THIS_ IDirect3DPixelShader9* pShader) PURE; - STDMETHOD(GetPixelShader)(THIS_ IDirect3DPixelShader9** ppShader) PURE; - STDMETHOD(SetPixelShaderConstantF)(THIS_ UINT StartRegister,CONST float* pConstantData,UINT Vector4fCount) PURE; - STDMETHOD(GetPixelShaderConstantF)(THIS_ UINT StartRegister,float* pConstantData,UINT Vector4fCount) PURE; - STDMETHOD(SetPixelShaderConstantI)(THIS_ UINT StartRegister,CONST int* pConstantData,UINT Vector4iCount) PURE; - STDMETHOD(GetPixelShaderConstantI)(THIS_ UINT StartRegister,int* pConstantData,UINT Vector4iCount) PURE; - STDMETHOD(SetPixelShaderConstantB)(THIS_ UINT StartRegister,CONST BOOL* pConstantData,UINT BoolCount) PURE; - STDMETHOD(GetPixelShaderConstantB)(THIS_ UINT StartRegister,BOOL* pConstantData,UINT BoolCount) PURE; - STDMETHOD(DrawRectPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DRECTPATCH_INFO* pRectPatchInfo) PURE; - STDMETHOD(DrawTriPatch)(THIS_ UINT Handle,CONST float* pNumSegs,CONST D3DTRIPATCH_INFO* pTriPatchInfo) PURE; - STDMETHOD(DeletePatch)(THIS_ UINT Handle) PURE; - STDMETHOD(CreateQuery)(THIS_ D3DQUERYTYPE Type,IDirect3DQuery9** ppQuery) PURE; - - #ifdef D3D_DEBUG_INFO - D3DDEVICE_CREATION_PARAMETERS CreationParameters; - D3DPRESENT_PARAMETERS PresentParameters; - D3DDISPLAYMODE DisplayMode; - D3DCAPS9 Caps; - - UINT AvailableTextureMem; - UINT SwapChains; - UINT Textures; - UINT VertexBuffers; - UINT IndexBuffers; - UINT VertexShaders; - UINT PixelShaders; - - D3DVIEWPORT9 Viewport; - D3DMATRIX ProjectionMatrix; - D3DMATRIX ViewMatrix; - D3DMATRIX WorldMatrix; - D3DMATRIX TextureMatrices[8]; - - DWORD FVF; - UINT VertexSize; - DWORD VertexShaderVersion; - DWORD PixelShaderVersion; - BOOL SoftwareVertexProcessing; - - D3DMATERIAL9 Material; - D3DLIGHT9 Lights[16]; - BOOL LightsEnabled[16]; - - D3DGAMMARAMP GammaRamp; - RECT ScissorRect; - BOOL DialogBoxMode; - #endif -}; - -typedef struct IDirect3DDevice9 *LPDIRECT3DDEVICE9, *PDIRECT3DDEVICE9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DDevice9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DDevice9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DDevice9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DDevice9_TestCooperativeLevel(p) (p)->lpVtbl->TestCooperativeLevel(p) -#define IDirect3DDevice9_GetAvailableTextureMem(p) (p)->lpVtbl->GetAvailableTextureMem(p) -#define IDirect3DDevice9_EvictManagedResources(p) (p)->lpVtbl->EvictManagedResources(p) -#define IDirect3DDevice9_GetDirect3D(p,a) (p)->lpVtbl->GetDirect3D(p,a) -#define IDirect3DDevice9_GetDeviceCaps(p,a) (p)->lpVtbl->GetDeviceCaps(p,a) -#define IDirect3DDevice9_GetDisplayMode(p,a,b) (p)->lpVtbl->GetDisplayMode(p,a,b) -#define IDirect3DDevice9_GetCreationParameters(p,a) (p)->lpVtbl->GetCreationParameters(p,a) -#define IDirect3DDevice9_SetCursorProperties(p,a,b,c) (p)->lpVtbl->SetCursorProperties(p,a,b,c) -#define IDirect3DDevice9_SetCursorPosition(p,a,b,c) (p)->lpVtbl->SetCursorPosition(p,a,b,c) -#define IDirect3DDevice9_ShowCursor(p,a) (p)->lpVtbl->ShowCursor(p,a) -#define IDirect3DDevice9_CreateAdditionalSwapChain(p,a,b) (p)->lpVtbl->CreateAdditionalSwapChain(p,a,b) -#define IDirect3DDevice9_GetSwapChain(p,a,b) (p)->lpVtbl->GetSwapChain(p,a,b) -#define IDirect3DDevice9_GetNumberOfSwapChains(p) (p)->lpVtbl->GetNumberOfSwapChains(p) -#define IDirect3DDevice9_Reset(p,a) (p)->lpVtbl->Reset(p,a) -#define IDirect3DDevice9_Present(p,a,b,c,d) (p)->lpVtbl->Present(p,a,b,c,d) -#define IDirect3DDevice9_GetBackBuffer(p,a,b,c,d) (p)->lpVtbl->GetBackBuffer(p,a,b,c,d) -#define IDirect3DDevice9_GetRasterStatus(p,a,b) (p)->lpVtbl->GetRasterStatus(p,a,b) -#define IDirect3DDevice9_SetDialogBoxMode(p,a) (p)->lpVtbl->SetDialogBoxMode(p,a) -#define IDirect3DDevice9_SetGammaRamp(p,a,b,c) (p)->lpVtbl->SetGammaRamp(p,a,b,c) -#define IDirect3DDevice9_GetGammaRamp(p,a,b) (p)->lpVtbl->GetGammaRamp(p,a,b) -#define IDirect3DDevice9_CreateTexture(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateTexture(p,a,b,c,d,e,f,g,h) -#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) -#define IDirect3DDevice9_CreateCubeTexture(p,a,b,c,d,e,f,g) (p)->lpVtbl->CreateCubeTexture(p,a,b,c,d,e,f,g) -#define IDirect3DDevice9_CreateVertexBuffer(p,a,b,c,d,e,f) (p)->lpVtbl->CreateVertexBuffer(p,a,b,c,d,e,f) -#define IDirect3DDevice9_CreateIndexBuffer(p,a,b,c,d,e,f) (p)->lpVtbl->CreateIndexBuffer(p,a,b,c,d,e,f) -#define IDirect3DDevice9_CreateRenderTarget(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateRenderTarget(p,a,b,c,d,e,f,g,h) -#define IDirect3DDevice9_CreateDepthStencilSurface(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->CreateDepthStencilSurface(p,a,b,c,d,e,f,g,h) -#define IDirect3DDevice9_UpdateSurface(p,a,b,c,d) (p)->lpVtbl->UpdateSurface(p,a,b,c,d) -#define IDirect3DDevice9_UpdateTexture(p,a,b) (p)->lpVtbl->UpdateTexture(p,a,b) -#define IDirect3DDevice9_GetRenderTargetData(p,a,b) (p)->lpVtbl->GetRenderTargetData(p,a,b) -#define IDirect3DDevice9_GetFrontBufferData(p,a,b) (p)->lpVtbl->GetFrontBufferData(p,a,b) -#define IDirect3DDevice9_StretchRect(p,a,b,c,d,e) (p)->lpVtbl->StretchRect(p,a,b,c,d,e) -#define IDirect3DDevice9_ColorFill(p,a,b,c) (p)->lpVtbl->ColorFill(p,a,b,c) -#define IDirect3DDevice9_CreateOffscreenPlainSurface(p,a,b,c,d,e,f) (p)->lpVtbl->CreateOffscreenPlainSurface(p,a,b,c,d,e,f) -#define IDirect3DDevice9_SetRenderTarget(p,a,b) (p)->lpVtbl->SetRenderTarget(p,a,b) -#define IDirect3DDevice9_GetRenderTarget(p,a,b) (p)->lpVtbl->GetRenderTarget(p,a,b) -#define IDirect3DDevice9_SetDepthStencilSurface(p,a) (p)->lpVtbl->SetDepthStencilSurface(p,a) -#define IDirect3DDevice9_GetDepthStencilSurface(p,a) (p)->lpVtbl->GetDepthStencilSurface(p,a) -#define IDirect3DDevice9_BeginScene(p) (p)->lpVtbl->BeginScene(p) -#define IDirect3DDevice9_EndScene(p) (p)->lpVtbl->EndScene(p) -#define IDirect3DDevice9_Clear(p,a,b,c,d,e,f) (p)->lpVtbl->Clear(p,a,b,c,d,e,f) -#define IDirect3DDevice9_SetTransform(p,a,b) (p)->lpVtbl->SetTransform(p,a,b) -#define IDirect3DDevice9_GetTransform(p,a,b) (p)->lpVtbl->GetTransform(p,a,b) -#define IDirect3DDevice9_MultiplyTransform(p,a,b) (p)->lpVtbl->MultiplyTransform(p,a,b) -#define IDirect3DDevice9_SetViewport(p,a) (p)->lpVtbl->SetViewport(p,a) -#define IDirect3DDevice9_GetViewport(p,a) (p)->lpVtbl->GetViewport(p,a) -#define IDirect3DDevice9_SetMaterial(p,a) (p)->lpVtbl->SetMaterial(p,a) -#define IDirect3DDevice9_GetMaterial(p,a) (p)->lpVtbl->GetMaterial(p,a) -#define IDirect3DDevice9_SetLight(p,a,b) (p)->lpVtbl->SetLight(p,a,b) -#define IDirect3DDevice9_GetLight(p,a,b) (p)->lpVtbl->GetLight(p,a,b) -#define IDirect3DDevice9_LightEnable(p,a,b) (p)->lpVtbl->LightEnable(p,a,b) -#define IDirect3DDevice9_GetLightEnable(p,a,b) (p)->lpVtbl->GetLightEnable(p,a,b) -#define IDirect3DDevice9_SetClipPlane(p,a,b) (p)->lpVtbl->SetClipPlane(p,a,b) -#define IDirect3DDevice9_GetClipPlane(p,a,b) (p)->lpVtbl->GetClipPlane(p,a,b) -#define IDirect3DDevice9_SetRenderState(p,a,b) (p)->lpVtbl->SetRenderState(p,a,b) -#define IDirect3DDevice9_GetRenderState(p,a,b) (p)->lpVtbl->GetRenderState(p,a,b) -#define IDirect3DDevice9_CreateStateBlock(p,a,b) (p)->lpVtbl->CreateStateBlock(p,a,b) -#define IDirect3DDevice9_BeginStateBlock(p) (p)->lpVtbl->BeginStateBlock(p) -#define IDirect3DDevice9_EndStateBlock(p,a) (p)->lpVtbl->EndStateBlock(p,a) -#define IDirect3DDevice9_SetClipStatus(p,a) (p)->lpVtbl->SetClipStatus(p,a) -#define IDirect3DDevice9_GetClipStatus(p,a) (p)->lpVtbl->GetClipStatus(p,a) -#define IDirect3DDevice9_GetTexture(p,a,b) (p)->lpVtbl->GetTexture(p,a,b) -#define IDirect3DDevice9_SetTexture(p,a,b) (p)->lpVtbl->SetTexture(p,a,b) -#define IDirect3DDevice9_GetTextureStageState(p,a,b,c) (p)->lpVtbl->GetTextureStageState(p,a,b,c) -#define IDirect3DDevice9_SetTextureStageState(p,a,b,c) (p)->lpVtbl->SetTextureStageState(p,a,b,c) -#define IDirect3DDevice9_GetSamplerState(p,a,b,c) (p)->lpVtbl->GetSamplerState(p,a,b,c) -#define IDirect3DDevice9_SetSamplerState(p,a,b,c) (p)->lpVtbl->SetSamplerState(p,a,b,c) -#define IDirect3DDevice9_ValidateDevice(p,a) (p)->lpVtbl->ValidateDevice(p,a) -#define IDirect3DDevice9_SetPaletteEntries(p,a,b) (p)->lpVtbl->SetPaletteEntries(p,a,b) -#define IDirect3DDevice9_GetPaletteEntries(p,a,b) (p)->lpVtbl->GetPaletteEntries(p,a,b) -#define IDirect3DDevice9_SetCurrentTexturePalette(p,a) (p)->lpVtbl->SetCurrentTexturePalette(p,a) -#define IDirect3DDevice9_GetCurrentTexturePalette(p,a) (p)->lpVtbl->GetCurrentTexturePalette(p,a) -#define IDirect3DDevice9_SetScissorRect(p,a) (p)->lpVtbl->SetScissorRect(p,a) -#define IDirect3DDevice9_GetScissorRect(p,a) (p)->lpVtbl->GetScissorRect(p,a) -#define IDirect3DDevice9_SetSoftwareVertexProcessing(p,a) (p)->lpVtbl->SetSoftwareVertexProcessing(p,a) -#define IDirect3DDevice9_GetSoftwareVertexProcessing(p) (p)->lpVtbl->GetSoftwareVertexProcessing(p) -#define IDirect3DDevice9_SetNPatchMode(p,a) (p)->lpVtbl->SetNPatchMode(p,a) -#define IDirect3DDevice9_GetNPatchMode(p) (p)->lpVtbl->GetNPatchMode(p) -#define IDirect3DDevice9_DrawPrimitive(p,a,b,c) (p)->lpVtbl->DrawPrimitive(p,a,b,c) -#define IDirect3DDevice9_DrawIndexedPrimitive(p,a,b,c,d,e,f) (p)->lpVtbl->DrawIndexedPrimitive(p,a,b,c,d,e,f) -#define IDirect3DDevice9_DrawPrimitiveUP(p,a,b,c,d) (p)->lpVtbl->DrawPrimitiveUP(p,a,b,c,d) -#define IDirect3DDevice9_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->lpVtbl->DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) -#define IDirect3DDevice9_ProcessVertices(p,a,b,c,d,e,f) (p)->lpVtbl->ProcessVertices(p,a,b,c,d,e,f) -#define IDirect3DDevice9_CreateVertexDeclaration(p,a,b) (p)->lpVtbl->CreateVertexDeclaration(p,a,b) -#define IDirect3DDevice9_SetVertexDeclaration(p,a) (p)->lpVtbl->SetVertexDeclaration(p,a) -#define IDirect3DDevice9_GetVertexDeclaration(p,a) (p)->lpVtbl->GetVertexDeclaration(p,a) -#define IDirect3DDevice9_SetFVF(p,a) (p)->lpVtbl->SetFVF(p,a) -#define IDirect3DDevice9_GetFVF(p,a) (p)->lpVtbl->GetFVF(p,a) -#define IDirect3DDevice9_CreateVertexShader(p,a,b) (p)->lpVtbl->CreateVertexShader(p,a,b) -#define IDirect3DDevice9_SetVertexShader(p,a) (p)->lpVtbl->SetVertexShader(p,a) -#define IDirect3DDevice9_GetVertexShader(p,a) (p)->lpVtbl->GetVertexShader(p,a) -#define IDirect3DDevice9_SetVertexShaderConstantF(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstantF(p,a,b,c) -#define IDirect3DDevice9_GetVertexShaderConstantF(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstantF(p,a,b,c) -#define IDirect3DDevice9_SetVertexShaderConstantI(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstantI(p,a,b,c) -#define IDirect3DDevice9_GetVertexShaderConstantI(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstantI(p,a,b,c) -#define IDirect3DDevice9_SetVertexShaderConstantB(p,a,b,c) (p)->lpVtbl->SetVertexShaderConstantB(p,a,b,c) -#define IDirect3DDevice9_GetVertexShaderConstantB(p,a,b,c) (p)->lpVtbl->GetVertexShaderConstantB(p,a,b,c) -#define IDirect3DDevice9_SetStreamSource(p,a,b,c,d) (p)->lpVtbl->SetStreamSource(p,a,b,c,d) -#define IDirect3DDevice9_GetStreamSource(p,a,b,c,d) (p)->lpVtbl->GetStreamSource(p,a,b,c,d) -#define IDirect3DDevice9_SetStreamSourceFreq(p,a,b) (p)->lpVtbl->SetStreamSourceFreq(p,a,b) -#define IDirect3DDevice9_GetStreamSourceFreq(p,a,b) (p)->lpVtbl->GetStreamSourceFreq(p,a,b) -#define IDirect3DDevice9_SetIndices(p,a) (p)->lpVtbl->SetIndices(p,a) -#define IDirect3DDevice9_GetIndices(p,a) (p)->lpVtbl->GetIndices(p,a) -#define IDirect3DDevice9_CreatePixelShader(p,a,b) (p)->lpVtbl->CreatePixelShader(p,a,b) -#define IDirect3DDevice9_SetPixelShader(p,a) (p)->lpVtbl->SetPixelShader(p,a) -#define IDirect3DDevice9_GetPixelShader(p,a) (p)->lpVtbl->GetPixelShader(p,a) -#define IDirect3DDevice9_SetPixelShaderConstantF(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstantF(p,a,b,c) -#define IDirect3DDevice9_GetPixelShaderConstantF(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstantF(p,a,b,c) -#define IDirect3DDevice9_SetPixelShaderConstantI(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstantI(p,a,b,c) -#define IDirect3DDevice9_GetPixelShaderConstantI(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstantI(p,a,b,c) -#define IDirect3DDevice9_SetPixelShaderConstantB(p,a,b,c) (p)->lpVtbl->SetPixelShaderConstantB(p,a,b,c) -#define IDirect3DDevice9_GetPixelShaderConstantB(p,a,b,c) (p)->lpVtbl->GetPixelShaderConstantB(p,a,b,c) -#define IDirect3DDevice9_DrawRectPatch(p,a,b,c) (p)->lpVtbl->DrawRectPatch(p,a,b,c) -#define IDirect3DDevice9_DrawTriPatch(p,a,b,c) (p)->lpVtbl->DrawTriPatch(p,a,b,c) -#define IDirect3DDevice9_DeletePatch(p,a) (p)->lpVtbl->DeletePatch(p,a) -#define IDirect3DDevice9_CreateQuery(p,a,b) (p)->lpVtbl->CreateQuery(p,a,b) -#else -#define IDirect3DDevice9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DDevice9_AddRef(p) (p)->AddRef() -#define IDirect3DDevice9_Release(p) (p)->Release() -#define IDirect3DDevice9_TestCooperativeLevel(p) (p)->TestCooperativeLevel() -#define IDirect3DDevice9_GetAvailableTextureMem(p) (p)->GetAvailableTextureMem() -#define IDirect3DDevice9_EvictManagedResources(p) (p)->EvictManagedResources() -#define IDirect3DDevice9_GetDirect3D(p,a) (p)->GetDirect3D(a) -#define IDirect3DDevice9_GetDeviceCaps(p,a) (p)->GetDeviceCaps(a) -#define IDirect3DDevice9_GetDisplayMode(p,a,b) (p)->GetDisplayMode(a,b) -#define IDirect3DDevice9_GetCreationParameters(p,a) (p)->GetCreationParameters(a) -#define IDirect3DDevice9_SetCursorProperties(p,a,b,c) (p)->SetCursorProperties(a,b,c) -#define IDirect3DDevice9_SetCursorPosition(p,a,b,c) (p)->SetCursorPosition(a,b,c) -#define IDirect3DDevice9_ShowCursor(p,a) (p)->ShowCursor(a) -#define IDirect3DDevice9_CreateAdditionalSwapChain(p,a,b) (p)->CreateAdditionalSwapChain(a,b) -#define IDirect3DDevice9_GetSwapChain(p,a,b) (p)->GetSwapChain(a,b) -#define IDirect3DDevice9_GetNumberOfSwapChains(p) (p)->GetNumberOfSwapChains() -#define IDirect3DDevice9_Reset(p,a) (p)->Reset(a) -#define IDirect3DDevice9_Present(p,a,b,c,d) (p)->Present(a,b,c,d) -#define IDirect3DDevice9_GetBackBuffer(p,a,b,c,d) (p)->GetBackBuffer(a,b,c,d) -#define IDirect3DDevice9_GetRasterStatus(p,a,b) (p)->GetRasterStatus(a,b) -#define IDirect3DDevice9_SetDialogBoxMode(p,a) (p)->SetDialogBoxMode(a) -#define IDirect3DDevice9_SetGammaRamp(p,a,b,c) (p)->SetGammaRamp(a,b,c) -#define IDirect3DDevice9_GetGammaRamp(p,a,b) (p)->GetGammaRamp(a,b) -#define IDirect3DDevice9_CreateTexture(p,a,b,c,d,e,f,g,h) (p)->CreateTexture(a,b,c,d,e,f,g,h) -#define IDirect3DDevice9_CreateVolumeTexture(p,a,b,c,d,e,f,g,h,i) (p)->CreateVolumeTexture(a,b,c,d,e,f,g,h,i) -#define IDirect3DDevice9_CreateCubeTexture(p,a,b,c,d,e,f,g) (p)->CreateCubeTexture(a,b,c,d,e,f,g) -#define IDirect3DDevice9_CreateVertexBuffer(p,a,b,c,d,e,f) (p)->CreateVertexBuffer(a,b,c,d,e,f) -#define IDirect3DDevice9_CreateIndexBuffer(p,a,b,c,d,e,f) (p)->CreateIndexBuffer(a,b,c,d,e,f) -#define IDirect3DDevice9_CreateRenderTarget(p,a,b,c,d,e,f,g,h) (p)->CreateRenderTarget(a,b,c,d,e,f,g,h) -#define IDirect3DDevice9_CreateDepthStencilSurface(p,a,b,c,d,e,f,g,h) (p)->CreateDepthStencilSurface(a,b,c,d,e,f,g,h) -#define IDirect3DDevice9_UpdateSurface(p,a,b,c,d) (p)->UpdateSurface(a,b,c,d) -#define IDirect3DDevice9_UpdateTexture(p,a,b) (p)->UpdateTexture(a,b) -#define IDirect3DDevice9_GetRenderTargetData(p,a,b) (p)->GetRenderTargetData(a,b) -#define IDirect3DDevice9_GetFrontBufferData(p,a,b) (p)->GetFrontBufferData(a,b) -#define IDirect3DDevice9_StretchRect(p,a,b,c,d,e) (p)->StretchRect(a,b,c,d,e) -#define IDirect3DDevice9_ColorFill(p,a,b,c) (p)->ColorFill(a,b,c) -#define IDirect3DDevice9_CreateOffscreenPlainSurface(p,a,b,c,d,e,f) (p)->CreateOffscreenPlainSurface(a,b,c,d,e,f) -#define IDirect3DDevice9_SetRenderTarget(p,a,b) (p)->SetRenderTarget(a,b) -#define IDirect3DDevice9_GetRenderTarget(p,a,b) (p)->GetRenderTarget(a,b) -#define IDirect3DDevice9_SetDepthStencilSurface(p,a) (p)->SetDepthStencilSurface(a) -#define IDirect3DDevice9_GetDepthStencilSurface(p,a) (p)->GetDepthStencilSurface(a) -#define IDirect3DDevice9_BeginScene(p) (p)->BeginScene() -#define IDirect3DDevice9_EndScene(p) (p)->EndScene() -#define IDirect3DDevice9_Clear(p,a,b,c,d,e,f) (p)->Clear(a,b,c,d,e,f) -#define IDirect3DDevice9_SetTransform(p,a,b) (p)->SetTransform(a,b) -#define IDirect3DDevice9_GetTransform(p,a,b) (p)->GetTransform(a,b) -#define IDirect3DDevice9_MultiplyTransform(p,a,b) (p)->MultiplyTransform(a,b) -#define IDirect3DDevice9_SetViewport(p,a) (p)->SetViewport(a) -#define IDirect3DDevice9_GetViewport(p,a) (p)->GetViewport(a) -#define IDirect3DDevice9_SetMaterial(p,a) (p)->SetMaterial(a) -#define IDirect3DDevice9_GetMaterial(p,a) (p)->GetMaterial(a) -#define IDirect3DDevice9_SetLight(p,a,b) (p)->SetLight(a,b) -#define IDirect3DDevice9_GetLight(p,a,b) (p)->GetLight(a,b) -#define IDirect3DDevice9_LightEnable(p,a,b) (p)->LightEnable(a,b) -#define IDirect3DDevice9_GetLightEnable(p,a,b) (p)->GetLightEnable(a,b) -#define IDirect3DDevice9_SetClipPlane(p,a,b) (p)->SetClipPlane(a,b) -#define IDirect3DDevice9_GetClipPlane(p,a,b) (p)->GetClipPlane(a,b) -#define IDirect3DDevice9_SetRenderState(p,a,b) (p)->SetRenderState(a,b) -#define IDirect3DDevice9_GetRenderState(p,a,b) (p)->GetRenderState(a,b) -#define IDirect3DDevice9_CreateStateBlock(p,a,b) (p)->CreateStateBlock(a,b) -#define IDirect3DDevice9_BeginStateBlock(p) (p)->BeginStateBlock() -#define IDirect3DDevice9_EndStateBlock(p,a) (p)->EndStateBlock(a) -#define IDirect3DDevice9_SetClipStatus(p,a) (p)->SetClipStatus(a) -#define IDirect3DDevice9_GetClipStatus(p,a) (p)->GetClipStatus(a) -#define IDirect3DDevice9_GetTexture(p,a,b) (p)->GetTexture(a,b) -#define IDirect3DDevice9_SetTexture(p,a,b) (p)->SetTexture(a,b) -#define IDirect3DDevice9_GetTextureStageState(p,a,b,c) (p)->GetTextureStageState(a,b,c) -#define IDirect3DDevice9_SetTextureStageState(p,a,b,c) (p)->SetTextureStageState(a,b,c) -#define IDirect3DDevice9_GetSamplerState(p,a,b,c) (p)->GetSamplerState(a,b,c) -#define IDirect3DDevice9_SetSamplerState(p,a,b,c) (p)->SetSamplerState(a,b,c) -#define IDirect3DDevice9_ValidateDevice(p,a) (p)->ValidateDevice(a) -#define IDirect3DDevice9_SetPaletteEntries(p,a,b) (p)->SetPaletteEntries(a,b) -#define IDirect3DDevice9_GetPaletteEntries(p,a,b) (p)->GetPaletteEntries(a,b) -#define IDirect3DDevice9_SetCurrentTexturePalette(p,a) (p)->SetCurrentTexturePalette(a) -#define IDirect3DDevice9_GetCurrentTexturePalette(p,a) (p)->GetCurrentTexturePalette(a) -#define IDirect3DDevice9_SetScissorRect(p,a) (p)->SetScissorRect(a) -#define IDirect3DDevice9_GetScissorRect(p,a) (p)->GetScissorRect(a) -#define IDirect3DDevice9_SetSoftwareVertexProcessing(p,a) (p)->SetSoftwareVertexProcessing(a) -#define IDirect3DDevice9_GetSoftwareVertexProcessing(p) (p)->GetSoftwareVertexProcessing() -#define IDirect3DDevice9_SetNPatchMode(p,a) (p)->SetNPatchMode(a) -#define IDirect3DDevice9_GetNPatchMode(p) (p)->GetNPatchMode() -#define IDirect3DDevice9_DrawPrimitive(p,a,b,c) (p)->DrawPrimitive(a,b,c) -#define IDirect3DDevice9_DrawIndexedPrimitive(p,a,b,c,d,e,f) (p)->DrawIndexedPrimitive(a,b,c,d,e,f) -#define IDirect3DDevice9_DrawPrimitiveUP(p,a,b,c,d) (p)->DrawPrimitiveUP(a,b,c,d) -#define IDirect3DDevice9_DrawIndexedPrimitiveUP(p,a,b,c,d,e,f,g,h) (p)->DrawIndexedPrimitiveUP(a,b,c,d,e,f,g,h) -#define IDirect3DDevice9_ProcessVertices(p,a,b,c,d,e,f) (p)->ProcessVertices(a,b,c,d,e,f) -#define IDirect3DDevice9_CreateVertexDeclaration(p,a,b) (p)->CreateVertexDeclaration(a,b) -#define IDirect3DDevice9_SetVertexDeclaration(p,a) (p)->SetVertexDeclaration(a) -#define IDirect3DDevice9_GetVertexDeclaration(p,a) (p)->GetVertexDeclaration(a) -#define IDirect3DDevice9_SetFVF(p,a) (p)->SetFVF(a) -#define IDirect3DDevice9_GetFVF(p,a) (p)->GetFVF(a) -#define IDirect3DDevice9_CreateVertexShader(p,a,b) (p)->CreateVertexShader(a,b) -#define IDirect3DDevice9_SetVertexShader(p,a) (p)->SetVertexShader(a) -#define IDirect3DDevice9_GetVertexShader(p,a) (p)->GetVertexShader(a) -#define IDirect3DDevice9_SetVertexShaderConstantF(p,a,b,c) (p)->SetVertexShaderConstantF(a,b,c) -#define IDirect3DDevice9_GetVertexShaderConstantF(p,a,b,c) (p)->GetVertexShaderConstantF(a,b,c) -#define IDirect3DDevice9_SetVertexShaderConstantI(p,a,b,c) (p)->SetVertexShaderConstantI(a,b,c) -#define IDirect3DDevice9_GetVertexShaderConstantI(p,a,b,c) (p)->GetVertexShaderConstantI(a,b,c) -#define IDirect3DDevice9_SetVertexShaderConstantB(p,a,b,c) (p)->SetVertexShaderConstantB(a,b,c) -#define IDirect3DDevice9_GetVertexShaderConstantB(p,a,b,c) (p)->GetVertexShaderConstantB(a,b,c) -#define IDirect3DDevice9_SetStreamSource(p,a,b,c,d) (p)->SetStreamSource(a,b,c,d) -#define IDirect3DDevice9_GetStreamSource(p,a,b,c,d) (p)->GetStreamSource(a,b,c,d) -#define IDirect3DDevice9_SetStreamSourceFreq(p,a,b) (p)->SetStreamSourceFreq(a,b) -#define IDirect3DDevice9_GetStreamSourceFreq(p,a,b) (p)->GetStreamSourceFreq(a,b) -#define IDirect3DDevice9_SetIndices(p,a) (p)->SetIndices(a) -#define IDirect3DDevice9_GetIndices(p,a) (p)->GetIndices(a) -#define IDirect3DDevice9_CreatePixelShader(p,a,b) (p)->CreatePixelShader(a,b) -#define IDirect3DDevice9_SetPixelShader(p,a) (p)->SetPixelShader(a) -#define IDirect3DDevice9_GetPixelShader(p,a) (p)->GetPixelShader(a) -#define IDirect3DDevice9_SetPixelShaderConstantF(p,a,b,c) (p)->SetPixelShaderConstantF(a,b,c) -#define IDirect3DDevice9_GetPixelShaderConstantF(p,a,b,c) (p)->GetPixelShaderConstantF(a,b,c) -#define IDirect3DDevice9_SetPixelShaderConstantI(p,a,b,c) (p)->SetPixelShaderConstantI(a,b,c) -#define IDirect3DDevice9_GetPixelShaderConstantI(p,a,b,c) (p)->GetPixelShaderConstantI(a,b,c) -#define IDirect3DDevice9_SetPixelShaderConstantB(p,a,b,c) (p)->SetPixelShaderConstantB(a,b,c) -#define IDirect3DDevice9_GetPixelShaderConstantB(p,a,b,c) (p)->GetPixelShaderConstantB(a,b,c) -#define IDirect3DDevice9_DrawRectPatch(p,a,b,c) (p)->DrawRectPatch(a,b,c) -#define IDirect3DDevice9_DrawTriPatch(p,a,b,c) (p)->DrawTriPatch(a,b,c) -#define IDirect3DDevice9_DeletePatch(p,a) (p)->DeletePatch(a) -#define IDirect3DDevice9_CreateQuery(p,a,b) (p)->CreateQuery(a,b) -#endif - - -#undef INTERFACE -#define INTERFACE IDirect3DStateBlock9 - -DECLARE_INTERFACE_(IDirect3DStateBlock9, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DStateBlock9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(Capture)(THIS) PURE; - STDMETHOD(Apply)(THIS) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DStateBlock9 *LPDIRECT3DSTATEBLOCK9, *PDIRECT3DSTATEBLOCK9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DStateBlock9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DStateBlock9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DStateBlock9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DStateBlock9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DStateBlock9_Capture(p) (p)->lpVtbl->Capture(p) -#define IDirect3DStateBlock9_Apply(p) (p)->lpVtbl->Apply(p) -#else -#define IDirect3DStateBlock9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DStateBlock9_AddRef(p) (p)->AddRef() -#define IDirect3DStateBlock9_Release(p) (p)->Release() -#define IDirect3DStateBlock9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DStateBlock9_Capture(p) (p)->Capture() -#define IDirect3DStateBlock9_Apply(p) (p)->Apply() -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DSwapChain9 - -DECLARE_INTERFACE_(IDirect3DSwapChain9, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DSwapChain9 methods ***/ - STDMETHOD(Present)(THIS_ CONST RECT* pSourceRect,CONST RECT* pDestRect,HWND hDestWindowOverride,CONST RGNDATA* pDirtyRegion,DWORD dwFlags) PURE; - STDMETHOD(GetFrontBufferData)(THIS_ IDirect3DSurface9* pDestSurface) PURE; - STDMETHOD(GetBackBuffer)(THIS_ UINT iBackBuffer,D3DBACKBUFFER_TYPE Type,IDirect3DSurface9** ppBackBuffer) PURE; - STDMETHOD(GetRasterStatus)(THIS_ D3DRASTER_STATUS* pRasterStatus) PURE; - STDMETHOD(GetDisplayMode)(THIS_ D3DDISPLAYMODE* pMode) PURE; - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(GetPresentParameters)(THIS_ D3DPRESENT_PARAMETERS* pPresentationParameters) PURE; - - #ifdef D3D_DEBUG_INFO - D3DPRESENT_PARAMETERS PresentParameters; - D3DDISPLAYMODE DisplayMode; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DSwapChain9 *LPDIRECT3DSWAPCHAIN9, *PDIRECT3DSWAPCHAIN9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DSwapChain9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DSwapChain9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DSwapChain9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DSwapChain9_Present(p,a,b,c,d,e) (p)->lpVtbl->Present(p,a,b,c,d,e) -#define IDirect3DSwapChain9_GetFrontBufferData(p,a) (p)->lpVtbl->GetFrontBufferData(p,a) -#define IDirect3DSwapChain9_GetBackBuffer(p,a,b,c) (p)->lpVtbl->GetBackBuffer(p,a,b,c) -#define IDirect3DSwapChain9_GetRasterStatus(p,a) (p)->lpVtbl->GetRasterStatus(p,a) -#define IDirect3DSwapChain9_GetDisplayMode(p,a) (p)->lpVtbl->GetDisplayMode(p,a) -#define IDirect3DSwapChain9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DSwapChain9_GetPresentParameters(p,a) (p)->lpVtbl->GetPresentParameters(p,a) -#else -#define IDirect3DSwapChain9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DSwapChain9_AddRef(p) (p)->AddRef() -#define IDirect3DSwapChain9_Release(p) (p)->Release() -#define IDirect3DSwapChain9_Present(p,a,b,c,d,e) (p)->Present(a,b,c,d,e) -#define IDirect3DSwapChain9_GetFrontBufferData(p,a) (p)->GetFrontBufferData(a) -#define IDirect3DSwapChain9_GetBackBuffer(p,a,b,c) (p)->GetBackBuffer(a,b,c) -#define IDirect3DSwapChain9_GetRasterStatus(p,a) (p)->GetRasterStatus(a) -#define IDirect3DSwapChain9_GetDisplayMode(p,a) (p)->GetDisplayMode(a) -#define IDirect3DSwapChain9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DSwapChain9_GetPresentParameters(p,a) (p)->GetPresentParameters(a) -#endif - - - -#undef INTERFACE -#define INTERFACE IDirect3DResource9 - -DECLARE_INTERFACE_(IDirect3DResource9, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DResource9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; -}; - -typedef struct IDirect3DResource9 *LPDIRECT3DRESOURCE9, *PDIRECT3DRESOURCE9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DResource9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DResource9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DResource9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DResource9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DResource9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DResource9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DResource9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DResource9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DResource9_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DResource9_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DResource9_GetType(p) (p)->lpVtbl->GetType(p) -#else -#define IDirect3DResource9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DResource9_AddRef(p) (p)->AddRef() -#define IDirect3DResource9_Release(p) (p)->Release() -#define IDirect3DResource9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DResource9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DResource9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DResource9_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DResource9_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DResource9_GetPriority(p) (p)->GetPriority() -#define IDirect3DResource9_PreLoad(p) (p)->PreLoad() -#define IDirect3DResource9_GetType(p) (p)->GetType() -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DVertexDeclaration9 - -DECLARE_INTERFACE_(IDirect3DVertexDeclaration9, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DVertexDeclaration9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(GetDeclaration)(THIS_ D3DVERTEXELEMENT9* pElement,UINT* pNumElements) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DVertexDeclaration9 *LPDIRECT3DVERTEXDECLARATION9, *PDIRECT3DVERTEXDECLARATION9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DVertexDeclaration9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DVertexDeclaration9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DVertexDeclaration9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DVertexDeclaration9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DVertexDeclaration9_GetDeclaration(p,a,b) (p)->lpVtbl->GetDeclaration(p,a,b) -#else -#define IDirect3DVertexDeclaration9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DVertexDeclaration9_AddRef(p) (p)->AddRef() -#define IDirect3DVertexDeclaration9_Release(p) (p)->Release() -#define IDirect3DVertexDeclaration9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DVertexDeclaration9_GetDeclaration(p,a,b) (p)->GetDeclaration(a,b) -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DVertexShader9 - -DECLARE_INTERFACE_(IDirect3DVertexShader9, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DVertexShader9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(GetFunction)(THIS_ void*,UINT* pSizeOfData) PURE; - - #ifdef D3D_DEBUG_INFO - DWORD Version; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DVertexShader9 *LPDIRECT3DVERTEXSHADER9, *PDIRECT3DVERTEXSHADER9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DVertexShader9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DVertexShader9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DVertexShader9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DVertexShader9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DVertexShader9_GetFunction(p,a,b) (p)->lpVtbl->GetFunction(p,a,b) -#else -#define IDirect3DVertexShader9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DVertexShader9_AddRef(p) (p)->AddRef() -#define IDirect3DVertexShader9_Release(p) (p)->Release() -#define IDirect3DVertexShader9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DVertexShader9_GetFunction(p,a,b) (p)->GetFunction(a,b) -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DPixelShader9 - -DECLARE_INTERFACE_(IDirect3DPixelShader9, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DPixelShader9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(GetFunction)(THIS_ void*,UINT* pSizeOfData) PURE; - - #ifdef D3D_DEBUG_INFO - DWORD Version; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DPixelShader9 *LPDIRECT3DPIXELSHADER9, *PDIRECT3DPIXELSHADER9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DPixelShader9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DPixelShader9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DPixelShader9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DPixelShader9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DPixelShader9_GetFunction(p,a,b) (p)->lpVtbl->GetFunction(p,a,b) -#else -#define IDirect3DPixelShader9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DPixelShader9_AddRef(p) (p)->AddRef() -#define IDirect3DPixelShader9_Release(p) (p)->Release() -#define IDirect3DPixelShader9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DPixelShader9_GetFunction(p,a,b) (p)->GetFunction(a,b) -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DBaseTexture9 - -DECLARE_INTERFACE_(IDirect3DBaseTexture9, IDirect3DResource9) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DResource9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE; - STDMETHOD_(DWORD, GetLOD)(THIS) PURE; - STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE; - STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE; - STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE; - STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE; -}; - -typedef struct IDirect3DBaseTexture9 *LPDIRECT3DBASETEXTURE9, *PDIRECT3DBASETEXTURE9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DBaseTexture9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DBaseTexture9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DBaseTexture9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DBaseTexture9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DBaseTexture9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DBaseTexture9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DBaseTexture9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DBaseTexture9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DBaseTexture9_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DBaseTexture9_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DBaseTexture9_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DBaseTexture9_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) -#define IDirect3DBaseTexture9_GetLOD(p) (p)->lpVtbl->GetLOD(p) -#define IDirect3DBaseTexture9_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p) -#define IDirect3DBaseTexture9_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a) -#define IDirect3DBaseTexture9_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p) -#define IDirect3DBaseTexture9_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p) -#else -#define IDirect3DBaseTexture9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DBaseTexture9_AddRef(p) (p)->AddRef() -#define IDirect3DBaseTexture9_Release(p) (p)->Release() -#define IDirect3DBaseTexture9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DBaseTexture9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DBaseTexture9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DBaseTexture9_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DBaseTexture9_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DBaseTexture9_GetPriority(p) (p)->GetPriority() -#define IDirect3DBaseTexture9_PreLoad(p) (p)->PreLoad() -#define IDirect3DBaseTexture9_GetType(p) (p)->GetType() -#define IDirect3DBaseTexture9_SetLOD(p,a) (p)->SetLOD(a) -#define IDirect3DBaseTexture9_GetLOD(p) (p)->GetLOD() -#define IDirect3DBaseTexture9_GetLevelCount(p) (p)->GetLevelCount() -#define IDirect3DBaseTexture9_SetAutoGenFilterType(p,a) (p)->SetAutoGenFilterType(a) -#define IDirect3DBaseTexture9_GetAutoGenFilterType(p) (p)->GetAutoGenFilterType() -#define IDirect3DBaseTexture9_GenerateMipSubLevels(p) (p)->GenerateMipSubLevels() -#endif - - - - - -#undef INTERFACE -#define INTERFACE IDirect3DTexture9 - -DECLARE_INTERFACE_(IDirect3DTexture9, IDirect3DBaseTexture9) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DBaseTexture9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE; - STDMETHOD_(DWORD, GetLOD)(THIS) PURE; - STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE; - STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE; - STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE; - STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE; - STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DSURFACE_DESC *pDesc) PURE; - STDMETHOD(GetSurfaceLevel)(THIS_ UINT Level,IDirect3DSurface9** ppSurfaceLevel) PURE; - STDMETHOD(LockRect)(THIS_ UINT Level,D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE; - STDMETHOD(UnlockRect)(THIS_ UINT Level) PURE; - STDMETHOD(AddDirtyRect)(THIS_ CONST RECT* pDirtyRect) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR Name; - UINT Width; - UINT Height; - UINT Levels; - DWORD Usage; - D3DFORMAT Format; - D3DPOOL Pool; - DWORD Priority; - DWORD LOD; - D3DTEXTUREFILTERTYPE FilterType; - UINT LockCount; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DTexture9 *LPDIRECT3DTEXTURE9, *PDIRECT3DTEXTURE9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DTexture9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DTexture9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DTexture9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DTexture9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DTexture9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DTexture9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DTexture9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DTexture9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DTexture9_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DTexture9_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DTexture9_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DTexture9_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) -#define IDirect3DTexture9_GetLOD(p) (p)->lpVtbl->GetLOD(p) -#define IDirect3DTexture9_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p) -#define IDirect3DTexture9_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a) -#define IDirect3DTexture9_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p) -#define IDirect3DTexture9_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p) -#define IDirect3DTexture9_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b) -#define IDirect3DTexture9_GetSurfaceLevel(p,a,b) (p)->lpVtbl->GetSurfaceLevel(p,a,b) -#define IDirect3DTexture9_LockRect(p,a,b,c,d) (p)->lpVtbl->LockRect(p,a,b,c,d) -#define IDirect3DTexture9_UnlockRect(p,a) (p)->lpVtbl->UnlockRect(p,a) -#define IDirect3DTexture9_AddDirtyRect(p,a) (p)->lpVtbl->AddDirtyRect(p,a) -#else -#define IDirect3DTexture9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DTexture9_AddRef(p) (p)->AddRef() -#define IDirect3DTexture9_Release(p) (p)->Release() -#define IDirect3DTexture9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DTexture9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DTexture9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DTexture9_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DTexture9_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DTexture9_GetPriority(p) (p)->GetPriority() -#define IDirect3DTexture9_PreLoad(p) (p)->PreLoad() -#define IDirect3DTexture9_GetType(p) (p)->GetType() -#define IDirect3DTexture9_SetLOD(p,a) (p)->SetLOD(a) -#define IDirect3DTexture9_GetLOD(p) (p)->GetLOD() -#define IDirect3DTexture9_GetLevelCount(p) (p)->GetLevelCount() -#define IDirect3DTexture9_SetAutoGenFilterType(p,a) (p)->SetAutoGenFilterType(a) -#define IDirect3DTexture9_GetAutoGenFilterType(p) (p)->GetAutoGenFilterType() -#define IDirect3DTexture9_GenerateMipSubLevels(p) (p)->GenerateMipSubLevels() -#define IDirect3DTexture9_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b) -#define IDirect3DTexture9_GetSurfaceLevel(p,a,b) (p)->GetSurfaceLevel(a,b) -#define IDirect3DTexture9_LockRect(p,a,b,c,d) (p)->LockRect(a,b,c,d) -#define IDirect3DTexture9_UnlockRect(p,a) (p)->UnlockRect(a) -#define IDirect3DTexture9_AddDirtyRect(p,a) (p)->AddDirtyRect(a) -#endif - - - - - -#undef INTERFACE -#define INTERFACE IDirect3DVolumeTexture9 - -DECLARE_INTERFACE_(IDirect3DVolumeTexture9, IDirect3DBaseTexture9) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DBaseTexture9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE; - STDMETHOD_(DWORD, GetLOD)(THIS) PURE; - STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE; - STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE; - STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE; - STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE; - STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DVOLUME_DESC *pDesc) PURE; - STDMETHOD(GetVolumeLevel)(THIS_ UINT Level,IDirect3DVolume9** ppVolumeLevel) PURE; - STDMETHOD(LockBox)(THIS_ UINT Level,D3DLOCKED_BOX* pLockedVolume,CONST D3DBOX* pBox,DWORD Flags) PURE; - STDMETHOD(UnlockBox)(THIS_ UINT Level) PURE; - STDMETHOD(AddDirtyBox)(THIS_ CONST D3DBOX* pDirtyBox) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR Name; - UINT Width; - UINT Height; - UINT Depth; - UINT Levels; - DWORD Usage; - D3DFORMAT Format; - D3DPOOL Pool; - DWORD Priority; - DWORD LOD; - D3DTEXTUREFILTERTYPE FilterType; - UINT LockCount; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DVolumeTexture9 *LPDIRECT3DVOLUMETEXTURE9, *PDIRECT3DVOLUMETEXTURE9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DVolumeTexture9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DVolumeTexture9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DVolumeTexture9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DVolumeTexture9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DVolumeTexture9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DVolumeTexture9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DVolumeTexture9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DVolumeTexture9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DVolumeTexture9_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DVolumeTexture9_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DVolumeTexture9_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DVolumeTexture9_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) -#define IDirect3DVolumeTexture9_GetLOD(p) (p)->lpVtbl->GetLOD(p) -#define IDirect3DVolumeTexture9_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p) -#define IDirect3DVolumeTexture9_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a) -#define IDirect3DVolumeTexture9_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p) -#define IDirect3DVolumeTexture9_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p) -#define IDirect3DVolumeTexture9_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b) -#define IDirect3DVolumeTexture9_GetVolumeLevel(p,a,b) (p)->lpVtbl->GetVolumeLevel(p,a,b) -#define IDirect3DVolumeTexture9_LockBox(p,a,b,c,d) (p)->lpVtbl->LockBox(p,a,b,c,d) -#define IDirect3DVolumeTexture9_UnlockBox(p,a) (p)->lpVtbl->UnlockBox(p,a) -#define IDirect3DVolumeTexture9_AddDirtyBox(p,a) (p)->lpVtbl->AddDirtyBox(p,a) -#else -#define IDirect3DVolumeTexture9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DVolumeTexture9_AddRef(p) (p)->AddRef() -#define IDirect3DVolumeTexture9_Release(p) (p)->Release() -#define IDirect3DVolumeTexture9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DVolumeTexture9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DVolumeTexture9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DVolumeTexture9_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DVolumeTexture9_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DVolumeTexture9_GetPriority(p) (p)->GetPriority() -#define IDirect3DVolumeTexture9_PreLoad(p) (p)->PreLoad() -#define IDirect3DVolumeTexture9_GetType(p) (p)->GetType() -#define IDirect3DVolumeTexture9_SetLOD(p,a) (p)->SetLOD(a) -#define IDirect3DVolumeTexture9_GetLOD(p) (p)->GetLOD() -#define IDirect3DVolumeTexture9_GetLevelCount(p) (p)->GetLevelCount() -#define IDirect3DVolumeTexture9_SetAutoGenFilterType(p,a) (p)->SetAutoGenFilterType(a) -#define IDirect3DVolumeTexture9_GetAutoGenFilterType(p) (p)->GetAutoGenFilterType() -#define IDirect3DVolumeTexture9_GenerateMipSubLevels(p) (p)->GenerateMipSubLevels() -#define IDirect3DVolumeTexture9_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b) -#define IDirect3DVolumeTexture9_GetVolumeLevel(p,a,b) (p)->GetVolumeLevel(a,b) -#define IDirect3DVolumeTexture9_LockBox(p,a,b,c,d) (p)->LockBox(a,b,c,d) -#define IDirect3DVolumeTexture9_UnlockBox(p,a) (p)->UnlockBox(a) -#define IDirect3DVolumeTexture9_AddDirtyBox(p,a) (p)->AddDirtyBox(a) -#endif - - - - - -#undef INTERFACE -#define INTERFACE IDirect3DCubeTexture9 - -DECLARE_INTERFACE_(IDirect3DCubeTexture9, IDirect3DBaseTexture9) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DBaseTexture9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE; - STDMETHOD_(DWORD, GetLOD)(THIS) PURE; - STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE; - STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE; - STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE; - STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE; - STDMETHOD(GetLevelDesc)(THIS_ UINT Level,D3DSURFACE_DESC *pDesc) PURE; - STDMETHOD(GetCubeMapSurface)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level,IDirect3DSurface9** ppCubeMapSurface) PURE; - STDMETHOD(LockRect)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level,D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE; - STDMETHOD(UnlockRect)(THIS_ D3DCUBEMAP_FACES FaceType,UINT Level) PURE; - STDMETHOD(AddDirtyRect)(THIS_ D3DCUBEMAP_FACES FaceType,CONST RECT* pDirtyRect) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR Name; - UINT Width; - UINT Height; - UINT Levels; - DWORD Usage; - D3DFORMAT Format; - D3DPOOL Pool; - DWORD Priority; - DWORD LOD; - D3DTEXTUREFILTERTYPE FilterType; - UINT LockCount; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DCubeTexture9 *LPDIRECT3DCUBETEXTURE9, *PDIRECT3DCUBETEXTURE9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DCubeTexture9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DCubeTexture9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DCubeTexture9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DCubeTexture9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DCubeTexture9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DCubeTexture9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DCubeTexture9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DCubeTexture9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DCubeTexture9_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DCubeTexture9_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DCubeTexture9_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DCubeTexture9_SetLOD(p,a) (p)->lpVtbl->SetLOD(p,a) -#define IDirect3DCubeTexture9_GetLOD(p) (p)->lpVtbl->GetLOD(p) -#define IDirect3DCubeTexture9_GetLevelCount(p) (p)->lpVtbl->GetLevelCount(p) -#define IDirect3DCubeTexture9_SetAutoGenFilterType(p,a) (p)->lpVtbl->SetAutoGenFilterType(p,a) -#define IDirect3DCubeTexture9_GetAutoGenFilterType(p) (p)->lpVtbl->GetAutoGenFilterType(p) -#define IDirect3DCubeTexture9_GenerateMipSubLevels(p) (p)->lpVtbl->GenerateMipSubLevels(p) -#define IDirect3DCubeTexture9_GetLevelDesc(p,a,b) (p)->lpVtbl->GetLevelDesc(p,a,b) -#define IDirect3DCubeTexture9_GetCubeMapSurface(p,a,b,c) (p)->lpVtbl->GetCubeMapSurface(p,a,b,c) -#define IDirect3DCubeTexture9_LockRect(p,a,b,c,d,e) (p)->lpVtbl->LockRect(p,a,b,c,d,e) -#define IDirect3DCubeTexture9_UnlockRect(p,a,b) (p)->lpVtbl->UnlockRect(p,a,b) -#define IDirect3DCubeTexture9_AddDirtyRect(p,a,b) (p)->lpVtbl->AddDirtyRect(p,a,b) -#else -#define IDirect3DCubeTexture9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DCubeTexture9_AddRef(p) (p)->AddRef() -#define IDirect3DCubeTexture9_Release(p) (p)->Release() -#define IDirect3DCubeTexture9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DCubeTexture9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DCubeTexture9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DCubeTexture9_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DCubeTexture9_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DCubeTexture9_GetPriority(p) (p)->GetPriority() -#define IDirect3DCubeTexture9_PreLoad(p) (p)->PreLoad() -#define IDirect3DCubeTexture9_GetType(p) (p)->GetType() -#define IDirect3DCubeTexture9_SetLOD(p,a) (p)->SetLOD(a) -#define IDirect3DCubeTexture9_GetLOD(p) (p)->GetLOD() -#define IDirect3DCubeTexture9_GetLevelCount(p) (p)->GetLevelCount() -#define IDirect3DCubeTexture9_SetAutoGenFilterType(p,a) (p)->SetAutoGenFilterType(a) -#define IDirect3DCubeTexture9_GetAutoGenFilterType(p) (p)->GetAutoGenFilterType() -#define IDirect3DCubeTexture9_GenerateMipSubLevels(p) (p)->GenerateMipSubLevels() -#define IDirect3DCubeTexture9_GetLevelDesc(p,a,b) (p)->GetLevelDesc(a,b) -#define IDirect3DCubeTexture9_GetCubeMapSurface(p,a,b,c) (p)->GetCubeMapSurface(a,b,c) -#define IDirect3DCubeTexture9_LockRect(p,a,b,c,d,e) (p)->LockRect(a,b,c,d,e) -#define IDirect3DCubeTexture9_UnlockRect(p,a,b) (p)->UnlockRect(a,b) -#define IDirect3DCubeTexture9_AddDirtyRect(p,a,b) (p)->AddDirtyRect(a,b) -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DVertexBuffer9 - -DECLARE_INTERFACE_(IDirect3DVertexBuffer9, IDirect3DResource9) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DResource9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD(Lock)(THIS_ UINT OffsetToLock,UINT SizeToLock,void** ppbData,DWORD Flags) PURE; - STDMETHOD(Unlock)(THIS) PURE; - STDMETHOD(GetDesc)(THIS_ D3DVERTEXBUFFER_DESC *pDesc) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR Name; - UINT Length; - DWORD Usage; - DWORD FVF; - D3DPOOL Pool; - DWORD Priority; - UINT LockCount; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DVertexBuffer9 *LPDIRECT3DVERTEXBUFFER9, *PDIRECT3DVERTEXBUFFER9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DVertexBuffer9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DVertexBuffer9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DVertexBuffer9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DVertexBuffer9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DVertexBuffer9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DVertexBuffer9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DVertexBuffer9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DVertexBuffer9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DVertexBuffer9_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DVertexBuffer9_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DVertexBuffer9_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DVertexBuffer9_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) -#define IDirect3DVertexBuffer9_Unlock(p) (p)->lpVtbl->Unlock(p) -#define IDirect3DVertexBuffer9_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a) -#else -#define IDirect3DVertexBuffer9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DVertexBuffer9_AddRef(p) (p)->AddRef() -#define IDirect3DVertexBuffer9_Release(p) (p)->Release() -#define IDirect3DVertexBuffer9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DVertexBuffer9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DVertexBuffer9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DVertexBuffer9_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DVertexBuffer9_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DVertexBuffer9_GetPriority(p) (p)->GetPriority() -#define IDirect3DVertexBuffer9_PreLoad(p) (p)->PreLoad() -#define IDirect3DVertexBuffer9_GetType(p) (p)->GetType() -#define IDirect3DVertexBuffer9_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) -#define IDirect3DVertexBuffer9_Unlock(p) (p)->Unlock() -#define IDirect3DVertexBuffer9_GetDesc(p,a) (p)->GetDesc(a) -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DIndexBuffer9 - -DECLARE_INTERFACE_(IDirect3DIndexBuffer9, IDirect3DResource9) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DResource9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD(Lock)(THIS_ UINT OffsetToLock,UINT SizeToLock,void** ppbData,DWORD Flags) PURE; - STDMETHOD(Unlock)(THIS) PURE; - STDMETHOD(GetDesc)(THIS_ D3DINDEXBUFFER_DESC *pDesc) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR Name; - UINT Length; - DWORD Usage; - D3DFORMAT Format; - D3DPOOL Pool; - DWORD Priority; - UINT LockCount; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DIndexBuffer9 *LPDIRECT3DINDEXBUFFER9, *PDIRECT3DINDEXBUFFER9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DIndexBuffer9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DIndexBuffer9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DIndexBuffer9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DIndexBuffer9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DIndexBuffer9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DIndexBuffer9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DIndexBuffer9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DIndexBuffer9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DIndexBuffer9_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DIndexBuffer9_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DIndexBuffer9_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DIndexBuffer9_Lock(p,a,b,c,d) (p)->lpVtbl->Lock(p,a,b,c,d) -#define IDirect3DIndexBuffer9_Unlock(p) (p)->lpVtbl->Unlock(p) -#define IDirect3DIndexBuffer9_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a) -#else -#define IDirect3DIndexBuffer9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DIndexBuffer9_AddRef(p) (p)->AddRef() -#define IDirect3DIndexBuffer9_Release(p) (p)->Release() -#define IDirect3DIndexBuffer9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DIndexBuffer9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DIndexBuffer9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DIndexBuffer9_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DIndexBuffer9_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DIndexBuffer9_GetPriority(p) (p)->GetPriority() -#define IDirect3DIndexBuffer9_PreLoad(p) (p)->PreLoad() -#define IDirect3DIndexBuffer9_GetType(p) (p)->GetType() -#define IDirect3DIndexBuffer9_Lock(p,a,b,c,d) (p)->Lock(a,b,c,d) -#define IDirect3DIndexBuffer9_Unlock(p) (p)->Unlock() -#define IDirect3DIndexBuffer9_GetDesc(p,a) (p)->GetDesc(a) -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DSurface9 - -DECLARE_INTERFACE_(IDirect3DSurface9, IDirect3DResource9) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DResource9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE; - STDMETHOD_(DWORD, GetPriority)(THIS) PURE; - STDMETHOD_(void, PreLoad)(THIS) PURE; - STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE; - STDMETHOD(GetContainer)(THIS_ REFIID riid,void** ppContainer) PURE; - STDMETHOD(GetDesc)(THIS_ D3DSURFACE_DESC *pDesc) PURE; - STDMETHOD(LockRect)(THIS_ D3DLOCKED_RECT* pLockedRect,CONST RECT* pRect,DWORD Flags) PURE; - STDMETHOD(UnlockRect)(THIS) PURE; - STDMETHOD(GetDC)(THIS_ HDC *phdc) PURE; - STDMETHOD(ReleaseDC)(THIS_ HDC hdc) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR Name; - UINT Width; - UINT Height; - DWORD Usage; - D3DFORMAT Format; - D3DPOOL Pool; - D3DMULTISAMPLE_TYPE MultiSampleType; - DWORD MultiSampleQuality; - DWORD Priority; - UINT LockCount; - UINT DCCount; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DSurface9 *LPDIRECT3DSURFACE9, *PDIRECT3DSURFACE9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DSurface9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DSurface9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DSurface9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DSurface9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DSurface9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DSurface9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DSurface9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DSurface9_SetPriority(p,a) (p)->lpVtbl->SetPriority(p,a) -#define IDirect3DSurface9_GetPriority(p) (p)->lpVtbl->GetPriority(p) -#define IDirect3DSurface9_PreLoad(p) (p)->lpVtbl->PreLoad(p) -#define IDirect3DSurface9_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DSurface9_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b) -#define IDirect3DSurface9_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a) -#define IDirect3DSurface9_LockRect(p,a,b,c) (p)->lpVtbl->LockRect(p,a,b,c) -#define IDirect3DSurface9_UnlockRect(p) (p)->lpVtbl->UnlockRect(p) -#define IDirect3DSurface9_GetDC(p,a) (p)->lpVtbl->GetDC(p,a) -#define IDirect3DSurface9_ReleaseDC(p,a) (p)->lpVtbl->ReleaseDC(p,a) -#else -#define IDirect3DSurface9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DSurface9_AddRef(p) (p)->AddRef() -#define IDirect3DSurface9_Release(p) (p)->Release() -#define IDirect3DSurface9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DSurface9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DSurface9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DSurface9_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DSurface9_SetPriority(p,a) (p)->SetPriority(a) -#define IDirect3DSurface9_GetPriority(p) (p)->GetPriority() -#define IDirect3DSurface9_PreLoad(p) (p)->PreLoad() -#define IDirect3DSurface9_GetType(p) (p)->GetType() -#define IDirect3DSurface9_GetContainer(p,a,b) (p)->GetContainer(a,b) -#define IDirect3DSurface9_GetDesc(p,a) (p)->GetDesc(a) -#define IDirect3DSurface9_LockRect(p,a,b,c) (p)->LockRect(a,b,c) -#define IDirect3DSurface9_UnlockRect(p) (p)->UnlockRect() -#define IDirect3DSurface9_GetDC(p,a) (p)->GetDC(a) -#define IDirect3DSurface9_ReleaseDC(p,a) (p)->ReleaseDC(a) -#endif - - - - - -#undef INTERFACE -#define INTERFACE IDirect3DVolume9 - -DECLARE_INTERFACE_(IDirect3DVolume9, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DVolume9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE; - STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE; - STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE; - STDMETHOD(GetContainer)(THIS_ REFIID riid,void** ppContainer) PURE; - STDMETHOD(GetDesc)(THIS_ D3DVOLUME_DESC *pDesc) PURE; - STDMETHOD(LockBox)(THIS_ D3DLOCKED_BOX * pLockedVolume,CONST D3DBOX* pBox,DWORD Flags) PURE; - STDMETHOD(UnlockBox)(THIS) PURE; - - #ifdef D3D_DEBUG_INFO - LPCWSTR Name; - UINT Width; - UINT Height; - UINT Depth; - DWORD Usage; - D3DFORMAT Format; - D3DPOOL Pool; - UINT LockCount; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DVolume9 *LPDIRECT3DVOLUME9, *PDIRECT3DVOLUME9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DVolume9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DVolume9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DVolume9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DVolume9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DVolume9_SetPrivateData(p,a,b,c,d) (p)->lpVtbl->SetPrivateData(p,a,b,c,d) -#define IDirect3DVolume9_GetPrivateData(p,a,b,c) (p)->lpVtbl->GetPrivateData(p,a,b,c) -#define IDirect3DVolume9_FreePrivateData(p,a) (p)->lpVtbl->FreePrivateData(p,a) -#define IDirect3DVolume9_GetContainer(p,a,b) (p)->lpVtbl->GetContainer(p,a,b) -#define IDirect3DVolume9_GetDesc(p,a) (p)->lpVtbl->GetDesc(p,a) -#define IDirect3DVolume9_LockBox(p,a,b,c) (p)->lpVtbl->LockBox(p,a,b,c) -#define IDirect3DVolume9_UnlockBox(p) (p)->lpVtbl->UnlockBox(p) -#else -#define IDirect3DVolume9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DVolume9_AddRef(p) (p)->AddRef() -#define IDirect3DVolume9_Release(p) (p)->Release() -#define IDirect3DVolume9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DVolume9_SetPrivateData(p,a,b,c,d) (p)->SetPrivateData(a,b,c,d) -#define IDirect3DVolume9_GetPrivateData(p,a,b,c) (p)->GetPrivateData(a,b,c) -#define IDirect3DVolume9_FreePrivateData(p,a) (p)->FreePrivateData(a) -#define IDirect3DVolume9_GetContainer(p,a,b) (p)->GetContainer(a,b) -#define IDirect3DVolume9_GetDesc(p,a) (p)->GetDesc(a) -#define IDirect3DVolume9_LockBox(p,a,b,c) (p)->LockBox(a,b,c) -#define IDirect3DVolume9_UnlockBox(p) (p)->UnlockBox() -#endif - - - - -#undef INTERFACE -#define INTERFACE IDirect3DQuery9 - -DECLARE_INTERFACE_(IDirect3DQuery9, IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - - /*** IDirect3DQuery9 methods ***/ - STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE; - STDMETHOD_(D3DQUERYTYPE, GetType)(THIS) PURE; - STDMETHOD_(DWORD, GetDataSize)(THIS) PURE; - STDMETHOD(Issue)(THIS_ DWORD dwIssueFlags) PURE; - STDMETHOD(GetData)(THIS_ void* pData,DWORD dwSize,DWORD dwGetDataFlags) PURE; - - #ifdef D3D_DEBUG_INFO - D3DQUERYTYPE Type; - DWORD DataSize; - LPCWSTR CreationCallStack; - #endif -}; - -typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; - -#if !defined(__cplusplus) || defined(CINTERFACE) -#define IDirect3DQuery9_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDirect3DQuery9_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDirect3DQuery9_Release(p) (p)->lpVtbl->Release(p) -#define IDirect3DQuery9_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a) -#define IDirect3DQuery9_GetType(p) (p)->lpVtbl->GetType(p) -#define IDirect3DQuery9_GetDataSize(p) (p)->lpVtbl->GetDataSize(p) -#define IDirect3DQuery9_Issue(p,a) (p)->lpVtbl->Issue(p,a) -#define IDirect3DQuery9_GetData(p,a,b,c) (p)->lpVtbl->GetData(p,a,b,c) -#else -#define IDirect3DQuery9_QueryInterface(p,a,b) (p)->QueryInterface(a,b) -#define IDirect3DQuery9_AddRef(p) (p)->AddRef() -#define IDirect3DQuery9_Release(p) (p)->Release() -#define IDirect3DQuery9_GetDevice(p,a) (p)->GetDevice(a) -#define IDirect3DQuery9_GetType(p) (p)->GetType() -#define IDirect3DQuery9_GetDataSize(p) (p)->GetDataSize() -#define IDirect3DQuery9_Issue(p,a) (p)->Issue(a) -#define IDirect3DQuery9_GetData(p,a,b,c) (p)->GetData(a,b,c) -#endif - - -/**************************************************************************** - * Flags for SetPrivateData method on all D3D9 interfaces - * - * The passed pointer is an IUnknown ptr. The SizeOfData argument to SetPrivateData - * must be set to sizeof(IUnknown*). Direct3D will call AddRef through this - * pointer and Release when the private data is destroyed. The data will be - * destroyed when another SetPrivateData with the same GUID is set, when - * FreePrivateData is called, or when the D3D9 object is freed. - ****************************************************************************/ -#define D3DSPD_IUNKNOWN 0x00000001L - -/**************************************************************************** - * - * Flags for IDirect3D9::CreateDevice's BehaviorFlags - * - ****************************************************************************/ - -#define D3DCREATE_FPU_PRESERVE 0x00000002L -#define D3DCREATE_MULTITHREADED 0x00000004L - -#define D3DCREATE_PUREDEVICE 0x00000010L -#define D3DCREATE_SOFTWARE_VERTEXPROCESSING 0x00000020L -#define D3DCREATE_HARDWARE_VERTEXPROCESSING 0x00000040L -#define D3DCREATE_MIXED_VERTEXPROCESSING 0x00000080L - -#define D3DCREATE_DISABLE_DRIVER_MANAGEMENT 0x00000100L -#define D3DCREATE_ADAPTERGROUP_DEVICE 0x00000200L -#define D3DCREATE_DISABLE_DRIVER_MANAGEMENT_EX 0x00000400L - -// This flag causes the D3D runtime not to alter the focus -// window in any way. Use with caution- the burden of supporting -// focus management events (alt-tab, etc.) falls on the -// application, and appropriate responses (switching display -// mode, etc.) should be coded. -#define D3DCREATE_NOWINDOWCHANGES 0x00000800L - - -/**************************************************************************** - * - * Parameter for IDirect3D9::CreateDevice's Adapter argument - * - ****************************************************************************/ - -#define D3DADAPTER_DEFAULT 0 - -/**************************************************************************** - * - * Flags for IDirect3D9::EnumAdapters - * - ****************************************************************************/ - -#define D3DENUM_WHQL_LEVEL 0x00000002L - -/**************************************************************************** - * - * Maximum number of back-buffers supported in DX9 - * - ****************************************************************************/ - -#define D3DPRESENT_BACK_BUFFERS_MAX 3L - -/**************************************************************************** - * - * Flags for IDirect3DDevice9::SetGammaRamp - * - ****************************************************************************/ - -#define D3DSGR_NO_CALIBRATION 0x00000000L -#define D3DSGR_CALIBRATE 0x00000001L - -/**************************************************************************** - * - * Flags for IDirect3DDevice9::SetCursorPosition - * - ****************************************************************************/ - -#define D3DCURSOR_IMMEDIATE_UPDATE 0x00000001L - -/**************************************************************************** - * - * Flags for IDirect3DSwapChain9::Present - * - ****************************************************************************/ - -#define D3DPRESENT_DONOTWAIT 0x00000001L -#define D3DPRESENT_LINEAR_CONTENT 0x00000002L - -/**************************************************************************** - * - * Flags for DrawPrimitive/DrawIndexedPrimitive - * Also valid for Begin/BeginIndexed - * Also valid for VertexBuffer::CreateVertexBuffer - ****************************************************************************/ - - -/* - * DirectDraw error codes - */ -#define _FACD3D 0x876 -#define MAKE_D3DHRESULT( code ) MAKE_HRESULT( 1, _FACD3D, code ) -#define MAKE_D3DSTATUS( code ) MAKE_HRESULT( 0, _FACD3D, code ) - -/* - * Direct3D Errors - */ -#define D3D_OK S_OK - -#define D3DERR_WRONGTEXTUREFORMAT MAKE_D3DHRESULT(2072) -#define D3DERR_UNSUPPORTEDCOLOROPERATION MAKE_D3DHRESULT(2073) -#define D3DERR_UNSUPPORTEDCOLORARG MAKE_D3DHRESULT(2074) -#define D3DERR_UNSUPPORTEDALPHAOPERATION MAKE_D3DHRESULT(2075) -#define D3DERR_UNSUPPORTEDALPHAARG MAKE_D3DHRESULT(2076) -#define D3DERR_TOOMANYOPERATIONS MAKE_D3DHRESULT(2077) -#define D3DERR_CONFLICTINGTEXTUREFILTER MAKE_D3DHRESULT(2078) -#define D3DERR_UNSUPPORTEDFACTORVALUE MAKE_D3DHRESULT(2079) -#define D3DERR_CONFLICTINGRENDERSTATE MAKE_D3DHRESULT(2081) -#define D3DERR_UNSUPPORTEDTEXTUREFILTER MAKE_D3DHRESULT(2082) -#define D3DERR_CONFLICTINGTEXTUREPALETTE MAKE_D3DHRESULT(2086) -#define D3DERR_DRIVERINTERNALERROR MAKE_D3DHRESULT(2087) - -#define D3DERR_NOTFOUND MAKE_D3DHRESULT(2150) -#define D3DERR_MOREDATA MAKE_D3DHRESULT(2151) -#define D3DERR_DEVICELOST MAKE_D3DHRESULT(2152) -#define D3DERR_DEVICENOTRESET MAKE_D3DHRESULT(2153) -#define D3DERR_NOTAVAILABLE MAKE_D3DHRESULT(2154) -#define D3DERR_OUTOFVIDEOMEMORY MAKE_D3DHRESULT(380) -#define D3DERR_INVALIDDEVICE MAKE_D3DHRESULT(2155) -#define D3DERR_INVALIDCALL MAKE_D3DHRESULT(2156) -#define D3DERR_DRIVERINVALIDCALL MAKE_D3DHRESULT(2157) -#define D3DERR_WASSTILLDRAWING MAKE_D3DHRESULT(540) -#define D3DOK_NOAUTOGEN MAKE_D3DSTATUS(2159) - - -#ifdef __cplusplus -}; -#endif - -#endif /* (DIRECT3D_VERSION >= 0x0900) */ -#endif /* _D3D_H_ */ - diff --git a/Include/d3d9caps.h b/Include/d3d9caps.h index 6489f0e..c10c4cd 100644 --- a/Include/d3d9caps.h +++ b/Include/d3d9caps.h @@ -17,7 +17,7 @@ // include this file content only if compiling for DX9 interfaces #if(DIRECT3D_VERSION >= 0x0900) -#if defined(_X86_) || defined(_IA64) +#if defined(_X86_) || defined(_IA64_) #pragma pack(4) #endif @@ -65,6 +65,59 @@ typedef struct _D3DPSHADERCAPS2_0 #define D3DMIN30SHADERINSTRUCTIONS 512 #define D3DMAX30SHADERINSTRUCTIONS 32768 +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +typedef struct _D3DOVERLAYCAPS +{ + UINT Caps; + UINT MaxOverlayDisplayWidth; + UINT MaxOverlayDisplayHeight; +} D3DOVERLAYCAPS; + +#define D3DOVERLAYCAPS_FULLRANGERGB 0x00000001 +#define D3DOVERLAYCAPS_LIMITEDRANGERGB 0x00000002 +#define D3DOVERLAYCAPS_YCbCr_BT601 0x00000004 +#define D3DOVERLAYCAPS_YCbCr_BT709 0x00000008 +#define D3DOVERLAYCAPS_YCbCr_BT601_xvYCC 0x00000010 +#define D3DOVERLAYCAPS_YCbCr_BT709_xvYCC 0x00000020 +#define D3DOVERLAYCAPS_STRETCHX 0x00000040 +#define D3DOVERLAYCAPS_STRETCHY 0x00000080 + + +typedef struct _D3DCONTENTPROTECTIONCAPS +{ + DWORD Caps; + GUID KeyExchangeType; + UINT BufferAlignmentStart; + UINT BlockAlignmentSize; + ULONGLONG ProtectedMemorySize; +} D3DCONTENTPROTECTIONCAPS; + +#define D3DCPCAPS_SOFTWARE 0x00000001 +#define D3DCPCAPS_HARDWARE 0x00000002 +#define D3DCPCAPS_PROTECTIONALWAYSON 0x00000004 +#define D3DCPCAPS_PARTIALDECRYPTION 0x00000008 +#define D3DCPCAPS_CONTENTKEY 0x00000010 +#define D3DCPCAPS_FRESHENSESSIONKEY 0x00000020 +#define D3DCPCAPS_ENCRYPTEDREADBACK 0x00000040 +#define D3DCPCAPS_ENCRYPTEDREADBACKKEY 0x00000080 +#define D3DCPCAPS_SEQUENTIAL_CTR_IV 0x00000100 +#define D3DCPCAPS_ENCRYPTSLICEDATAONLY 0x00000200 + +DEFINE_GUID(D3DCRYPTOTYPE_AES128_CTR, +0x9b6bd711, 0x4f74, 0x41c9, 0x9e, 0x7b, 0xb, 0xe2, 0xd7, 0xd9, 0x3b, 0x4f); +DEFINE_GUID(D3DCRYPTOTYPE_PROPRIETARY, +0xab4e9afd, 0x1d1c, 0x46e6, 0xa7, 0x2f, 0x8, 0x69, 0x91, 0x7b, 0xd, 0xe8); + +DEFINE_GUID(D3DKEYEXCHANGE_RSAES_OAEP, +0xc1949895, 0xd72a, 0x4a1d, 0x8e, 0x5d, 0xed, 0x85, 0x7d, 0x17, 0x15, 0x20); +DEFINE_GUID(D3DKEYEXCHANGE_DXVA, +0x43d3775c, 0x38e5, 0x4924, 0x8d, 0x86, 0xd3, 0xfc, 0xcf, 0x15, 0x3e, 0x9b); + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + typedef struct _D3DCAPS9 { /* Device Info */ @@ -167,6 +220,7 @@ typedef struct _D3DCAPS9 // // Caps // +#define D3DCAPS_OVERLAY 0x00000800L #define D3DCAPS_READ_SCANLINE 0x00020000L // @@ -179,6 +233,14 @@ typedef struct _D3DCAPS9 #define D3DCAPS2_DYNAMICTEXTURES 0x20000000L #define D3DCAPS2_CANAUTOGENMIPMAP 0x40000000L +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +#define D3DCAPS2_CANSHARERESOURCE 0x80000000L + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + // // Caps3 // @@ -195,6 +257,7 @@ typedef struct _D3DCAPS9 #define D3DCAPS3_COPY_TO_VIDMEM 0x00000100L /* Device can acclerate copies from sysmem to local vidmem */ #define D3DCAPS3_COPY_TO_SYSTEMMEM 0x00000200L /* Device can acclerate copies from local vidmem to sysmem */ +#define D3DCAPS3_DXVAHD 0x00000400L // @@ -261,6 +324,15 @@ typedef struct _D3DCAPS9 #define D3DPMISCCAPS_MRTPOSTPIXELSHADERBLENDING 0x00080000L /* Device supports post-pixel shader operations for MRT */ #define D3DPMISCCAPS_FOGVERTEXCLAMPED 0x00100000L /* Device clamps fog blend factor per vertex */ +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +#define D3DPMISCCAPS_POSTBLENDSRGBCONVERT 0x00200000L /* Indicates device can perform conversion to sRGB after blending. */ + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + + // // LineCaps // @@ -321,6 +393,16 @@ typedef struct _D3DCAPS9 #define D3DPBLENDCAPS_BOTHINVSRCALPHA 0x00001000L #define D3DPBLENDCAPS_BLENDFACTOR 0x00002000L /* Supports both D3DBLEND_BLENDFACTOR and D3DBLEND_INVBLENDFACTOR */ +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +#define D3DPBLENDCAPS_SRCCOLOR2 0x00004000L +#define D3DPBLENDCAPS_INVSRCCOLOR2 0x00008000L + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + + // // ShadeCaps // @@ -364,6 +446,15 @@ typedef struct _D3DCAPS9 #define D3DPTFILTERCAPS_MINFGAUSSIANQUAD 0x00001000L #define D3DPTFILTERCAPS_MIPFPOINT 0x00010000L /* Mip Filter */ #define D3DPTFILTERCAPS_MIPFLINEAR 0x00020000L + +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +#define D3DPTFILTERCAPS_CONVOLUTIONMONO 0x00040000L /* Min and Mag for the convolution mono filter */ + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + #define D3DPTFILTERCAPS_MAGFPOINT 0x01000000L /* Mag Filter */ #define D3DPTFILTERCAPS_MAGFLINEAR 0x02000000L #define D3DPTFILTERCAPS_MAGFANISOTROPIC 0x04000000L diff --git a/Include/d3d9types.h b/Include/d3d9types.h index 4c2108f..4dd3cfa 100644 --- a/Include/d3d9types.h +++ b/Include/d3d9types.h @@ -23,7 +23,7 @@ #pragma warning(push) #endif #pragma warning(disable:4201) // anonymous unions warning -#if defined(_X86_) || defined(_IA64) +#if defined(_X86_) || defined(_IA64_) #pragma pack(4) #endif @@ -224,6 +224,14 @@ typedef enum _D3DBLEND { D3DBLEND_BOTHINVSRCALPHA = 13, D3DBLEND_BLENDFACTOR = 14, /* Only supported if D3DPBLENDCAPS_BLENDFACTOR is on */ D3DBLEND_INVBLENDFACTOR = 15, /* Only supported if D3DPBLENDCAPS_BLENDFACTOR is on */ +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + + D3DBLEND_SRCCOLOR2 = 16, + D3DBLEND_INVSRCCOLOR2 = 17, + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ D3DBLEND_FORCE_DWORD = 0x7fffffff, /* force 32-bit size enum */ } D3DBLEND; @@ -625,6 +633,13 @@ typedef enum _D3DTEXTUREFILTERTYPE D3DTEXF_ANISOTROPIC = 3, // anisotropic D3DTEXF_PYRAMIDALQUAD = 6, // 4-sample tent D3DTEXF_GAUSSIANQUAD = 7, // 4-sample gaussian +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + + D3DTEXF_CONVOLUTIONMONO = 8, // Convolution filter for monochrome textures + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ D3DTEXF_FORCE_DWORD = 0x7fffffff, // force 32-bit size enum } D3DTEXTUREFILTERTYPE; @@ -1377,6 +1392,16 @@ typedef enum _D3DFORMAT D3DFMT_D32F_LOCKABLE = 82, D3DFMT_D24FS8 = 83, +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + + /* Z-Stencil formats valid for CPU access */ + D3DFMT_D32_LOCKABLE = 84, + D3DFMT_S8_LOCKABLE = 85, + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + D3DFMT_L16 = 81, @@ -1402,6 +1427,22 @@ typedef enum _D3DFORMAT D3DFMT_CxV8U8 = 117, +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + + // Monochrome 1 bit per pixel format + D3DFMT_A1 = 118, + + // 2.8 biased fixed point + D3DFMT_A2B10G10R10_XR_BIAS = 119, + + + // Binary format indicating that the data has no inherent type + D3DFMT_BINARYBUFFER = 199, + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + D3DFMT_FORCE_DWORD =0x7fffffff } D3DFORMAT; @@ -1432,6 +1473,13 @@ typedef enum _D3DSWAPEFFECT D3DSWAPEFFECT_FLIP = 2, D3DSWAPEFFECT_COPY = 3, +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + D3DSWAPEFFECT_OVERLAY = 4, + D3DSWAPEFFECT_FLIPEX = 5, +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + D3DSWAPEFFECT_FORCE_DWORD = 0x7fffffff } D3DSWAPEFFECT; @@ -1480,6 +1528,20 @@ typedef struct _D3DPRESENT_PARAMETERS_ #define D3DPRESENTFLAG_DEVICECLIP 0x00000004 #define D3DPRESENTFLAG_VIDEO 0x00000010 +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +#define D3DPRESENTFLAG_NOAUTOROTATE 0x00000020 +#define D3DPRESENTFLAG_UNPRUNEDMODE 0x00000040 +#define D3DPRESENTFLAG_OVERLAY_LIMITEDRGB 0x00000080 +#define D3DPRESENTFLAG_OVERLAY_YCbCr_BT709 0x00000100 +#define D3DPRESENTFLAG_OVERLAY_YCbCr_xvYCC 0x00000200 +#define D3DPRESENTFLAG_RESTRICTED_CONTENT 0x00000400 +#define D3DPRESENTFLAG_RESTRICT_SHARED_RESOURCE_DRIVER 0x00000800 + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + /* Gamma Ramp: Same as DX7 */ typedef struct _D3DGAMMARAMP @@ -1508,7 +1570,7 @@ typedef enum _D3DRESOURCETYPE { D3DRTYPE_VOLUMETEXTURE = 4, D3DRTYPE_CUBETEXTURE = 5, D3DRTYPE_VERTEXBUFFER = 6, - D3DRTYPE_INDEXBUFFER = 7, + D3DRTYPE_INDEXBUFFER = 7, //if this changes, change _D3DDEVINFO_RESOURCEMANAGER definition D3DRTYPE_FORCE_DWORD = 0x7fffffff @@ -1519,6 +1581,14 @@ typedef enum _D3DRESOURCETYPE { #define D3DUSAGE_DEPTHSTENCIL (0x00000002L) #define D3DUSAGE_DYNAMIC (0x00000200L) +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +#define D3DUSAGE_NONSECURE (0x00800000L) + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + // When passed to CheckDeviceFormat, D3DUSAGE_AUTOGENMIPMAP may return // D3DOK_NOAUTOGEN if the device doesn't support autogeneration for that format. // D3DOK_NOAUTOGEN is a success code, not a failure code... the SUCCEEDED and FAILED macros @@ -1543,6 +1613,23 @@ typedef enum _D3DRESOURCETYPE { #define D3DUSAGE_RTPATCHES (0x00000080L) #define D3DUSAGE_NPATCHES (0x00000100L) +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +#define D3DUSAGE_TEXTAPI (0x10000000L) +#define D3DUSAGE_RESTRICTED_CONTENT (0x00000800L) +#define D3DUSAGE_RESTRICT_SHARED_RESOURCE (0x00002000L) +#define D3DUSAGE_RESTRICT_SHARED_RESOURCE_DRIVER (0x00001000L) + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + + + + + + + @@ -1756,6 +1843,10 @@ typedef enum _D3DQUERYTYPE { D3DQUERYTYPE_PIXELTIMINGS = 16, /* D3DISSUE_BEGIN, D3DISSUE_END */ D3DQUERYTYPE_BANDWIDTHTIMINGS = 17, /* D3DISSUE_BEGIN, D3DISSUE_END */ D3DQUERYTYPE_CACHEUTILIZATION = 18, /* D3DISSUE_BEGIN, D3DISSUE_END */ +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + D3DQUERYTYPE_MEMORYPRESSURE = 19, /* D3DISSUE_BEGIN, D3DISSUE_END */ +#endif // !D3D_DISABLE_9EX } D3DQUERYTYPE; // Flags field for Issue @@ -1788,7 +1879,11 @@ typedef struct _D3DRESOURCESTATS typedef struct _D3DDEVINFO_RESOURCEMANAGER { +#ifndef WOW64_ENUM_WORKAROUND D3DRESOURCESTATS stats[D3DRTYPECOUNT]; +#else + D3DRESOURCESTATS stats[8]; +#endif } D3DDEVINFO_RESOURCEMANAGER, *LPD3DDEVINFO_RESOURCEMANAGER; typedef struct _D3DDEVINFO_D3DVERTEXSTATS @@ -1799,7 +1894,7 @@ typedef struct _D3DDEVINFO_D3DVERTEXSTATS typedef struct _D3DDEVINFO_VCACHE { - DWORD Pattern; /* bit pattern, return value must be FOUR_CC(‘C’, ‘A’, ‘C’, ‘H’) */ + DWORD Pattern; /* bit pattern, return value must be FOUR_CC('C', 'A', 'C', 'H') */ DWORD OptMethod; /* optimization method 0 means longest strips, 1 means vertex cache based */ DWORD CacheSize; /* cache size to optimize for (only required if type is 1) */ DWORD MagicNumber; /* used to determine when to restart strips (only required if type is 1)*/ @@ -1843,6 +1938,472 @@ typedef struct _D3DDEVINFO_D3D9CACHEUTILIZATION FLOAT PostTransformVertexCacheHitRate; } D3DDEVINFO_D3D9CACHEUTILIZATION; +/* D3D9Ex only -- */ +#if !defined(D3D_DISABLE_9EX) + +typedef struct _D3DMEMORYPRESSURE +{ + UINT64 BytesEvictedFromProcess; + UINT64 SizeOfInefficientAllocation; + DWORD LevelOfEfficiency; +} D3DMEMORYPRESSURE; + +typedef enum _D3DCOMPOSERECTSOP{ + D3DCOMPOSERECTS_COPY = 1, + D3DCOMPOSERECTS_OR = 2, + D3DCOMPOSERECTS_AND = 3, + D3DCOMPOSERECTS_NEG = 4, + D3DCOMPOSERECTS_FORCE_DWORD = 0x7fffffff, /* force 32-bit size enum */ +} D3DCOMPOSERECTSOP; + +typedef struct _D3DCOMPOSERECTDESC +{ + USHORT X, Y; // Top-left coordinates of a rect in the source surface + USHORT Width, Height; // Dimensions of the rect +} D3DCOMPOSERECTDESC; + +typedef struct _D3DCOMPOSERECTDESTINATION +{ + USHORT SrcRectIndex; // Index of D3DCOMPOSERECTDESC + USHORT Reserved; // For alignment + SHORT X, Y; // Top-left coordinates of the rect in the destination surface +} D3DCOMPOSERECTDESTINATION; + +#define D3DCOMPOSERECTS_MAXNUMRECTS 0xFFFF +#define D3DCONVOLUTIONMONO_MAXWIDTH 7 +#define D3DCONVOLUTIONMONO_MAXHEIGHT D3DCONVOLUTIONMONO_MAXWIDTH +#define D3DFMT_A1_SURFACE_MAXWIDTH 8192 +#define D3DFMT_A1_SURFACE_MAXHEIGHT 2048 + + +typedef struct _D3DPRESENTSTATS { + UINT PresentCount; + UINT PresentRefreshCount; + UINT SyncRefreshCount; + LARGE_INTEGER SyncQPCTime; + LARGE_INTEGER SyncGPUTime; +} D3DPRESENTSTATS; + +typedef enum D3DSCANLINEORDERING +{ + D3DSCANLINEORDERING_UNKNOWN = 0, + D3DSCANLINEORDERING_PROGRESSIVE = 1, + D3DSCANLINEORDERING_INTERLACED = 2, +} D3DSCANLINEORDERING; + + +typedef struct D3DDISPLAYMODEEX +{ + UINT Size; + UINT Width; + UINT Height; + UINT RefreshRate; + D3DFORMAT Format; + D3DSCANLINEORDERING ScanLineOrdering; +} D3DDISPLAYMODEEX; + +typedef struct D3DDISPLAYMODEFILTER +{ + UINT Size; + D3DFORMAT Format; + D3DSCANLINEORDERING ScanLineOrdering; +} D3DDISPLAYMODEFILTER; + + +typedef enum D3DDISPLAYROTATION +{ + D3DDISPLAYROTATION_IDENTITY = 1, // No rotation. + D3DDISPLAYROTATION_90 = 2, // Rotated 90 degrees. + D3DDISPLAYROTATION_180 = 3, // Rotated 180 degrees. + D3DDISPLAYROTATION_270 = 4 // Rotated 270 degrees. +} D3DDISPLAYROTATION; + +/* For use in ID3DResource9::SetPriority calls */ +#define D3D9_RESOURCE_PRIORITY_MINIMUM 0x28000000 +#define D3D9_RESOURCE_PRIORITY_LOW 0x50000000 +#define D3D9_RESOURCE_PRIORITY_NORMAL 0x78000000 +#define D3D9_RESOURCE_PRIORITY_HIGH 0xa0000000 +#define D3D9_RESOURCE_PRIORITY_MAXIMUM 0xc8000000 + +#define D3D_OMAC_SIZE 16 + +typedef struct _D3D_OMAC +{ + BYTE Omac[D3D_OMAC_SIZE]; +} D3D_OMAC; + +typedef enum _D3DAUTHENTICATEDCHANNELTYPE +{ + D3DAUTHENTICATEDCHANNEL_D3D9 = 1, + D3DAUTHENTICATEDCHANNEL_DRIVER_SOFTWARE = 2, + D3DAUTHENTICATEDCHANNEL_DRIVER_HARDWARE = 3, +} D3DAUTHENTICATEDCHANNELTYPE; + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERY_INPUT +{ + GUID QueryType; + HANDLE hChannel; + UINT SequenceNumber; +} D3DAUTHENTICATEDCHANNEL_QUERY_INPUT; + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT +{ + D3D_OMAC omac; + GUID QueryType; + HANDLE hChannel; + UINT SequenceNumber; + HRESULT ReturnCode; +} D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT; + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_PROTECTION, +0xa84eb584, 0xc495, 0x48aa, 0xb9, 0x4d, 0x8b, 0xd2, 0xd6, 0xfb, 0xce, 0x5); + +typedef struct _D3DAUTHENTICATEDCHANNEL_PROTECTION_FLAGS +{ + union + { + struct + { + UINT ProtectionEnabled : 1; + UINT OverlayOrFullscreenRequired : 1; + UINT Reserved : 30; + }; + UINT Value; + }; + +} D3DAUTHENTICATEDCHANNEL_PROTECTION_FLAGS; + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYPROTECTION_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + D3DAUTHENTICATEDCHANNEL_PROTECTION_FLAGS ProtectionFlags; + +} D3DAUTHENTICATEDCHANNEL_QUERYPROTECTION_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_CHANNELTYPE, +0xbc1b18a5, 0xb1fb, 0x42ab, 0xbd, 0x94, 0xb5, 0x82, 0x8b, 0x4b, 0xf7, 0xbe); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYCHANNELTYPE_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + D3DAUTHENTICATEDCHANNELTYPE ChannelType; + +} D3DAUTHENTICATEDCHANNEL_QUERYCHANNELTYPE_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_DEVICEHANDLE, +0xec1c539d, 0x8cff, 0x4e2a, 0xbc, 0xc4, 0xf5, 0x69, 0x2f, 0x99, 0xf4, 0x80); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYDEVICEHANDLE_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + HANDLE DeviceHandle; + +} D3DAUTHENTICATEDCHANNEL_QUERYDEVICEHANDLE_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_CRYPTOSESSION, +0x2634499e, 0xd018, 0x4d74, 0xac, 0x17, 0x7f, 0x72, 0x40, 0x59, 0x52, 0x8d); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYCRYPTOSESSION_INPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_INPUT Input; + + HANDLE DXVA2DecodeHandle; + +} D3DAUTHENTICATEDCHANNEL_QUERYCRYPTOSESSION_INPUT; + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYCRYPTOSESSION_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + HANDLE DXVA2DecodeHandle; + HANDLE CryptoSessionHandle; + HANDLE DeviceHandle; + +} D3DAUTHENTICATEDCHANNEL_QUERYCRYPTOSESSION_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_RESTRICTEDSHAREDRESOURCEPROCESSCOUNT, +0xdb207b3, 0x9450, 0x46a6, 0x82, 0xde, 0x1b, 0x96, 0xd4, 0x4f, 0x9c, 0xf2); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESSCOUNT_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + UINT NumRestrictedSharedResourceProcesses; + +} D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESSCOUNT_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_RESTRICTEDSHAREDRESOURCEPROCESS, +0x649bbadb, 0xf0f4, 0x4639, 0xa1, 0x5b, 0x24, 0x39, 0x3f, 0xc3, 0xab, 0xac); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESS_INPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_INPUT Input; + + UINT ProcessIndex; + +} D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESS_INPUT; + +typedef enum _D3DAUTHENTICATEDCHANNEL_PROCESSIDENTIFIERTYPE +{ + PROCESSIDTYPE_UNKNOWN = 0, + PROCESSIDTYPE_DWM = 1, + PROCESSIDTYPE_HANDLE = 2 +} D3DAUTHENTICATEDCHANNEL_PROCESSIDENTIFIERTYPE; + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESS_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + UINT ProcessIndex; + D3DAUTHENTICATEDCHANNEL_PROCESSIDENTIFIERTYPE ProcessIdentifer; + HANDLE ProcessHandle; + +} D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESS_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_UNRESTRICTEDPROTECTEDSHAREDRESOURCECOUNT, +0x12f0bd6, 0xe662, 0x4474, 0xbe, 0xfd, 0xaa, 0x53, 0xe5, 0x14, 0x3c, 0x6d); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYUNRESTRICTEDPROTECTEDSHAREDRESOURCECOUNT_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + UINT NumUnrestrictedProtectedSharedResources; + +} D3DAUTHENTICATEDCHANNEL_QUERYUNRESTRICTEDPROTECTEDSHAREDRESOURCECOUNT_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_OUTPUTIDCOUNT, +0x2c042b5e, 0x8c07, 0x46d5, 0xaa, 0xbe, 0x8f, 0x75, 0xcb, 0xad, 0x4c, 0x31); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTIDCOUNT_INPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_INPUT Input; + + HANDLE DeviceHandle; + HANDLE CryptoSessionHandle; + +} D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTIDCOUNT_INPUT; + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTIDCOUNT_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + HANDLE DeviceHandle; + HANDLE CryptoSessionHandle; + UINT NumOutputIDs; + +} D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTIDCOUNT_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_OUTPUTID, +0x839ddca3, 0x9b4e, 0x41e4, 0xb0, 0x53, 0x89, 0x2b, 0xd2, 0xa1, 0x1e, 0xe7); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTID_INPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_INPUT Input; + + HANDLE DeviceHandle; + HANDLE CryptoSessionHandle; + UINT OutputIDIndex; + +} D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTID_INPUT; + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTID_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + HANDLE DeviceHandle; + HANDLE CryptoSessionHandle; + UINT OutputIDIndex; + UINT64 OutputID; + +} D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTID_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_ACCESSIBILITYATTRIBUTES, +0x6214d9d2, 0x432c, 0x4abb, 0x9f, 0xce, 0x21, 0x6e, 0xea, 0x26, 0x9e, 0x3b); + +typedef enum _D3DBUSTYPE +{ + D3DBUSTYPE_OTHER = 0x00000000, + D3DBUSTYPE_PCI = 0x00000001, + D3DBUSTYPE_PCIX = 0x00000002, + D3DBUSTYPE_PCIEXPRESS = 0x00000003, + D3DBUSTYPE_AGP = 0x00000004, + D3DBUSIMPL_MODIFIER_INSIDE_OF_CHIPSET = 0x00010000, + D3DBUSIMPL_MODIFIER_TRACKS_ON_MOTHER_BOARD_TO_CHIP = 0x00020000, + D3DBUSIMPL_MODIFIER_TRACKS_ON_MOTHER_BOARD_TO_SOCKET = 0x00030000, + D3DBUSIMPL_MODIFIER_DAUGHTER_BOARD_CONNECTOR = 0x00040000, + D3DBUSIMPL_MODIFIER_DAUGHTER_BOARD_CONNECTOR_INSIDE_OF_NUAE = 0x00050000, + D3DBUSIMPL_MODIFIER_NON_STANDARD = 0x80000000, +} D3DBUSTYPE; + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYINFOBUSTYPE_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + D3DBUSTYPE BusType; + BOOL bAccessibleInContiguousBlocks; + BOOL bAccessibleInNonContiguousBlocks; + +} D3DAUTHENTICATEDCHANNEL_QUERYINFOBUSTYPE_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_ENCRYPTIONWHENACCESSIBLEGUIDCOUNT, +0xb30f7066, 0x203c, 0x4b07, 0x93, 0xfc, 0xce, 0xaa, 0xfd, 0x61, 0x24, 0x1e); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUIDCOUNT_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + UINT NumEncryptionGuids; + +} D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUIDCOUNT_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_ENCRYPTIONWHENACCESSIBLEGUID, +0xf83a5958, 0xe986, 0x4bda, 0xbe, 0xb0, 0x41, 0x1f, 0x6a, 0x7a, 0x1, 0xb7); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUID_INPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_INPUT Input; + + UINT EncryptionGuidIndex; + +} D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUID_INPUT; + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUID_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + UINT EncryptionGuidIndex; + GUID EncryptionGuid; + +} D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUID_OUTPUT; + + +DEFINE_GUID(D3DAUTHENTICATEDQUERY_CURRENTENCRYPTIONWHENACCESSIBLE, +0xec1791c7, 0xdad3, 0x4f15, 0x9e, 0xc3, 0xfa, 0xa9, 0x3d, 0x60, 0xd4, 0xf0); + +typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYUNCOMPRESSEDENCRYPTIONLEVEL_OUTPUT +{ + D3DAUTHENTICATEDCHANNEL_QUERY_OUTPUT Output; + + GUID EncryptionGuid; + +} D3DAUTHENTICATEDCHANNEL_QUERYUNCOMPRESSEDENCRYPTIONLEVEL_OUTPUT; + + +typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGURE_INPUT +{ + D3D_OMAC omac; + GUID ConfigureType; + HANDLE hChannel; + UINT SequenceNumber; + +} D3DAUTHENTICATEDCHANNEL_CONFIGURE_INPUT; + +typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGURE_OUTPUT +{ + D3D_OMAC omac; + GUID ConfigureType; + HANDLE hChannel; + UINT SequenceNumber; + HRESULT ReturnCode; + +} D3DAUTHENTICATEDCHANNEL_CONFIGURE_OUTPUT; + +DEFINE_GUID(D3DAUTHENTICATEDCONFIGURE_INITIALIZE, +0x6114bdb, 0x3523, 0x470a, 0x8d, 0xca, 0xfb, 0xc2, 0x84, 0x51, 0x54, 0xf0); + +typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGUREINITIALIZE +{ + D3DAUTHENTICATEDCHANNEL_CONFIGURE_INPUT Parameters; + + UINT StartSequenceQuery; + UINT StartSequenceConfigure; + +} D3DAUTHENTICATEDCHANNEL_CONFIGUREINITIALIZE; + + +DEFINE_GUID(D3DAUTHENTICATEDCONFIGURE_PROTECTION, +0x50455658, 0x3f47, 0x4362, 0xbf, 0x99, 0xbf, 0xdf, 0xcd, 0xe9, 0xed, 0x29); + +typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGUREPROTECTION +{ + D3DAUTHENTICATEDCHANNEL_CONFIGURE_INPUT Parameters; + + D3DAUTHENTICATEDCHANNEL_PROTECTION_FLAGS Protections; + +} D3DAUTHENTICATEDCHANNEL_CONFIGUREPROTECTION; + + +DEFINE_GUID(D3DAUTHENTICATEDCONFIGURE_CRYPTOSESSION, +0x6346cc54, 0x2cfc, 0x4ad4, 0x82, 0x24, 0xd1, 0x58, 0x37, 0xde, 0x77, 0x0); + +typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGURECRYPTOSESSION +{ + D3DAUTHENTICATEDCHANNEL_CONFIGURE_INPUT Parameters; + + HANDLE DXVA2DecodeHandle; + HANDLE CryptoSessionHandle; + HANDLE DeviceHandle; + +} D3DAUTHENTICATEDCHANNEL_CONFIGURECRYPTOSESSION; + + +DEFINE_GUID(D3DAUTHENTICATEDCONFIGURE_SHAREDRESOURCE, +0x772d047, 0x1b40, 0x48e8, 0x9c, 0xa6, 0xb5, 0xf5, 0x10, 0xde, 0x9f, 0x1); + +typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGURESHAREDRESOURCE +{ + D3DAUTHENTICATEDCHANNEL_CONFIGURE_INPUT Parameters; + + D3DAUTHENTICATEDCHANNEL_PROCESSIDENTIFIERTYPE ProcessIdentiferType; + HANDLE ProcessHandle; + BOOL AllowAccess; + +} D3DAUTHENTICATEDCHANNEL_CONFIGURESHAREDRESOURCE; + + +DEFINE_GUID(D3DAUTHENTICATEDCONFIGURE_ENCRYPTIONWHENACCESSIBLE, +0x41fff286, 0x6ae0, 0x4d43, 0x9d, 0x55, 0xa4, 0x6e, 0x9e, 0xfd, 0x15, 0x8a); + +typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGUREUNCOMPRESSEDENCRYPTION +{ + D3DAUTHENTICATEDCHANNEL_CONFIGURE_INPUT Parameters; + + GUID EncryptionGuid; + +} D3DAUTHENTICATEDCHANNEL_CONFIGUREUNCOMPRESSEDENCRYPTION; + +typedef struct _D3DENCRYPTED_BLOCK_INFO +{ + UINT NumEncryptedBytesAtBeginning; + UINT NumBytesInSkipPattern; + UINT NumBytesInEncryptPattern; +} D3DENCRYPTED_BLOCK_INFO; + +typedef struct _D3DAES_CTR_IV +{ + UINT64 IV; // Big-Endian IV + UINT64 Count; // Big-Endian Block Count +} D3DAES_CTR_IV; + + + +#endif // !D3D_DISABLE_9EX +/* -- D3D9Ex only */ + #pragma pack() #if _MSC_VER >= 1200 #pragma warning(pop) diff --git a/Include/dxdiag.txt b/Include/dxdiag.txt deleted file mode 100644 index 3def6ee..0000000 --- a/Include/dxdiag.txt +++ /dev/null @@ -1,185 +0,0 @@ -/*==========================================================================; - * - * Copyright (C) Microsoft Corporation. All Rights Reserved. - * - * File: dxdiag.h - * Content: DirectX Diagnostic Tool include file - * - ****************************************************************************/ - -#ifndef _DXDIAG_H_ -#define _DXDIAG_H_ - -#include // for DECLARE_INTERFACE_ and HRESULT - -// This identifier is passed to IDxDiagProvider::Initialize in order to ensure that an -// application was built against the correct header files. This number is -// incremented whenever a header (or other) change would require applications -// to be rebuilt. If the version doesn't match, IDxDiagProvider::Initialize will fail. -// (The number itself has no meaning.) -#define DXDIAG_DX9_SDK_VERSION 111 - -#ifdef __cplusplus -extern "C" { -#endif - - -/**************************************************************************** - * - * DxDiag Errors - * - ****************************************************************************/ -#define DXDIAG_E_INSUFFICIENT_BUFFER ((HRESULT)0x8007007AL) // HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER) - - -/**************************************************************************** - * - * DxDiag CLSIDs - * - ****************************************************************************/ - -// {A65B8071-3BFE-4213-9A5B-491DA4461CA7} -DEFINE_GUID(CLSID_DxDiagProvider, -0xA65B8071, 0x3BFE, 0x4213, 0x9A, 0x5B, 0x49, 0x1D, 0xA4, 0x46, 0x1C, 0xA7); - - -/**************************************************************************** - * - * DxDiag Interface IIDs - * - ****************************************************************************/ - -// {9C6B4CB0-23F8-49CC-A3ED-45A55000A6D2} -DEFINE_GUID(IID_IDxDiagProvider, -0x9C6B4CB0, 0x23F8, 0x49CC, 0xA3, 0xED, 0x45, 0xA5, 0x50, 0x00, 0xA6, 0xD2); - -// {0x7D0F462F-0x4064-0x4862-BC7F-933E5058C10F} -DEFINE_GUID(IID_IDxDiagContainer, -0x7D0F462F, 0x4064, 0x4862, 0xBC, 0x7F, 0x93, 0x3E, 0x50, 0x58, 0xC1, 0x0F); - - -/**************************************************************************** - * - * DxDiag Interface Pointer definitions - * - ****************************************************************************/ - -typedef struct IDxDiagProvider *LPDXDIAGPROVIDER, *PDXDIAGPROVIDER; - -typedef struct IDxDiagContainer *LPDXDIAGCONTAINER, *PDXDIAGCONTAINER; - - -/**************************************************************************** - * - * DxDiag Structures - * - ****************************************************************************/ - -typedef struct _DXDIAG_INIT_PARAMS -{ - DWORD dwSize; // Size of this structure. - DWORD dwDxDiagHeaderVersion; // Pass in DXDIAG_DX9_SDK_VERSION. This verifies - // the header and dll are correctly matched. - BOOL bAllowWHQLChecks; // If true, allow dxdiag to check if drivers are - // digital signed as logo'd by WHQL which may - // connect via internet to update WHQL certificates. - VOID* pReserved; // Reserved. Must be NULL. -} DXDIAG_INIT_PARAMS; - - -/**************************************************************************** - * - * DxDiag Application Interfaces - * - ****************************************************************************/ - -// -// COM definition for IDxDiagProvider -// -#undef INTERFACE // External COM Implementation -#define INTERFACE IDxDiagProvider -DECLARE_INTERFACE_(IDxDiagProvider,IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID *ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - /*** IDxDiagProvider methods ***/ - STDMETHOD(Initialize) (THIS_ DXDIAG_INIT_PARAMS* pParams) PURE; - STDMETHOD(GetRootContainer) (THIS_ IDxDiagContainer **ppInstance) PURE; -}; - - -// -// COM definition for IDxDiagContainer -// -#undef INTERFACE // External COM Implementation -#define INTERFACE IDxDiagContainer -DECLARE_INTERFACE_(IDxDiagContainer,IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID *ppvObj) PURE; - STDMETHOD_(ULONG,AddRef) (THIS) PURE; - STDMETHOD_(ULONG,Release) (THIS) PURE; - - /*** IDxDiagContainer methods ***/ - STDMETHOD(GetNumberOfChildContainers) (THIS_ DWORD *pdwCount) PURE; - STDMETHOD(EnumChildContainerNames) (THIS_ DWORD dwIndex, LPWSTR pwszContainer, DWORD cchContainer) PURE; - STDMETHOD(GetChildContainer) (THIS_ LPCWSTR pwszContainer, IDxDiagContainer **ppInstance) PURE; - STDMETHOD(GetNumberOfProps) (THIS_ DWORD *pdwCount) PURE; - STDMETHOD(EnumPropNames) (THIS_ DWORD dwIndex, LPWSTR pwszPropName, DWORD cchPropName) PURE; - STDMETHOD(GetProp) (THIS_ LPCWSTR pwszPropName, VARIANT *pvarProp) PURE; -}; - - -/**************************************************************************** - * - * DxDiag application interface macros - * - ****************************************************************************/ - -#if !defined(__cplusplus) || defined(CINTERFACE) - -#define IDxDiagProvider_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDxDiagProvider_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDxDiagProvider_Release(p) (p)->lpVtbl->Release(p) -#define IDxDiagProvider_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b) -#define IDxDiagProvider_GetRootContainer(p,a) (p)->lpVtbl->GetRootContainer(p,a) - -#define IDxDiagContainer_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IDxDiagContainer_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IDxDiagContainer_Release(p) (p)->lpVtbl->Release(p) -#define IDxDiagContainer_GetNumberOfChildContainers(p,a) (p)->lpVtbl->GetNumberOfChildContainers(p,a) -#define IDxDiagContainer_EnumChildContainerNames(p,a,b,c) (p)->lpVtbl->EnumChildContainerNames(p,a,b,c) -#define IDxDiagContainer_GetChildContainer(p,a,b) (p)->lpVtbl->GetChildContainer(p,a,b) -#define IDxDiagContainer_GetNumberOfProps(p,a) (p)->lpVtbl->GetNumberOfProps(p,a) -#define IDxDiagContainer_EnumProps(p,a,b) (p)->lpVtbl->EnumProps(p,a,b,c) -#define IDxDiagContainer_GetProp(p,a,b) (p)->lpVtbl->GetProp(p,a,b) - -#else /* C++ */ - -#define IDxDiagProvider_QueryInterface(p,a,b) (p)->QueryInterface(p,a,b) -#define IDxDiagProvider_AddRef(p) (p)->AddRef(p) -#define IDxDiagProvider_Release(p) (p)->Release(p) -#define IDxDiagProvider_Initialize(p,a,b) (p)->Initialize(p,a,b) -#define IDxDiagProvider_GetRootContainer(p,a) (p)->GetRootContainer(p,a) - -#define IDxDiagContainer_QueryInterface(p,a,b) (p)->QueryInterface(p,a,b) -#define IDxDiagContainer_AddRef(p) (p)->AddRef(p) -#define IDxDiagContainer_Release(p) (p)->Release(p) -#define IDxDiagContainer_GetNumberOfChildContainers(p,a) (p)->GetNumberOfChildContainers(p,a) -#define IDxDiagContainer_EnumChildContainerNames(p,a,b,c) (p)->EnumChildContainerNames(p,a,b,c) -#define IDxDiagContainer_GetChildContainer(p,a,b) (p)->GetChildContainer(p,a,b) -#define IDxDiagContainer_GetNumberOfProps(p,a) (p)->GetNumberOfProps(p,a) -#define IDxDiagContainer_EnumProps(p,a,b) (p)->EnumProps(p,a,b,c) -#define IDxDiagContainer_GetProp(p,a,b) (p)->GetProp(p,a,b) - -#endif - - -#ifdef __cplusplus -} -#endif - -#endif /* _DXDIAG_H_ */ diff --git a/Include/dxwnd.h b/Include/dxwnd.h index aa7bac4..8dcde05 100644 --- a/Include/dxwnd.h +++ b/Include/dxwnd.h @@ -80,6 +80,8 @@ // third flags DWORD dxw.dwFlags3: #define FORCEHOOKOPENGL 0x00000001 // loads OpenGL32.dll and hooks it #define MARKBLIT 0x00000002 // higlights the blit to primary surface operation by surroundig the rect in color +#define HOOKDLLS 0x00000004 // Hook all DLLs referenced in PE +#define SUPPRESSD3DEXT 0x00000008 // Disables extended d3d APIs for Vista/Win7/Win8 platforms // logging Tflags DWORD: #define OUTTRACE 0x00000001 // enables tracing to dxwnd.log in general diff --git a/build/dxwnd.dll b/build/dxwnd.dll index 5872506..cbaa407 100644 --- a/build/dxwnd.dll +++ b/build/dxwnd.dll @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2d27bd94b95b7ca824b05b37e72626d7250273d4c55512eac260ea59ed8cb2cb -size 314880 +oid sha256:3ab8190eadcff243a68b15f1b95a1ae8a260ec90013a73ba149322adc1786dfd +size 340992 diff --git a/build/dxwnd.exe b/build/dxwnd.exe index df79c93..f5ea8d0 100644 --- a/build/dxwnd.exe +++ b/build/dxwnd.exe @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c518035d2eea78a680be7ee136ab574ad087f8f346f923be2e43b1ba9fa5b3ee -size 502272 +oid sha256:b5a29f58873b15c65c45cc3216847b5bd94c4c6a382ad62f717087cb69e8406e +size 503296 diff --git a/build/dxwnd.ini b/build/dxwnd.ini index f9aa226..d45a764 100644 --- a/build/dxwnd.ini +++ b/build/dxwnd.ini @@ -1,4957 +1,5 @@ -[target] -title0=1602 A.D. -path0=C:\Games\1602 A.D\1602.exe -module0= -ver0=0 -flag0=679608354 -flagg0=0 -tflag0=0 -initx0=0 -inity0=0 -minx0=0 -miny0=0 -maxx0=0 -maxy0=0 -posx0=50 -posy0=50 -sizx0=800 -sizy0=600 -title1=7th Legion -path1=D:\Games\7th_Legion\LEGION.EXE -module1= -ver1=0 -flag1=402669607 -flagg1=539056144 -tflag1=12 -initx1=0 -inity1=0 -minx1=0 -miny1=0 -maxx1=0 -maxy1=0 -posx1=50 -posy1=50 -sizx1=800 -sizy1=600 -title2=A10 Cuba -path2=D:\Games\A10\A10Cuba.exe -module2= -ver2=0 -flag2=34 -flagg2=0 -tflag2=258 -initx2=0 -inity2=0 -minx2=0 -miny2=0 -maxx2=0 -maxy2=0 -posx2=50 -posy2=50 -sizx2=800 -sizy2=600 -title3=Achtung Spitfire -path3=D:\Games\Achtung Spitfire\ASP95.EXE -module3= -ver3=0 -flag3=536870946 -flagg3=0 -tflag3=70 -initx3=0 -inity3=0 -minx3=0 -miny3=0 -maxx3=0 -maxy3=0 -posx3=50 -posy3=50 -sizx3=800 -sizy3=600 -title4=Actua Soccer 3 -path4=D:\Games\ActuaSoccer3\Soccer3.exe -module4= -ver4=0 -flag4=671088674 -flagg4=256 -tflag4=263 -initx4=0 -inity4=0 -minx4=0 -miny4=0 -maxx4=0 -maxy4=0 -posx4=50 -posy4=50 -sizx4=800 -sizy4=600 -title5=AfterLife -path5=d:\Games\ALIFE\ALIFE.EXE -module5= -ver5=1 -flag5=142606370 -flagg5=160 -tflag5=259 -initx5=0 -inity5=0 -minx5=0 -miny5=0 -maxx5=0 -maxy5=0 -posx5=50 -posy5=50 -sizx5=800 -sizy5=600 -title6=Age of Empires -path6=D:\Games\Age of Empires\EMPIRES.EXE -module6= -ver6=0 -flag6=402655267 -flagg6=536940560 -tflag6=3 -initx6=0 -inity6=0 -minx6=0 -miny6=0 -maxx6=0 -maxy6=0 -posx6=50 -posy6=50 -sizx6=800 -sizy6=600 -title7=Age of Empires 2 -path7=D:\Games\Age of Empires 2\empires2.exe -module7= -ver7=0 -flag7=134217762 -flagg7=20480 -tflag7=3 -initx7=0 -inity7=0 -minx7=0 -miny7=0 -maxx7=0 -maxy7=0 -posx7=50 -posy7=50 -sizx7=800 -sizy7=600 -title8=Age of Empires the Rise of Rome -path8=D:\Games\Age of Empires\EMPIRESX.EXE -module8= -ver8=0 -flag8=134217762 -flagg8=81920 -tflag8=0 -initx8=0 -inity8=0 -minx8=0 -miny8=0 -maxx8=0 -maxy8=0 -posx8=50 -posy8=50 -sizx8=800 -sizy8=600 -title9=Age of Wonders -path9=D:\Games\Age of Wonders\AoW.exe -module9=VideoP.dpl vcl30.dpl -ver9=0 -flag9=813826050 -flagg9=537919505 -tflag9=3 -initx9=0 -inity9=0 -minx9=0 -miny9=0 -maxx9=0 -maxy9=0 -posx9=50 -posy9=50 -sizx9=800 -sizy9=600 -title10=Airline Tycoon Evolution -path10=D:\Games\Airline.Tycoon.Evolution\AT.EXE -module10= -ver10=0 -flag10=402653217 -flagg10=5242880 -tflag10=259 -initx10=0 -inity10=0 -minx10=0 -miny10=0 -maxx10=0 -maxy10=0 -posx10=50 -posy10=50 -sizx10=800 -sizy10=600 -title11=Alien Cabal 95 -path11=D:\Games\Alien_cabal\ACabal95.exe -module11= -ver11=0 -flag11=71303200 -flagg11=0 -tflag11=3 -initx11=0 -inity11=0 -minx11=0 -miny11=0 -maxx11=0 -maxy11=0 -posx11=50 -posy11=50 -sizx11=800 -sizy11=600 -title12=Alien vs. Predator -path12=C:\Games\Alien vs Predator\AvP.exe -module12= -ver12=0 -flag12=8224 -flagg12=0 -tflag12=130 -initx12=0 -inity12=0 -minx12=0 -miny12=0 -maxx12=0 -maxy12=0 -posx12=50 -posy12=50 -sizx12=800 -sizy12=600 -title13=Aliens Nations Demo -path13=C:\Games\aademo\Bin\AA.exe -module13= -ver13=0 -flag13=134217762 -flagg13=0 -tflag13=0 -initx13=0 -inity13=0 -minx13=0 -miny13=0 -maxx13=0 -maxy13=0 -posx13=0 -posy13=0 -sizx13=800 -sizy13=600 -title14=America -path14=D:\Games\America\america.exe -module14= -ver14=0 -flag14=134234150 -flagg14=16 -tflag14=0 -initx14=0 -inity14=0 -minx14=0 -miny14=0 -maxx14=0 -maxy14=0 -posx14=50 -posy14=50 -sizx14=800 -sizy14=600 -title15=American McGee's Alice Demo -path15=D:\Games\American McGee's Alice Demo\alice.exe -module15= -ver15=10 -flag15=268435458 -flagg15=-2147352576 -tflag15=0 -initx15=0 -inity15=0 -minx15=0 -miny15=0 -maxx15=0 -maxy15=0 -posx15=50 -posy15=50 -sizx15=800 -sizy15=600 -title16=Ancient Conquest -path16=D:\Games\Ancient Conquest\ANCIENT.EXE -module16= -ver16=0 -flag16=142606370 -flagg16=1048576 -tflag16=258 -initx16=0 -inity16=0 -minx16=0 -miny16=0 -maxx16=0 -maxy16=0 -posx16=50 -posy16=50 -sizx16=800 -sizy16=600 -title17=Ancient Evil -path17=C:\Games\Ancient Evil\RPG.EXE -module17=DDW16.DLL -ver17=1 -flag17=-2013249497 -flagg17=0 -tflag17=2 -initx17=0 -inity17=0 -minx17=0 -miny17=0 -maxx17=0 -maxy17=0 -posx17=50 -posy17=50 -sizx17=800 -sizy17=600 -title18=Ancient Evil Demo -path18=C:\Games\Ancient Evil Curse of the Snake Cult\aecsc-demo.exe -module18= -ver18=1 -flag18=134242336 -flagg18=0 -tflag18=0 -initx18=0 -inity18=0 -minx18=0 -miny18=0 -maxx18=0 -maxy18=0 -posx18=50 -posy18=50 -sizx18=800 -sizy18=600 -title19=Armymen -path19=C:\Games\armymen\Armymen.exe -module19= -ver19=0 -flag19=134218274 -flagg19=1 -tflag19=0 -initx19=0 -inity19=0 -minx19=0 -miny19=0 -maxx19=0 -maxy19=0 -posx19=50 -posy19=50 -sizx19=800 -sizy19=600 -title20=ArmyMen 2 -path20=C:\Games\army2\ArmyMen2.exe -module20= -ver20=0 -flag20=402653730 -flagg20=0 -tflag20=0 -initx20=0 -inity20=0 -minx20=0 -miny20=0 -maxx20=0 -maxy20=0 -posx20=50 -posy20=50 -sizx20=800 -sizy20=600 -title21=Atomic Bomberman -path21=C:\Games\Atomic Bomberman\BM95.EXE -module21= -ver21=0 -flag21=2 -flagg21=0 -tflag21=0 -initx21=0 -inity21=0 -minx21=0 -miny21=0 -maxx21=0 -maxy21=0 -posx21=50 -posy21=50 -sizx21=800 -sizy21=600 -title22=Axis & Allies Iron Blitz Edition -path22=C:\Games\Axis & Allies Iron Blitz Edition\Axis & Allies\AxisAllies.exe -module22= -ver22=0 -flag22=-2147483614 -flagg22=0 -tflag22=0 -initx22=0 -inity22=0 -minx22=0 -miny22=0 -maxx22=0 -maxy22=0 -posx22=50 -posy22=50 -sizx22=800 -sizy22=600 -title23=Baldies -path23=C:\Games\Baldies for Win95\baldies.exe -module23= -ver23=0 -flag23=537010210 -flagg23=0 -tflag23=0 -initx23=0 -inity23=0 -minx23=0 -miny23=0 -maxx23=0 -maxy23=0 -posx23=50 -posy23=50 -sizx23=800 -sizy23=600 -title24=Battle Arena Toshinden 2 -path24=D:\Games\Battle Arena Toshinden 2\T2.EXE -module24= -ver24=0 -flag24=134217761 -flagg24=134217808 -tflag24=3 -initx24=0 -inity24=0 -minx24=0 -miny24=0 -maxx24=0 -maxy24=0 -posx24=50 -posy24=50 -sizx24=800 -sizy24=600 -title25=Beasts & Bumpkins -path25=C:\Games\Beasts and Bumpkins\BEASTS.EXE -module25= -ver25=0 -flag25=2105890 -flagg25=0 -tflag25=2 -initx25=0 -inity25=0 -minx25=0 -miny25=0 -maxx25=0 -maxy25=0 -posx25=50 -posy25=50 -sizx25=800 -sizy25=600 -title26=Beats of Rage -path26=C:\Games\BOR\BeatsOfRage.exe -module26= -ver26=0 -flag26=537002018 -flagg26=0 -tflag26=0 -initx26=0 -inity26=0 -minx26=0 -miny26=0 -maxx26=0 -maxy26=0 -posx26=50 -posy26=50 -sizx26=800 -sizy26=600 -title27=Beyond Good & Evil Demo -path27=C:\Games\Beyond Good & Evil\BGE.exe -module27= -ver27=0 -flag27=0 -flagg27=0 -tflag27=0 -initx27=0 -inity27=0 -minx27=0 -miny27=0 -maxx27=0 -maxy27=0 -posx27=50 -posy27=50 -sizx27=800 -sizy27=600 -title28=Black Moon Lune Noire -path28=C:\Games\Black Moon\Lune noire\Engine.exe -module28= -ver28=0 -flag28=262179 -flagg28=0 -tflag28=0 -initx28=0 -inity28=0 -minx28=0 -miny28=0 -maxx28=0 -maxy28=0 -posx28=50 -posy28=50 -sizx28=800 -sizy28=600 -title29=Blood Omen Legacy of Kain -path29=C:\Games\Blood Omen\KAIN.EXE -module29= -ver29=0 -flag29=49190 -flagg29=0 -tflag29=0 -initx29=0 -inity29=0 -minx29=0 -miny29=0 -maxx29=0 -maxy29=0 -posx29=50 -posy29=50 -sizx29=800 -sizy29=600 -title30=Bonkheads -path30=C:\Games\Bonkheads\Bonkheads.exe -module30= -ver30=0 -flag30=262690 -flagg30=16 -tflag30=78 -initx30=0 -inity30=0 -minx30=0 -miny30=0 -maxx30=0 -maxy30=0 -posx30=50 -posy30=50 -sizx30=800 -sizy30=600 -title31=Bubble Bobble 2 -path31=C:\Games\bubble2\BOBO2.EXE -module31= -ver31=0 -flag31=34 -flagg31=0 -tflag31=0 -initx31=0 -inity31=0 -minx31=0 -miny31=0 -maxx31=0 -maxy31=0 -posx31=50 -posy31=50 -sizx31=800 -sizy31=600 -title32=Bug! -path32=C:\Games\Bug\BUG!.EXE -module32= -ver32=0 -flag32=134225954 -flagg32=32 -tflag32=2 -initx32=0 -inity32=0 -minx32=0 -miny32=0 -maxx32=0 -maxy32=0 -posx32=0 -posy32=0 -sizx32=800 -sizy32=600 -title33=Caesar III -path33=C:\Games\Caesar III\c3.exe -module33= -ver33=0 -flag33=-2147475422 -flagg33=0 -tflag33=0 -initx33=0 -inity33=0 -minx33=0 -miny33=0 -maxx33=0 -maxy33=0 -posx33=50 -posy33=50 -sizx33=800 -sizy33=600 -title34=Championship Manager 99-00 -path34=C:\Games\CM9900\cm9900.exe -module34= -ver34=0 -flag34=10306 -flagg34=0 -tflag34=0 -initx34=0 -inity34=0 -minx34=0 -miny34=0 -maxx34=0 -maxy34=0 -posx34=50 -posy34=50 -sizx34=800 -sizy34=600 -title35=Civilization Call to Power -path35=C:\Games\civctp\Civilization_Call_To_Power\ctp_program\ctp\civctp.exe -module35= -ver35=0 -flag35=545267746 -flagg35=0 -tflag35=0 -initx35=0 -inity35=0 -minx35=0 -miny35=0 -maxx35=0 -maxy35=0 -posx35=50 -posy35=50 -sizx35=800 -sizy35=600 -title36=Claw -path36=C:\Games\claw\clawexe.exe -module36= -ver36=0 -flag36=24610 -flagg36=0 -tflag36=0 -initx36=0 -inity36=0 -minx36=0 -miny36=0 -maxx36=0 -maxy36=0 -posx36=50 -posy36=50 -sizx36=800 -sizy36=600 -title37=Commando's Behind Enemy Lines Demo -path37=C:\Games\Commando's Behind Enemy Lines Demo\COMANDOS\Comandos.exe -module37= -ver37=0 -flag37=1744838944 -flagg37=0 -tflag37=64 -initx37=0 -inity37=0 -minx37=0 -miny37=0 -maxx37=0 -maxy37=0 -posx37=50 -posy37=50 -sizx37=800 -sizy37=600 -title38=Commandos II: Men of Courage -path38=C:\Games\Commandos II\comm2.exe -module38= -ver38=0 -flag38=-1207951008 -flagg38=0 -tflag38=0 -initx38=0 -inity38=0 -minx38=0 -miny38=0 -maxx38=0 -maxy38=0 -posx38=50 -posy38=50 -sizx38=800 -sizy38=600 -title39=Crazy Taxy -path39=C:\Games\Crazy_Taxi\Crazy Taxi PC Version\crazy_taxi_pc.exe -module39= -ver39=8 -flag39=536870945 -flagg39=0 -tflag39=0 -initx39=0 -inity39=0 -minx39=0 -miny39=0 -maxx39=0 -maxy39=0 -posx39=50 -posy39=50 -sizx39=800 -sizy39=600 -title40=Crush! Deluxe -path40=C:\Games\Crush! Deluxe\CRUSHD.EXE -module40= -ver40=0 -flag40=134492706 -flagg40=0 -tflag40=0 -initx40=0 -inity40=0 -minx40=0 -miny40=0 -maxx40=0 -maxy40=0 -posx40=50 -posy40=50 -sizx40=800 -sizy40=600 -title41=Cybermercs -path41=C:\Games\cybermercs\cybermercs.exe -module41= -ver41=0 -flag41=134234146 -flagg41=16 -tflag41=0 -initx41=0 -inity41=0 -minx41=0 -miny41=0 -maxx41=0 -maxy41=0 -posx41=50 -posy41=50 -sizx41=800 -sizy41=600 -title42=Daikatana -path42=D:\Games\Daikatana\daikatana.exe -module42= -ver42=10 -flag42=806486530 -flagg42=537002497 -tflag42=259 -initx42=0 -inity42=0 -minx42=0 -miny42=0 -maxx42=0 -maxy42=0 -posx42=50 -posy42=50 -sizx42=800 -sizy42=600 -title43=Darius Gaiden -path43=C:\Games\Darius_gaiden\DARIUS.EXE -module43= -ver43=0 -flag43=536870946 -flagg43=0 -tflag43=0 -initx43=0 -inity43=0 -minx43=0 -miny43=0 -maxx43=0 -maxy43=0 -posx43=50 -posy43=50 -sizx43=800 -sizy43=600 -title44=Dark Colony the Council Wars -path44=C:\Games\darkcolony_council\dc\DC16.EXE -module44= -ver44=0 -flag44=268435462 -flagg44=0 -tflag44=0 -initx44=0 -inity44=0 -minx44=0 -miny44=0 -maxx44=0 -maxy44=0 -posx44=50 -posy44=50 -sizx44=800 -sizy44=600 -title45=Darkstone -path45=C:\Games\darkstone\Darkstone.exe -module45= -ver45=0 -flag45=134234148 -flagg45=0 -tflag45=0 -initx45=0 -inity45=0 -minx45=0 -miny45=0 -maxx45=0 -maxy45=0 -posx45=50 -posy45=50 -sizx45=800 -sizy45=600 -title46=Dave Mirra Freestyle BMX Demo -path46=C:\Games\Dave Mirra Freestyle BMX\NgBMXDemo.exe -module46= -ver46=0 -flag46=8224 -flagg46=0 -tflag46=0 -initx46=0 -inity46=0 -minx46=0 -miny46=0 -maxx46=0 -maxy46=0 -posx46=50 -posy46=50 -sizx46=800 -sizy46=600 -title47=Daytona USA Deluxe -path47=C:\Games\Daytona USA Deluxe\DAYTONA USA Deluxe.exe -module47= -ver47=0 -flag47=402661410 -flagg47=0 -tflag47=0 -initx47=0 -inity47=0 -minx47=0 -miny47=0 -maxx47=0 -maxy47=0 -posx47=50 -posy47=50 -sizx47=800 -sizy47=600 -title48=Deadlock 2 -path48=C:\Games\deadlock2\DEADLOCK.EXE -module48= -ver48=0 -flag48=-2012995550 -flagg48=0 -tflag48=0 -initx48=0 -inity48=0 -minx48=0 -miny48=0 -maxx48=0 -maxy48=0 -posx48=50 -posy48=50 -sizx48=800 -sizy48=600 -title49=Deeper Dungeons 95 -path49=C:\Games\Keeper95\Deeper95.exe -module49= -ver49=0 -flag49=268460070 -flagg49=0 -tflag49=0 -initx49=0 -inity49=0 -minx49=0 -miny49=0 -maxx49=0 -maxy49=0 -posx49=50 -posy49=50 -sizx49=800 -sizy49=600 -title50=Delta Force -path50=C:\Games\Delta Force\Df.exe -module50= -ver50=0 -flag50=34 -flagg50=0 -tflag50=0 -initx50=0 -inity50=0 -minx50=0 -miny50=0 -maxx50=0 -maxy50=0 -posx50=50 -posy50=50 -sizx50=800 -sizy50=600 -title51=Dementia -path51=C:\Games\dementia\program\CRUX.EXE -h -module51= -ver51=0 -flag51=536887330 -flagg51=0 -tflag51=2 -initx51=0 -inity51=0 -minx51=0 -miny51=0 -maxx51=0 -maxy51=0 -posx51=50 -posy51=50 -sizx51=800 -sizy51=600 -title52=Dethkarz -path52=D:\Games\DethKarz\Dethkarz.exe -module52= -ver52=0 -flag52=0 -flagg52=0 -tflag52=0 -initx52=0 -inity52=0 -minx52=0 -miny52=0 -maxx52=0 -maxy52=0 -posx52=50 -posy52=50 -sizx52=800 -sizy52=600 -title53=Devil Inside -path53=C:\Games\Devil Inside\Devil.exe -module53= -ver53=0 -flag53=32 -flagg53=0 -tflag53=0 -initx53=0 -inity53=0 -minx53=0 -miny53=0 -maxx53=0 -maxy53=0 -posx53=50 -posy53=50 -sizx53=800 -sizy53=600 -title54=Diablo -path54=D:\Games\Diablo\Diablo.exe -module54=diabloui storm haigu smackw32 -ver54=1 -flag54=138428450 -flagg54=101711872 -tflag54=259 -initx54=0 -inity54=0 -minx54=0 -miny54=0 -maxx54=0 -maxy54=0 -posx54=50 -posy54=50 -sizx54=800 -sizy54=600 -title55=Dink Smallwood (BAD) -path55=C:\Games\Dink SmallWood\Dink.exe -module55= -ver55=0 -flag55=546 -flagg55=0 -tflag55=258 -initx55=0 -inity55=0 -minx55=0 -miny55=0 -maxx55=0 -maxy55=0 -posx55=50 -posy55=50 -sizx55=800 -sizy55=600 -title56=Doom 64 Absolution -path56=D:\Games\Doom 64\Bin\Absolution.exe -module56= -ver56=8 -flag56=0 -flagg56=86016 -tflag56=259 -initx56=0 -inity56=0 -minx56=0 -miny56=0 -maxx56=0 -maxy56=0 -posx56=50 -posy56=50 -sizx56=800 -sizy56=600 -title57=Drakan -path57=C:\Games\Drakan\drakan.exe -module57= -ver57=0 -flag57=536887328 -flagg57=0 -tflag57=0 -initx57=0 -inity57=0 -minx57=0 -miny57=0 -maxx57=0 -maxy57=0 -posx57=50 -posy57=50 -sizx57=800 -sizy57=600 -title58=Dream Aquarium -path58=D:\Program Files\Dream Aquarium\Dream_Aquarium.scr -module58= -ver58=9 -flag58=679477249 -flagg58=303104 -tflag58=256 -initx58=0 -inity58=0 -minx58=0 -miny58=0 -maxx58=0 -maxy58=0 -posx58=50 -posy58=50 -sizx58=800 -sizy58=600 -title59=Dungeon Keeper 2 GOG release -path59=D:\Games\Dungeon Keeper 2 GOG release\DKII.EXE -module59= -ver59=0 -flag59=134217762 -flagg59=4276224 -tflag59=6 -initx59=0 -inity59=0 -minx59=0 -miny59=0 -maxx59=0 -maxy59=0 -posx59=50 -posy59=50 -sizx59=800 -sizy59=600 -title60=Dungeon Keeper 95 -path60=D:\Games\Keeper95\KEEPER95.EXE -module60= -ver60=0 -flag60=134234150 -flagg60=0 -tflag60=64 -initx60=0 -inity60=0 -minx60=0 -miny60=0 -maxx60=0 -maxy60=0 -posx60=50 -posy60=50 -sizx60=800 -sizy60=600 -title61=Dungeon Keeper II -path61=D:\Games\Dungeon Keeper 2\DKII.exe -module61= -ver61=0 -flag61=34 -flagg61=0 -tflag61=262 -initx61=0 -inity61=0 -minx61=0 -miny61=0 -maxx61=0 -maxy61=0 -posx61=150 -posy61=50 -sizx61=800 -sizy61=600 -title62=Emergency Fighters for life -path62=D:\Games\Emergency\EMERGY.EXE -module62= -ver62=0 -flag62=134545443 -flagg62=18 -tflag62=3 -initx62=0 -inity62=0 -minx62=0 -miny62=0 -maxx62=0 -maxy62=0 -posx62=50 -posy62=50 -sizx62=800 -sizy62=600 -title63=Enemy Infestation -path63=C:\Games\Enemy Infestation (1998)\Ei.exe -module63= -ver63=0 -flag63=38 -flagg63=0 -tflag63=0 -initx63=0 -inity63=0 -minx63=0 -miny63=0 -maxx63=0 -maxy63=0 -posx63=50 -posy63=50 -sizx63=800 -sizy63=600 -title64=Evil Genius -path64=D:\Games\Evil Genius\ReleaseExe\EvilGenius_Cracked.exe -module64= -ver64=9 -flag64=2053 -flagg64=80 -tflag64=0 -initx64=0 -inity64=0 -minx64=0 -miny64=0 -maxx64=0 -maxy64=0 -posx64=50 -posy64=50 -sizx64=800 -sizy64=600 -title65=Expendable -path65=C:\Games\eXpendable\go.exe -nocputest -module65= -ver65=0 -flag65=402653280 -flagg65=1 -tflag65=2 -initx65=0 -inity65=0 -minx65=0 -miny65=0 -maxx65=0 -maxy65=0 -posx65=50 -posy65=50 -sizx65=800 -sizy65=600 -title66=Fallen Heaven (BAD) -path66=C:\Games\falhaven\Exe\FALLEN.EXE -module66= -ver66=0 -flag66=679485962 -flagg66=32 -tflag66=0 -initx66=0 -inity66=0 -minx66=0 -miny66=0 -maxx66=0 -maxy66=0 -posx66=0 -posy66=0 -sizx66=800 -sizy66=600 -title67=Fallout -path67=D:\Games\Fallout\FALLOUTW.EXE -module67= -ver67=1 -flag67=134217734 -flagg67=16 -tflag67=0 -initx67=0 -inity67=0 -minx67=0 -miny67=0 -maxx67=0 -maxy67=0 -posx67=50 -posy67=50 -sizx67=800 -sizy67=600 -title68=FreakOut -path68=C:\Games\Freak Out - Extreme Freeride\FreakOut.exe -module68= -ver68=9 -flag68=0 -flagg68=0 -tflag68=2 -initx68=0 -inity68=0 -minx68=0 -miny68=0 -maxx68=0 -maxy68=0 -posx68=50 -posy68=50 -sizx68=800 -sizy68=600 -title69=Funtracks -path69=C:\Games\Funtracks\Fun_win.exe -module69= -ver69=1 -flag69=2 -flagg69=0 -tflag69=258 -initx69=0 -inity69=0 -minx69=0 -miny69=0 -maxx69=0 -maxy69=0 -posx69=50 -posy69=50 -sizx69=800 -sizy69=600 -title70=Galapagos -path70=C:\Games\Galapagos\GALA.EXE -module70= -ver70=0 -flag70=134217760 -flagg70=0 -tflag70=0 -initx70=0 -inity70=0 -minx70=0 -miny70=0 -maxx70=0 -maxy70=0 -posx70=50 -posy70=50 -sizx70=800 -sizy70=600 -title71=Gangsters -path71=C:\Games\Gangsters\gangsters.exe -module71= -ver71=0 -flag71=134217762 -flagg71=0 -tflag71=2 -initx71=0 -inity71=0 -minx71=0 -miny71=0 -maxx71=0 -maxy71=0 -posx71=100 -posy71=100 -sizx71=800 -sizy71=600 -title72=GeneRally -path72=C:\Games\generally105\GeneRally.exe -module72= -ver72=0 -flag72=34 -flagg72=0 -tflag72=0 -initx72=0 -inity72=0 -minx72=0 -miny72=0 -maxx72=0 -maxy72=0 -posx72=50 -posy72=50 -sizx72=800 -sizy72=600 -title73=Get Medieval -path73=C:\Games\Get Medieval\MEDIEVAL.EXE -module73= -ver73=0 -flag73=34 -flagg73=2 -tflag73=0 -initx73=0 -inity73=0 -minx73=0 -miny73=0 -maxx73=0 -maxy73=0 -posx73=0 -posy73=0 -sizx73=800 -sizy73=600 -title74=Gift -path74=C:\Games\Gift\Gift.exe -module74= -ver74=0 -flag74=4196384 -flagg74=0 -tflag74=34 -initx74=0 -inity74=0 -minx74=0 -miny74=0 -maxx74=0 -maxy74=0 -posx74=0 -posy74=0 -sizx74=0 -sizy74=0 -title75=Golden Age of Racing -path75=C:\Games\Golden Age of Racing\GAOR.exe -module75= -ver75=0 -flag75=34 -flagg75=0 -tflag75=0 -initx75=0 -inity75=0 -minx75=0 -miny75=0 -maxx75=0 -maxy75=0 -posx75=50 -posy75=50 -sizx75=800 -sizy75=600 -title76=Gp500 for Win2K -path76=C:\Games\gp500\gp500_win2k.exe -module76= -ver76=1 -flag76=545677860 -flagg76=0 -tflag76=2 -initx76=0 -inity76=0 -minx76=0 -miny76=0 -maxx76=0 -maxy76=0 -posx76=50 -posy76=50 -sizx76=800 -sizy76=600 -title77=G-Police -path77=C:\Games\gpolice\GPOLICE.EXE -module77= -ver77=0 -flag77=67125286 -flagg77=0 -tflag77=2 -initx77=0 -inity77=0 -minx77=0 -miny77=0 -maxx77=0 -maxy77=0 -posx77=50 -posy77=50 -sizx77=800 -sizy77=600 -title78=Grand Prix Legends -path78=D:\Games\Grand Prix Legends\gpl\gpl.exe -module78= -ver78=0 -flag78=-1979678687 -flagg78=4 -tflag78=271 -initx78=0 -inity78=0 -minx78=0 -miny78=0 -maxx78=0 -maxy78=0 -posx78=50 -posy78=50 -sizx78=640 -sizy78=480 -title79=Grim Fandango Demo -path79=C:\Games\GrimWebDemo\grimdemo.exe -module79= -ver79=0 -flag79=34 -flagg79=0 -tflag79=258 -initx79=0 -inity79=0 -minx79=0 -miny79=0 -maxx79=0 -maxy79=0 -posx79=50 -posy79=50 -sizx79=800 -sizy79=600 -title80=Half-Life Blue-Shift (d3d) -path80=D:\Games\Half-Life Blue-Shift\bshift.exe -module80= -ver80=7 -flag80=1207959554 -flagg80=513 -tflag80=258 -initx80=0 -inity80=0 -minx80=0 -miny80=0 -maxx80=0 -maxy80=0 -posx80=50 -posy80=50 -sizx80=800 -sizy80=600 -title81=Half-Life Uplink Demo -path81=D:\Games\Half-Life Uplink\hldemo.exe -module81= -ver81=1 -flag81=1073741826 -flagg81=16384 -tflag81=2 -initx81=0 -inity81=0 -minx81=0 -miny81=0 -maxx81=0 -maxy81=0 -posx81=50 -posy81=50 -sizx81=640 -sizy81=480 -title82=Halo Combat Evolved -path82=D:\Games\Halo Combat Evolved\halo.exe -module82= -ver82=9 -flag82=570425377 -flagg82=-2147483648 -tflag82=478 -initx82=0 -inity82=0 -minx82=0 -miny82=0 -maxx82=0 -maxy82=0 -posx82=50 -posy82=50 -sizx82=800 -sizy82=600 -title83=Heart of Darkness -path83=d:\Games\Heart of Darkness\HODWin32.exe -module83= -ver83=0 -flag83=8226 -flagg83=2179072 -tflag83=0 -initx83=0 -inity83=0 -minx83=0 -miny83=0 -maxx83=0 -maxy83=0 -posx83=50 -posy83=50 -sizx83=800 -sizy83=600 -title84=Heavy Metal FAKK 2 -path84=C:\Games\Heavy Metal - FAKK2\fakk2.exe -module84= -ver84=0 -flag84=33554464 -flagg84=64 -tflag84=2 -initx84=0 -inity84=0 -minx84=0 -miny84=0 -maxx84=0 -maxy84=0 -posx84=50 -posy84=50 -sizx84=800 -sizy84=600 -title85=HellCopter -path85=C:\Games\hellcop\HCopter.exe -module85= -ver85=0 -flag85=-2013249500 -flagg85=256 -tflag85=0 -initx85=0 -inity85=0 -minx85=0 -miny85=0 -maxx85=0 -maxy85=0 -posx85=50 -posy85=50 -sizx85=800 -sizy85=600 -title86=Heroes of Might & Magic III Demo -path86=C:\Games\Heroes III Demo\h3demo.exe -module86= -ver86=1 -flag86=134234146 -flagg86=0 -tflag86=2 -initx86=0 -inity86=0 -minx86=0 -miny86=0 -maxx86=0 -maxy86=0 -posx86=50 -posy86=50 -sizx86=800 -sizy86=600 -title87=Hexen II (opengl) -path87=D:\Games\Hexen II\glh2.exe -module87= -ver87=10 -flag87=3 -flagg87=212993 -tflag87=387 -initx87=0 -inity87=0 -minx87=0 -miny87=0 -maxx87=0 -maxy87=0 -posx87=50 -posy87=50 -sizx87=800 -sizy87=600 -title88=Hexen II (software) -path88=D:\Games\Hexen II\h2.exe -module88= -ver88=10 -flag88=671088642 -flagg88=1130496 -tflag88=0 -initx88=0 -inity88=0 -minx88=0 -miny88=0 -maxx88=0 -maxy88=0 -posx88=50 -posy88=50 -sizx88=800 -sizy88=600 -title89=hover -path89=C:\Games\hover\hoverX.exe -module89= -ver89=0 -flag89=8224 -flagg89=0 -tflag89=0 -initx89=0 -inity89=0 -minx89=0 -miny89=0 -maxx89=0 -maxy89=0 -posx89=50 -posy89=50 -sizx89=800 -sizy89=600 -title90=Hyperblade -path90=D:\Games\Hyperblade\HYPERX.EXE -module90= -ver90=0 -flag90=134217891 -flagg90=3231762 -tflag90=2 -initx90=0 -inity90=0 -minx90=0 -miny90=0 -maxx90=0 -maxy90=0 -posx90=50 -posy90=50 -sizx90=800 -sizy90=600 -title91=Idinaloq -path91=C:\Games\idina101\idinaloq.exe -module91= -ver91=0 -flag91=32 -flagg91=0 -tflag91=0 -initx91=0 -inity91=0 -minx91=0 -miny91=0 -maxx91=0 -maxy91=0 -posx91=50 -posy91=50 -sizx91=800 -sizy91=600 -title92=Immanis -path92=C:\Games\Immanis CD release\immanis.exe -module92= -ver92=0 -flag92=24611 -flagg92=0 -tflag92=0 -initx92=0 -inity92=0 -minx92=0 -miny92=0 -maxx92=0 -maxy92=0 -posx92=50 -posy92=50 -sizx92=800 -sizy92=600 -title93=Immanis (v2) -path93=C:\Games\Immanis CD release\immanis_v2.exe -module93= -ver93=0 -flag93=268460067 -flagg93=0 -tflag93=0 -initx93=0 -inity93=0 -minx93=0 -miny93=0 -maxx93=0 -maxy93=0 -posx93=50 -posy93=50 -sizx93=800 -sizy93=600 -title94=In the Hunt -path94=C:\Games\In The Hunt\e8.exe -module94= -ver94=0 -flag94=2 -flagg94=0 -tflag94=0 -initx94=0 -inity94=0 -minx94=0 -miny94=0 -maxx94=0 -maxy94=0 -posx94=50 -posy94=50 -sizx94=800 -sizy94=600 -title95=Incoming Forces -path95=D:\Games\Incoming Forces\forces.exe -module95= -ver95=8 -flag95=134217760 -flagg95=0 -tflag95=2 -initx95=0 -inity95=0 -minx95=0 -miny95=0 -maxx95=0 -maxy95=0 -posx95=50 -posy95=50 -sizx95=800 -sizy95=600 -title96=International Superstar Soccer 3 -path96=C:\Games\ISS_3\iss3.exe -module96= -ver96=8 -flag96=545267715 -flagg96=0 -tflag96=0 -initx96=0 -inity96=0 -minx96=0 -miny96=0 -maxx96=0 -maxy96=0 -posx96=50 -posy96=50 -sizx96=800 -sizy96=600 -title97=Jacked -path97=D:\Games\Jacked\Jacked.exe -module97=winmm -ver97=9 -flag97=537010208 -flagg97=196608 -tflag97=258 -initx97=0 -inity97=0 -minx97=0 -miny97=0 -maxx97=0 -maxy97=0 -posx97=50 -posy97=50 -sizx97=800 -sizy97=600 -title98=Jedi Knight II Jedi Outcast -path98=D:\Games\Jedi Knight II Jedi Outcast\GameData\jk2sp.exe -module98= -ver98=0 -flag98=0 -flagg98=512 -tflag98=266 -initx98=0 -inity98=0 -minx98=0 -miny98=0 -maxx98=0 -maxy98=0 -posx98=50 -posy98=50 -sizx98=800 -sizy98=600 -title99=Jet Moto -path99=M:\JETMOTO.EXE -module99= -ver99=0 -flag99=139298 -flagg99=0 -tflag99=0 -initx99=0 -inity99=0 -minx99=0 -miny99=0 -maxx99=0 -maxy99=0 -posx99=50 -posy99=50 -sizx99=800 -sizy99=600 -title100=Kiss Psyco Cyrcus -path100=C:\Games\Psycho\client.exe -module100=d3d.ren -ver100=7 -flag100=537018404 -flagg100=0 -tflag100=0 -initx100=0 -inity100=0 -minx100=0 -miny100=0 -maxx100=0 -maxy100=0 -posx100=50 -posy100=50 -sizx100=800 -sizy100=600 -title101=Krazy Ivan -path101=C:\Games\Krazy Ivan\KRAZY.EXE -module101= -ver101=0 -flag101=536870914 -flagg101=0 -tflag101=0 -initx101=0 -inity101=0 -minx101=0 -miny101=0 -maxx101=0 -maxy101=0 -posx101=50 -posy101=50 -sizx101=800 -sizy101=600 -title102=Last Bronx -path102=C:\Games\Last_Bronx\LB.EXE -module102= -ver102=0 -flag102=40994 -flagg102=0 -tflag102=64 -initx102=0 -inity102=0 -minx102=0 -miny102=0 -maxx102=0 -maxy102=0 -posx102=50 -posy102=50 -sizx102=800 -sizy102=600 -title103=Lionheart -path103=C:\Games\Lionheart Demo\Lionheart.exe -module103= -ver103=0 -flag103=-2147483612 -flagg103=0 -tflag103=0 -initx103=0 -inity103=0 -minx103=0 -miny103=0 -maxx103=0 -maxy103=0 -posx103=50 -posy103=50 -sizx103=800 -sizy103=600 -title104=lithtech.exe -path104=D:\Games\NOLF Technology Demo\lithtech.exe -module104= -ver104=7 -flag104=0 -flagg104=512 -tflag104=258 -initx104=0 -inity104=0 -minx104=0 -miny104=0 -maxx104=0 -maxy104=0 -posx104=50 -posy104=50 -sizx104=800 -sizy104=600 -title105=Lords of the Realm 2 -path105=D:\Games\L2SIEGE\LORDS2.EXE -module105= -ver105=0 -flag105=38 -flagg105=65536 -tflag105=9 -initx105=0 -inity105=0 -minx105=0 -miny105=0 -maxx105=0 -maxy105=0 -posx105=50 -posy105=50 -sizx105=800 -sizy105=600 -title106=M.A.X. 2 -path106=C:\Games\MAX 2\MAX_2\MAX2\MAX2.EXE -module106= -ver106=0 -flag106=34 -flagg106=0 -tflag106=0 -initx106=0 -inity106=0 -minx106=0 -miny106=0 -maxx106=0 -maxy106=0 -posx106=50 -posy106=50 -sizx106=800 -sizy106=600 -title107=M1 Tank Platoon 2 -path107=C:\Games\M1 Tank Platoon 2\M1TP2.exe -module107= -ver107=8 -flag107=34 -flagg107=0 -tflag107=0 -initx107=0 -inity107=0 -minx107=0 -miny107=0 -maxx107=0 -maxy107=0 -posx107=50 -posy107=50 -sizx107=800 -sizy107=600 -title108=Mario Worlds (stripped PE) -path108=C:\Games\Mario Worlds\Mario Worlds.exe -module108= -ver108=1 -flag108=2 -flagg108=1 -tflag108=386 -initx108=0 -inity108=0 -minx108=0 -miny108=0 -maxx108=0 -maxy108=0 -posx108=50 -posy108=50 -sizx108=800 -sizy108=600 -title109=Masters of Orion 2 -path109=C:\Games\Orion2\Orion95.exe -module109= -ver109=0 -flag109=34 -flagg109=0 -tflag109=0 -initx109=0 -inity109=0 -minx109=0 -miny109=0 -maxx109=0 -maxy109=0 -posx109=50 -posy109=50 -sizx109=800 -sizy109=600 -title110=Microsoft Flight Simulator 98 -path110=C:\Games\Flight Simulator 98\FLTSIM98.EXE -module110= -ver110=0 -flag110=288 -flagg110=0 -tflag110=0 -initx110=0 -inity110=0 -minx110=0 -miny110=0 -maxx110=0 -maxy110=0 -posx110=50 -posy110=50 -sizx110=800 -sizy110=600 -title111=Microsoft Midtown Madness -path111=C:\Games\Midtown Madness\midtown.exe -module111= -ver111=0 -flag111=8192 -flagg111=0 -tflag111=2 -initx111=0 -inity111=0 -minx111=0 -miny111=0 -maxx111=0 -maxy111=0 -posx111=50 -posy111=50 -sizx111=800 -sizy111=600 -title112=Microsoft Midtown Madness Trial (BAD) -path112=C:\Games\Midtown Madness Trial\midtrial.exe -module112= -ver112=0 -flag112=2 -flagg112=0 -tflag112=0 -initx112=0 -inity112=0 -minx112=0 -miny112=0 -maxx112=0 -maxy112=0 -posx112=0 -posy112=0 -sizx112=800 -sizy112=600 -title113=Microsoft Motocross Madness 2 (BAD!!) -path113=C:\Games\Motocross Madness 2\MCM2.cracked.EXE -module113= -ver113=7 -flag113=201326664 -flagg113=1 -tflag113=82 -initx113=0 -inity113=0 -minx113=0 -miny113=0 -maxx113=0 -maxy113=0 -posx113=50 -posy113=50 -sizx113=800 -sizy113=600 -title114=Microsoft Motocross Madness Trial (BAD) -path114=C:\Games\Motocross Madness Trial\mcm.exe -module114= -ver114=1 -flag114=134225952 -flagg114=0 -tflag114=130 -initx114=0 -inity114=0 -minx114=0 -miny114=0 -maxx114=0 -maxy114=0 -posx114=50 -posy114=50 -sizx114=0 -sizy114=0 -title115=Mission Force Cyberstorm (BAD ?) -path115=C:\Games\SIERRA\CSTORM\CSTORM.EXE -module115= -ver115=0 -flag115=33562658 -flagg115=0 -tflag115=0 -initx115=0 -inity115=0 -minx115=0 -miny115=0 -maxx115=0 -maxy115=0 -posx115=50 -posy115=50 -sizx115=0 -sizy115=0 -title116=Monopoly 3D -path116=C:\Games\Monopoly (Edition 3D)\Monopoly.exe -module116= -ver116=0 -flag116=134244388 -flagg116=0 -tflag116=2 -initx116=0 -inity116=0 -minx116=0 -miny116=0 -maxx116=0 -maxy116=0 -posx116=50 -posy116=50 -sizx116=800 -sizy116=600 -title117=Monster Truck Madness 2 -path117=C:\Games\Monster Truck Madness 2\Monster.EXE -module117= -ver117=1 -flag117=34 -flagg117=1 -tflag117=0 -initx117=0 -inity117=0 -minx117=0 -miny117=0 -maxx117=0 -maxy117=0 -posx117=50 -posy117=50 -sizx117=800 -sizy117=600 -title118=Moto Racer Demo -path118=D:\Games\Moto Racer Demo\PlayDemo.exe -module118= -ver118=0 -flag118=167903267 -flagg118=192 -tflag118=14 -initx118=0 -inity118=0 -minx118=0 -miny118=0 -maxx118=0 -maxy118=0 -posx118=50 -posy118=50 -sizx118=800 -sizy118=600 -title119=Necrodrome -path119=C:\Games\Necrodome\NECRO95.EXE -module119= -ver119=0 -flag119=268435495 -flagg119=256 -tflag119=0 -initx119=0 -inity119=0 -minx119=0 -miny119=0 -maxx119=0 -maxy119=0 -posx119=50 -posy119=50 -sizx119=800 -sizy119=600 -title120=Need For Speed - Porsche 2000 -path120=C:\Games\Need For Speed - Porsche 2000\Porsche.exe -module120= -ver120=7 -flag120=0 -flagg120=0 -tflag120=258 -initx120=0 -inity120=0 -minx120=0 -miny120=0 -maxx120=0 -maxy120=0 -posx120=50 -posy120=50 -sizx120=800 -sizy120=600 -title121=Netstorm Islands at War -path121=C:\Games\Netstorm\Netstorm.exe -module121= -ver121=0 -flag121=2 -flagg121=0 -tflag121=0 -initx121=0 -inity121=0 -minx121=0 -miny121=0 -maxx121=0 -maxy121=0 -posx121=50 -posy121=50 -sizx121=800 -sizy121=600 -title122=Nox -path122=d:\Games\Nox\Game.exe -module122= -ver122=0 -flag122=939540515 -flagg122=0 -tflag122=386 -initx122=0 -inity122=0 -minx122=0 -miny122=0 -maxx122=0 -maxy122=0 -posx122=50 -posy122=50 -sizx122=800 -sizy122=600 -title123=Pacific General -path123=C:\Games\Pacific General\PACGEN.EXE -module123= -ver123=0 -flag123=8226 -flagg123=0 -tflag123=2 -initx123=0 -inity123=0 -minx123=0 -miny123=0 -maxx123=0 -maxy123=0 -posx123=50 -posy123=50 -sizx123=800 -sizy123=600 -title124=Project Nomads Demo (BAD) -path124=C:\Games\Project Nomads Demo\bin\win32\nomads.exe -module124= -ver124=8 -flag124=-1476394912 -flagg124=256 -tflag124=258 -initx124=0 -inity124=0 -minx124=0 -miny124=0 -maxx124=0 -maxy124=0 -posx124=50 -posy124=50 -sizx124=800 -sizy124=600 -title125=Puzzle Bubble -path125=C:\Games\Puzzle Bubble\PB.EXE -module125= -ver125=0 -flag125=34 -flagg125=0 -tflag125=0 -initx125=0 -inity125=0 -minx125=0 -miny125=0 -maxx125=0 -maxy125=0 -posx125=50 -posy125=50 -sizx125=800 -sizy125=600 -title126=Quake 2 -path126=D:\Games\QUAKE2\quake2.exe -module126= -ver126=10 -flag126=671089154 -flagg126=-1476263359 -tflag126=259 -initx126=0 -inity126=0 -minx126=0 -miny126=0 -maxx126=0 -maxy126=0 -posx126=50 -posy126=50 -sizx126=800 -sizy126=600 -title127=Quake 3 Arena -path127=D:\Games\Q3A\quake3.exe -module127= -ver127=10 -flag127=0 -flagg127=1180160 -tflag127=3 -initx127=0 -inity127=0 -minx127=0 -miny127=0 -maxx127=0 -maxy127=0 -posx127=50 -posy127=50 -sizx127=800 -sizy127=600 -title128=Raiden II -path128=C:\Games\Raiden II\Raiden II\RAIDENII.EXE -module128= -ver128=0 -flag128=34 -flagg128=0 -tflag128=0 -initx128=0 -inity128=0 -minx128=0 -miny128=0 -maxx128=0 -maxy128=0 -posx128=50 -posy128=50 -sizx128=800 -sizy128=600 -title129=Railroad Tycoon II -path129=C:\Games\Railroad.Tycoon.II\RT2.EXE -module129= -ver129=1 -flag129=134225954 -flagg129=0 -tflag129=0 -initx129=0 -inity129=0 -minx129=0 -miny129=0 -maxx129=0 -maxy129=0 -posx129=50 -posy129=50 -sizx129=800 -sizy129=600 -title130=Rally Championship 2000 -path130=C:\Games\Rally Championship 2000\RAL.EXE -module130= -ver130=0 -flag130=67108864 -flagg130=0 -tflag130=2 -initx130=0 -inity130=0 -minx130=0 -miny130=0 -maxx130=0 -maxy130=0 -posx130=50 -posy130=50 -sizx130=800 -sizy130=600 -title131=Rebel Moon Rising -path131=C:\Games\Rebel Moon Rising\Rmr.exe -module131= -ver131=0 -flag131=0 -flagg131=0 -tflag131=0 -initx131=0 -inity131=0 -minx131=0 -miny131=0 -maxx131=0 -maxy131=0 -posx131=50 -posy131=50 -sizx131=800 -sizy131=600 -title132=Redline - Gang Warfare 2066 -path132=C:\Games\Redline - Gang Warfare 2066\redline.exe -module132= -ver132=0 -flag132=32 -flagg132=0 -tflag132=386 -initx132=0 -inity132=0 -minx132=0 -miny132=0 -maxx132=0 -maxy132=0 -posx132=50 -posy132=50 -sizx132=800 -sizy132=600 -title133=Resident Evil -path133=D:\Games\Resident Evil\residentevil.patched.exe -module133= -ver133=1 -flag133=134217827 -flagg133=-2147483520 -tflag133=2 -initx133=0 -inity133=0 -minx133=0 -miny133=0 -maxx133=0 -maxy133=0 -posx133=50 -posy133=50 -sizx133=800 -sizy133=600 -title134=Return to Castle Wolfenstein -path134=D:\Games\Return to Castle Wolfenstein (2001)\Return to Castle Wolfenstein\WolfSP.exe -module134= -ver134=0 -flag134=134234114 -flagg134=-2147270656 -tflag134=256 -initx134=0 -inity134=0 -minx134=0 -miny134=0 -maxx134=0 -maxy134=0 -posx134=50 -posy134=50 -sizx134=800 -sizy134=600 -title135=Re-Volt -path135=C:\Games\Re-Volt\REVOLT.EXE -module135= -ver135=0 -flag135=134217792 -flagg135=0 -tflag135=0 -initx135=0 -inity135=0 -minx135=0 -miny135=0 -maxx135=0 -maxy135=0 -posx135=50 -posy135=50 -sizx135=800 -sizy135=600 -title136=Road Rash -path136=D:\Games\Road Rash\ROADRASH\ROADRASH.EXE -module136= -ver136=0 -flag136=134217730 -flagg136=0 -tflag136=386 -initx136=0 -inity136=0 -minx136=0 -miny136=0 -maxx136=0 -maxy136=0 -posx136=50 -posy136=50 -sizx136=800 -sizy136=600 -title137=Road Rash Demo -path137=D:\Games\RoadRash DEMO\DEMORASH.EXE -module137= -ver137=0 -flag137=134218242 -flagg137=0 -tflag137=258 -initx137=0 -inity137=0 -minx137=0 -miny137=0 -maxx137=0 -maxy137=0 -posx137=50 -posy137=50 -sizx137=800 -sizy137=600 -title138=RollerCoaster Tycoon 2 Mini Game -path138=C:\Games\RollerCoaster Tycoon 2 Mini Game\rct2.exe -module138= -ver138=1 -flag138=536870946 -flagg138=0 -tflag138=0 -initx138=0 -inity138=0 -minx138=0 -miny138=0 -maxx138=0 -maxy138=0 -posx138=0 -posy138=0 -sizx138=800 -sizy138=600 -title139=Sega Rally 2 Championship -path139=C:\Games\Sega Rally 2 Championship\SEGA RALLY 2.exe -module139= -ver139=1 -flag139=268435488 -flagg139=2 -tflag139=0 -initx139=0 -inity139=0 -minx139=0 -miny139=0 -maxx139=0 -maxy139=0 -posx139=0 -posy139=0 -sizx139=800 -sizy139=600 -title140=Sentinel Returns -path140=D:\Games\Sentinel Returns\Sentinel.exe -module140= -ver140=1 -flag140=3 -flagg140=-2147483648 -tflag140=0 -initx140=0 -inity140=0 -minx140=0 -miny140=0 -maxx140=0 -maxy140=0 -posx140=50 -posy140=50 -sizx140=800 -sizy140=600 -title141=Shadow Master (TBD) -path141=C:\Games\Shadow Master\rmg.exe -module141= -ver141=1 -flag141=32 -flagg141=256 -tflag141=450 -initx141=0 -inity141=0 -minx141=0 -miny141=0 -maxx141=0 -maxy141=0 -posx141=50 -posy141=50 -sizx141=800 -sizy141=600 -title142=Sid Meier's SimGolf Demo -path142=C:\Games\Sid Meier's SimGolf Demo\golf.exe -module142=jgl.dll -ver142=0 -flag142=33554434 -flagg142=0 -tflag142=2 -initx142=0 -inity142=0 -minx142=0 -miny142=0 -maxx142=0 -maxy142=0 -posx142=50 -posy142=50 -sizx142=800 -sizy142=600 -title143=Sin, Wages of (sw renderer) -path143=D:\Games\sin\sin.exe -module143=ref_gl.dll ref_soft.dll -ver143=10 -flag143=402670082 -flagg143=513 -tflag143=386 -initx143=0 -inity143=0 -minx143=0 -miny143=0 -maxx143=0 -maxy143=0 -posx143=50 -posy143=50 -sizx143=800 -sizy143=600 -title144=SleepWalker -path144=C:\Games\SleepWalker\Sleepy.exe -module144= -ver144=0 -flag144=301989954 -flagg144=0 -tflag144=198 -initx144=0 -inity144=0 -minx144=0 -miny144=0 -maxx144=0 -maxy144=0 -posx144=50 -posy144=50 -sizx144=800 -sizy144=600 -title145=SnowBoard Racer -path145=C:\Games\Snowboard Racer\SnowBoard.exe -module145= -ver145=0 -flag145=268443681 -flagg145=0 -tflag145=0 -initx145=0 -inity145=0 -minx145=0 -miny145=0 -maxx145=0 -maxy145=0 -posx145=50 -posy145=50 -sizx145=800 -sizy145=600 -title146=Solaris (~BAD) -path146=c:\Games\Solaris\solaris.exe -module146= -ver146=7 -flag146=973078627 -flagg146=1 -tflag146=2 -initx146=0 -inity146=0 -minx146=0 -miny146=0 -maxx146=0 -maxy146=0 -posx146=50 -posy146=50 -sizx146=800 -sizy146=600 -title147=Soldiers at War -path147=D:\Games\Soldiers at War\SAW_Game.exe -module147= -ver147=0 -flag147=671359010 -flagg147=64 -tflag147=0 -initx147=0 -inity147=0 -minx147=0 -miny147=0 -maxx147=0 -maxy147=0 -posx147=50 -posy147=50 -sizx147=640 -sizy147=480 -title148=Sonic 3 -path148=C:\Games\Sonic 3 + Sonic et Knuckles\Sonic 3\SONIC3K.EXE -module148= -ver148=1 -flag148=546 -flagg148=0 -tflag148=0 -initx148=0 -inity148=0 -minx148=0 -miny148=0 -maxx148=0 -maxy148=0 -posx148=50 -posy148=50 -sizx148=800 -sizy148=600 -title149=Sonic 3D Blast -path149=C:\Games\Sonic3D\pcsonic.exe -module149= -ver149=0 -flag149=134217762 -flagg149=0 -tflag149=0 -initx149=0 -inity149=0 -minx149=0 -miny149=0 -maxx149=0 -maxy149=0 -posx149=50 -posy149=50 -sizx149=800 -sizy149=600 -title150=Sonic R -path150=C:\Games\SonicR\sonicr.exe -module150= -ver150=0 -flag150=8288 -flagg150=0 -tflag150=0 -initx150=0 -inity150=0 -minx150=0 -miny150=0 -maxx150=0 -maxy150=0 -posx150=50 -posy150=50 -sizx150=800 -sizy150=600 -title151=Soulbringer -path151=C:\Games\SoulBringer\SoulbringeVCnoeax.exe -module151= -ver151=0 -flag151=143024174 -flagg151=0 -tflag151=0 -initx151=0 -inity151=0 -minx151=0 -miny151=0 -maxx151=0 -maxy151=0 -posx151=50 -posy151=50 -sizx151=800 -sizy151=600 -title152=Speedboat Attack (BAD) -path152=C:\Games\Speedboat Attack\SBOAT.EXE -module152= -ver152=0 -flag152=541073954 -flagg152=0 -tflag152=2 -initx152=0 -inity152=0 -minx152=0 -miny152=0 -maxx152=0 -maxy152=0 -posx152=50 -posy152=50 -sizx152=800 -sizy152=600 -title153=Star trek Klingon Honor Guard -path153=D:\Games\Star trek Klingon Honor Guard\System\Khg.exe -module153=OGIDrv.dll -ver153=10 -flag153=0 -flagg153=131585 -tflag153=387 -initx153=0 -inity153=0 -minx153=0 -miny153=0 -maxx153=0 -maxy153=0 -posx153=50 -posy153=50 -sizx153=800 -sizy153=600 -title154=Star Wars Episode 1 Racer -path154=C:\Games\sw racer\SWEP1RCR.EXE -module154= -ver154=0 -flag154=142606368 -flagg154=0 -tflag154=0 -initx154=0 -inity154=0 -minx154=0 -miny154=0 -maxx154=0 -maxy154=0 -posx154=50 -posy154=50 -sizx154=800 -sizy154=600 -title155=Star Wars Jedi Knight Jedi Academy -path155=D:\Games\Star_Wars_Jedi_Knight_Jedi_Academy\GameData\jasp.exe -module155= -ver155=10 -flag155=0 -flagg155=65536 -tflag155=2 -initx155=0 -inity155=0 -minx155=0 -miny155=0 -maxx155=0 -maxy155=0 -posx155=50 -posy155=50 -sizx155=800 -sizy155=600 -title156=Star Wars: Jedi Knight -path156=C:\Games\Jedi Knight\Jedi Knight\JK.EXE -module156= -ver156=0 -flag156=8226 -flagg156=0 -tflag156=0 -initx156=0 -inity156=0 -minx156=0 -miny156=0 -maxx156=0 -maxy156=0 -posx156=50 -posy156=50 -sizx156=800 -sizy156=600 -title157=Star Wars: the Gungan Frontier -path157=C:\Games\sw the gungan frontier\Gungan Frontier.exe -module157= -ver157=1 -flag157=402915362 -flagg157=512 -tflag157=0 -initx157=0 -inity157=0 -minx157=0 -miny157=0 -maxx157=0 -maxy157=0 -posx157=0 -posy157=0 -sizx157=800 -sizy157=600 -title158=Starship Troopers -path158=C:\Games\Starship Troopers - Terran Ascendancy\stta\StarshipTroopers.exe -module158= -ver158=1 -flag158=32 -flagg158=0 -tflag158=0 -initx158=0 -inity158=0 -minx158=0 -miny158=0 -maxx158=0 -maxy158=0 -posx158=50 -posy158=50 -sizx158=800 -sizy158=600 -title159=Starshot Space Circus -path159=D:\SpaceCircus.exe -module159= -ver159=0 -flag159=66 -flagg159=0 -tflag159=0 -initx159=0 -inity159=0 -minx159=0 -miny159=0 -maxx159=0 -maxy159=0 -posx159=50 -posy159=50 -sizx159=800 -sizy159=600 -title160=Stronghold Demo -path160=C:\Games\Firefly Studios' Stronghold - Demo\Stronghold Demo.exe -module160= -ver160=0 -flag160=98 -flagg160=0 -tflag160=0 -initx160=0 -inity160=0 -minx160=0 -miny160=0 -maxx160=0 -maxy160=0 -posx160=50 -posy160=50 -sizx160=800 -sizy160=600 -title161=Sub Culture -path161=C:\Games\Sub Culture\sc.exe -module161= -ver161=0 -flag161=66 -flagg161=256 -tflag161=10 -initx161=50 -inity161=50 -minx161=50 -miny161=50 -maxx161=800 -maxy161=600 -posx161=50 -posy161=50 -sizx161=800 -sizy161=600 -title162=Superbike 2001 -path162=C:\Games\Superbike 2001\Sbk2001.exe -module162= -ver162=1 -flag162=536887332 -flagg162=0 -tflag162=0 -initx162=0 -inity162=0 -minx162=0 -miny162=0 -maxx162=0 -maxy162=0 -posx162=50 -posy162=50 -sizx162=800 -sizy162=600 -title163=Syberia 2 Demo -path163=C:\Games\Syberia 2 Demo\Syberia2Demo.exe -module163= -ver163=8 -flag163=536887332 -flagg163=0 -tflag163=0 -initx163=0 -inity163=0 -minx163=0 -miny163=0 -maxx163=0 -maxy163=0 -posx163=50 -posy163=50 -sizx163=800 -sizy163=600 -title164=Syberia Demo -path164=C:\Games\SyberiaDemo\SyberiaDemo.exe -module164= -ver164=1 -flag164=536887332 -flagg164=0 -tflag164=0 -initx164=0 -inity164=0 -minx164=0 -miny164=0 -maxx164=0 -maxy164=0 -posx164=50 -posy164=50 -sizx164=800 -sizy164=600 -title165=System Shock 2 (BAD!!!) -path165=C:\Games\Sys Shock II\Shock2.exe -module165= -ver165=1 -flag165=0 -flagg165=64 -tflag165=0 -initx165=0 -inity165=0 -minx165=0 -miny165=0 -maxx165=0 -maxy165=0 -posx165=50 -posy165=50 -sizx165=800 -sizy165=600 -title166=Test Drive 4 -path166=D:\Games\Test Drive 4\td4.EXE -module166= -ver166=0 -flag166=-2013265885 -flagg166=-2147418094 -tflag166=2 -initx166=0 -inity166=0 -minx166=0 -miny166=0 -maxx166=0 -maxy166=0 -posx166=50 -posy166=50 -sizx166=800 -sizy166=600 -title167=The Nations Demo -path167=C:\Games\The Nations Demo\bin\Game.exe -module167= -ver167=1 -flag167=402661920 -flagg167=256 -tflag167=0 -initx167=0 -inity167=0 -minx167=0 -miny167=0 -maxx167=0 -maxy167=0 -posx167=50 -posy167=50 -sizx167=800 -sizy167=600 -title168=The Sims -path168=D:\Games\sims\Sims.exe -module168= -ver168=0 -flag168=134226976 -flagg168=65536 -tflag168=2 -initx168=0 -inity168=0 -minx168=0 -miny168=0 -maxx168=0 -maxy168=0 -posx168=50 -posy168=50 -sizx168=800 -sizy168=600 -title169=Thief the Dark Project (FRE) -path169=C:\Games\thief\game\thieffixed.exe -module169= -ver169=1 -flag169=16390 -flagg169=0 -tflag169=0 -initx169=0 -inity169=0 -minx169=0 -miny169=0 -maxx169=0 -maxy169=0 -posx169=50 -posy169=50 -sizx169=800 -sizy169=600 -title170=TinTin: Prisoners of the Sun -path170=C:\Games\tintin\TINTINW.EXE -module170= -ver170=0 -flag170=34 -flagg170=0 -tflag170=2 -initx170=0 -inity170=0 -minx170=0 -miny170=0 -maxx170=0 -maxy170=0 -posx170=50 -posy170=50 -sizx170=800 -sizy170=600 -title171=Tintoy (BAD gfx) -path171=C:\Games\Tintoy\Tintoy.exe -module171= -ver171=0 -flag171=546 -flagg171=256 -tflag171=258 -initx171=0 -inity171=0 -minx171=0 -miny171=0 -maxx171=0 -maxy171=0 -posx171=50 -posy171=50 -sizx171=800 -sizy171=600 -title172=Tomb Raider - Anniversary -path172=C:\Games\Tomb Raider - Anniversary\tra.exe -module172= -ver172=9 -flag172=0 -flagg172=256 -tflag172=2 -initx172=0 -inity172=0 -minx172=0 -miny172=0 -maxx172=0 -maxy172=0 -posx172=50 -posy172=50 -sizx172=800 -sizy172=600 -title173=Tomb Raider 2 the Golden Mask -path173=D:\Games\TR2 Golden Mask\T2GOLD.EXE -module173= -ver173=0 -flag173=570425378 -flagg173=1064960 -tflag173=258 -initx173=0 -inity173=0 -minx173=0 -miny173=0 -maxx173=0 -maxy173=0 -posx173=50 -posy173=50 -sizx173=800 -sizy173=600 -title174=Tomb Raider 3 Demo -path174=C:\Games\Tomb Raider 3 - The Lost Artifact Demo\tr3gold.exe -module174= -ver174=1 -flag174=369098848 -flagg174=0 -tflag174=258 -initx174=0 -inity174=0 -minx174=0 -miny174=0 -maxx174=0 -maxy174=0 -posx174=50 -posy174=50 -sizx174=800 -sizy174=600 -title175=Tomb Raider 4 Demo -path175=C:\Games\Tomb Raider 4 - The Last Revelation (Demo)\tomb4.patched.exe -module175= -ver175=0 -flag175=234881056 -flagg175=16 -tflag175=258 -initx175=0 -inity175=0 -minx175=0 -miny175=0 -maxx175=0 -maxy175=0 -posx175=50 -posy175=50 -sizx175=800 -sizy175=600 -title176=Total Annihilation Kingdoms -path176=D:\Games\Total Annihilation Kingdoms\Kingdoms.exe -module176= -ver176=0 -flag176=134234146 -flagg176=0 -tflag176=0 -initx176=0 -inity176=0 -minx176=0 -miny176=0 -maxx176=0 -maxy176=0 -posx176=50 -posy176=50 -sizx176=800 -sizy176=600 -title177=Total Soccer 2000 -path177=D:\Games\Total Soccer 2000\Total Soccer 2000\SOCCERDX.EXE -module177= -ver177=1 -flag177=33554434 -flagg177=1069056 -tflag177=0 -initx177=0 -inity177=0 -minx177=0 -miny177=0 -maxx177=0 -maxy177=0 -posx177=50 -posy177=50 -sizx177=800 -sizy177=600 -title178=Ultim@te Race Pro -path178=C:\Games\Ultim@te race pro\Ultim@te Race Pro.exe -module178= -ver178=0 -flag178=570425440 -flagg178=256 -tflag178=0 -initx178=0 -inity178=0 -minx178=0 -miny178=0 -maxx178=0 -maxy178=0 -posx178=50 -posy178=50 -sizx178=800 -sizy178=600 -title179=Uprising - Join or Die -path179=D:\Games\Uprising\uprising.exe -module179= -ver179=0 -flag179=-2013265882 -flagg179=18 -tflag179=0 -initx179=0 -inity179=0 -minx179=0 -miny179=0 -maxx179=0 -maxy179=0 -posx179=50 -posy179=50 -sizx179=800 -sizy179=600 -title180=Urban Assault -path180=D:\Games\Urban Assault\UA.EXE -module180= -ver180=0 -flag180=671236130 -flagg180=256 -tflag180=258 -initx180=0 -inity180=0 -minx180=0 -miny180=0 -maxx180=0 -maxy180=0 -posx180=50 -posy180=50 -sizx180=800 -sizy180=600 -title181=Warcraft 2 Battlenet Edition -path181=D:\Games\Warcraft 2\Warcraft II BNE.exe -module181= -ver181=0 -flag181=268452003 -flagg181=16 -tflag181=258 -initx181=0 -inity181=0 -minx181=0 -miny181=0 -maxx181=0 -maxy181=0 -posx181=50 -posy181=50 -sizx181=800 -sizy181=600 -title182=WarHammer Rites of War -path182=C:\Games\Rites of War\RoW.exe -module182= -ver182=0 -flag182=134217760 -flagg182=128 -tflag182=0 -initx182=0 -inity182=0 -minx182=0 -miny182=0 -maxx182=0 -maxy182=0 -posx182=50 -posy182=50 -sizx182=800 -sizy182=600 -title183=Warlords 3 -path183=D:\Games\WARLORDS3\Darklord.exe -module183= -ver183=0 -flag183=-2013264350 -flagg183=286261280 -tflag183=259 -initx183=0 -inity183=0 -minx183=0 -miny183=0 -maxx183=0 -maxy183=0 -posx183=50 -posy183=50 -sizx183=0 -sizy183=0 -title184=WarTorn -path184=C:\Games\WarTorn\W.exe -module184= -ver184=0 -flag184=32 -flagg184=0 -tflag184=0 -initx184=0 -inity184=0 -minx184=0 -miny184=0 -maxx184=0 -maxy184=0 -posx184=50 -posy184=50 -sizx184=800 -sizy184=600 -title185=WarWind -path185=C:\Games\WarWind\WW.EXE -module185= -ver185=0 -flag185=16418 -flagg185=81936 -tflag185=0 -initx185=0 -inity185=0 -minx185=0 -miny185=0 -maxx185=0 -maxy185=0 -posx185=50 -posy185=50 -sizx185=800 -sizy185=600 -title186=Worms Armageddon Demo (BAD!!!) -path186=C:\Games\Worms Armageddon Demo\WaDemo.exe -module186= -ver186=1 -flag186=939524099 -flagg186=8 -tflag186=2 -initx186=0 -inity186=0 -minx186=0 -miny186=0 -maxx186=0 -maxy186=0 -posx186=0 -posy186=0 -sizx186=0 -sizy186=0 -title187=Worms World Party -path187=D:\Games\Worms World Party\wwp.exe -module187= -ver187=1 -flag187=8388610 -flagg187=0 -tflag187=0 -initx187=0 -inity187=0 -minx187=0 -miny187=0 -maxx187=0 -maxy187=0 -posx187=50 -posy187=50 -sizx187=800 -sizy187=600 -maxfps0=0 -maxfps1=40 -maxfps2=0 -maxfps3=0 -maxfps4=0 -maxfps5=0 -maxfps6=10 -maxfps7=40 -maxfps8=0 -maxfps9=0 -maxfps10=0 -maxfps11=0 -maxfps12=0 -maxfps13=0 -maxfps14=0 -maxfps15=0 -maxfps16=0 -maxfps17=0 -maxfps18=0 -maxfps19=0 -maxfps20=0 -maxfps21=0 -maxfps22=0 -maxfps23=0 -maxfps24=0 -maxfps25=0 -maxfps26=0 -maxfps27=0 -maxfps28=0 -maxfps29=0 -maxfps30=0 -maxfps31=0 -maxfps32=0 -maxfps33=0 -maxfps34=0 -maxfps35=0 -maxfps36=0 -maxfps37=0 -maxfps38=0 -maxfps39=0 -maxfps40=0 -maxfps41=0 -maxfps42=0 -maxfps43=0 -maxfps44=0 -maxfps45=0 -maxfps46=0 -maxfps47=0 -maxfps48=0 -maxfps49=0 -maxfps50=0 -maxfps51=0 -maxfps52=0 -maxfps53=0 -maxfps54=0 -maxfps55=0 -maxfps56=100 -maxfps57=0 -maxfps58=500 -maxfps59=0 -maxfps60=0 -maxfps61=0 -maxfps62=0 -maxfps63=0 -maxfps64=0 -maxfps65=0 -maxfps66=0 -maxfps67=0 -maxfps68=0 -maxfps69=0 -maxfps70=0 -maxfps71=0 -maxfps72=0 -maxfps73=0 -maxfps74=0 -maxfps75=0 -maxfps76=0 -maxfps77=0 -maxfps78=0 -maxfps79=0 -maxfps80=0 -maxfps81=0 -maxfps82=0 -maxfps83=0 -maxfps84=0 -maxfps85=0 -maxfps86=0 -maxfps87=50 -maxfps88=0 -maxfps89=0 -maxfps90=25 -maxfps91=0 -maxfps92=0 -maxfps93=0 -maxfps94=0 -maxfps95=0 -maxfps96=0 -maxfps97=100 -maxfps98=0 -maxfps99=0 -maxfps100=0 -maxfps101=0 -maxfps102=0 -maxfps103=0 -maxfps104=0 -maxfps105=0 -maxfps106=0 -maxfps107=0 -maxfps108=0 -maxfps109=0 -maxfps110=0 -maxfps111=0 -maxfps112=0 -maxfps113=0 -maxfps114=0 -maxfps115=0 -maxfps116=0 -maxfps117=0 -maxfps118=0 -maxfps119=0 -maxfps120=0 -maxfps121=0 -maxfps122=0 -maxfps123=0 -maxfps124=0 -maxfps125=0 -maxfps126=0 -maxfps127=0 -maxfps128=0 -maxfps129=0 -maxfps130=0 -maxfps131=0 -maxfps132=0 -maxfps133=0 -maxfps134=50 -maxfps135=0 -maxfps136=0 -maxfps137=0 -maxfps138=0 -maxfps139=0 -maxfps140=0 -maxfps141=0 -maxfps142=0 -maxfps143=0 -maxfps144=0 -maxfps145=0 -maxfps146=0 -maxfps147=0 -maxfps148=0 -maxfps149=0 -maxfps150=0 -maxfps151=0 -maxfps152=0 -maxfps153=0 -maxfps154=0 -maxfps155=0 -maxfps156=0 -maxfps157=0 -maxfps158=0 -maxfps159=0 -maxfps160=0 -maxfps161=0 -maxfps162=0 -maxfps163=0 -maxfps164=0 -maxfps165=0 -maxfps166=0 -maxfps167=0 -maxfps168=0 -maxfps169=0 -maxfps170=0 -maxfps171=0 -maxfps172=0 -maxfps173=0 -maxfps174=0 -maxfps175=0 -maxfps176=0 -maxfps177=200 -maxfps178=0 -maxfps179=0 -maxfps180=0 -maxfps181=40 -maxfps182=0 -maxfps183=0 -maxfps184=0 -maxfps185=0 -maxfps186=0 -maxfps187=0 -title188=Worms World Party Demo (BAD) -path188=C:\Games\WWP Demo\wwp.exe -module188=MFC42.DLL ltkrn10N.dll -ver188=1 -flag188=406847491 -flagg188=8 -tflag188=2 -initx188=0 -inity188=0 -minx188=0 -miny188=0 -maxx188=0 -maxy188=0 -posx188=0 -posy188=0 -sizx188=0 -maxfps188=0 -opengllib0= -initts0=-8 -opengllib1= -initts1=-7 -opengllib2= -initts2=-7 -opengllib3= -initts3=0 -opengllib4= -initts4=0 -opengllib5= -initts5=0 -opengllib6= -initts6=0 -opengllib7= -initts7=0 -opengllib8= -initts8=0 -opengllib9= -initts9=0 -opengllib10= -initts10=0 -opengllib11= -initts11=0 -opengllib12= -initts12=0 -opengllib13= -initts13=0 -opengllib14= -initts14=0 -opengllib15= -initts15=0 -opengllib16= -initts16=0 -opengllib17= -initts17=0 -opengllib18= -initts18=0 -opengllib19= -initts19=0 -opengllib20= -initts20=0 -opengllib21= -initts21=0 -opengllib22= -initts22=0 -opengllib23= -initts23=0 -opengllib24= -initts24=0 -opengllib25= -initts25=0 -opengllib26= -initts26=0 -opengllib27= -initts27=0 -opengllib28= -initts28=0 -opengllib29= -initts29=0 -opengllib30= -initts30=0 -opengllib31= -initts31=0 -opengllib32= -initts32=0 -opengllib33= -initts33=0 -opengllib34= -initts34=0 -opengllib35= -initts35=0 -opengllib36= -initts36=0 -opengllib37= -initts37=0 -opengllib38= -initts38=0 -opengllib39= -initts39=0 -opengllib40= -initts40=0 -opengllib41= -initts41=0 -opengllib42= -initts42=0 -opengllib43= -initts43=0 -opengllib44= -initts44=0 -opengllib45= -initts45=0 -opengllib46= -initts46=0 -opengllib47= -initts47=0 -opengllib48= -initts48=0 -opengllib49= -initts49=0 -opengllib50= -initts50=0 -opengllib51= -initts51=0 -opengllib52= -initts52=0 -opengllib53= -initts53=0 -opengllib54= -initts54=0 -opengllib55= -initts55=0 -opengllib56= -initts56=-5 -opengllib57= -initts57=0 -opengllib58= -initts58=0 -opengllib59= -initts59=0 -opengllib60= -initts60=0 -opengllib61= -initts61=0 -opengllib62= -initts62=0 -opengllib63= -initts63=0 -opengllib64= -initts64=0 -opengllib65= -initts65=0 -opengllib66= -initts66=0 -opengllib67= -initts67=0 -opengllib68= -initts68=0 -opengllib69= -initts69=0 -opengllib70= -initts70=0 -opengllib71= -initts71=0 -opengllib72= -initts72=0 -opengllib73= -initts73=0 -opengllib74= -initts74=0 -opengllib75= -initts75=0 -opengllib76= -initts76=0 -opengllib77= -initts77=0 -opengllib78= -initts78=0 -opengllib79= -initts79=0 -opengllib80= -initts80=0 -opengllib81= -initts81=0 -opengllib82= -initts82=0 -opengllib83= -initts83=4 -opengllib84= -initts84=0 -opengllib85= -initts85=0 -opengllib86= -initts86=0 -opengllib87= -initts87=8 -opengllib88= -initts88=8 -opengllib89= -initts89=0 -opengllib90= -initts90=1 -opengllib91= -initts91=0 -opengllib92= -initts92=0 -opengllib93= -initts93=0 -opengllib94= -initts94=0 -opengllib95= -initts95=0 -opengllib96= -initts96=0 -opengllib97= -initts97=3 -opengllib98= -initts98=0 -opengllib99= -initts99=0 -opengllib100= -initts100=0 -opengllib101= -initts101=0 -opengllib102= -initts102=0 -opengllib103= -initts103=0 -opengllib104= -initts104=0 -opengllib105= -initts105=0 -opengllib106= -initts106=0 -opengllib107= -initts107=0 -opengllib108= -initts108=0 -opengllib109= -initts109=0 -opengllib110= -initts110=0 -opengllib111= -initts111=0 -opengllib112= -initts112=0 -opengllib113= -initts113=0 -opengllib114= -initts114=0 -opengllib115= -initts115=0 -opengllib116= -initts116=0 -opengllib117= -initts117=0 -opengllib118= -initts118=0 -opengllib119= -initts119=0 -opengllib120= -initts120=0 -opengllib121= -initts121=0 -opengllib122= -initts122=0 -opengllib123= -initts123=0 -opengllib124= -initts124=0 -opengllib125= -initts125=0 -opengllib126= -initts126=0 -opengllib127= -initts127=0 -opengllib128= -initts128=0 -opengllib129= -initts129=0 -opengllib130= -initts130=0 -opengllib131= -initts131=0 -opengllib132= -initts132=0 -opengllib133= -initts133=0 -opengllib134= -initts134=-4 -opengllib135= -initts135=0 -opengllib136= -initts136=0 -opengllib137= -initts137=0 -opengllib138= -initts138=0 -opengllib139= -initts139=0 -opengllib140= -initts140=0 -opengllib141= -initts141=0 -opengllib142= -initts142=0 -opengllib143= -initts143=0 -opengllib144= -initts144=0 -opengllib145= -initts145=0 -opengllib146= -initts146=0 -opengllib147= -initts147=0 -opengllib148= -initts148=0 -opengllib149= -initts149=0 -opengllib150= -initts150=0 -opengllib151= -initts151=0 -opengllib152= -initts152=0 -opengllib153= -initts153=0 -opengllib154= -initts154=0 -opengllib155= -initts155=0 -opengllib156= -initts156=0 -opengllib157= -initts157=0 -opengllib158= -initts158=0 -opengllib159= -initts159=0 -opengllib160= -initts160=0 -opengllib161= -initts161=0 -opengllib162= -initts162=0 -opengllib163= -initts163=0 -opengllib164= -initts164=0 -opengllib165= -initts165=0 -opengllib166= -initts166=-2 -opengllib167= -initts167=0 -opengllib168= -initts168=0 -opengllib169= -initts169=0 -opengllib170= -initts170=0 -opengllib171= -initts171=0 -opengllib172= -initts172=8 -opengllib173= -initts173=8 -opengllib174= -initts174=0 -opengllib175= -initts175=0 -opengllib176= -initts176=0 -opengllib177= -initts177=0 -opengllib178= -initts178=0 -opengllib179= -initts179=0 -opengllib180= -initts180=0 -opengllib181= -initts181=0 -opengllib182= -initts182=0 -opengllib183= -initts183=0 -opengllib184= -initts184=0 -opengllib185= -initts185=0 -opengllib186= -initts186=0 -opengllib187= -initts187=0 -opengllib188= -sizy188=0 -initts188=0 -title189=X-Com Enforcer -path189=C:\Games\X-Com Enforcer\System\xcom.exe -module189= -opengllib189= -ver189=1 -flag189=32 -flagg189=0 -tflag189=0 -initx189=0 -inity189=0 -minx189=0 -miny189=0 -maxx189=0 -maxy189=0 -posx189=0 -posy189=0 -sizx189=800 -sizy189=600 -maxfps189=0 -initts189=0 -title190=X-Com Interceptor -module190= -opengllib190= -path190=C:\Games\X-Com_Interceptor\X-COM Interceptor\Interceptor.exe -ver190=0 -flag190=16418 -flagg190=0 -tflag190=0 -initx190=0 -inity190=0 -minx190=0 -miny190=0 -maxx190=0 -maxy190=0 -posx190=50 -posy190=50 -sizx190=800 -sizy190=600 -maxfps190=0 -initts190=0 -title191=Z Steel Soldiers -path191=C:\Games\ZSteelSoldiers\Bin\z2.exe -module191= -opengllib191= -ver191=8 -flag191=805462020 -flagg191=0 -tflag191=0 -initx191=0 -inity191=0 -minx191=0 -miny191=0 -maxx191=0 -maxy191=0 -posx191=50 -posy191=50 -sizx191=800 -sizy191=600 -maxfps191=0 -initts191=0 -title192=Zax Alien Hunter -path192=C:\Games\ZaxDemo\Zax.exe -module192= -opengllib192= -ver192=0 -flag192=-1476386784 -flagg192=0 -tflag192=0 -initx192=0 -inity192=0 -minx192=0 -miny192=0 -maxx192=0 -maxy192=0 -posx192=50 -posy192=50 -sizx192=800 -sizy192=600 -maxfps192=0 -initts192=0 -title193=Zero Critical (BAD) -path193=C:\Games\zero_critical_-_satin_rift\ZEROCR.EXE -module193= -opengllib193= -ver193=0 -flag193=679477858 -flagg193=8 -tflag193=0 -initx193=0 -inity193=0 -minx193=0 -miny193=0 -maxx193=0 -maxy193=0 -posx193=0 -posy193=0 -sizx193=800 -sizy193=600 -maxfps193=0 -initts193=0 -title194=Zero Population Count -path194=C:\Games\ZPC\ZPC.EXE -module194= -opengllib194= -ver194=0 -flag194=1073741859 -flagg194=0 -tflag194=0 -initx194=0 -inity194=0 -minx194=0 -miny194=0 -maxx194=0 -maxy194=0 -posx194=0 -posy194=0 -sizx194=800 -sizy194=600 -maxfps194=0 -initts194=0 -title195=Zero Zone -path195=D:\ZZone\ZeroZone.exe -module195= -opengllib195= -ver195=0 -flag195=34 -flagg195=0 -tflag195=0 -initx195=0 -inity195=0 -minx195=0 -miny195=0 -maxx195=0 -maxy195=0 -posx195=50 -posy195=50 -sizx195=800 -sizy195=600 -maxfps195=0 -initts195=0 -title196=Zeus Poseidon -path196=C:\Games\Zeus-Poseidon\Zeus.exe -module196= -opengllib196= -ver196=0 -flag196=34 -flagg196=0 -tflag196=0 -initx196=0 -inity196=0 -minx196=0 -miny196=0 -maxx196=0 -maxy196=0 -posx196=50 -posy196=50 -sizx196=800 -sizy196=600 -maxfps196=0 -initts196=0 - -title197=Zoo Tycoon -path197=C:\Games\Zoo Tycoon\zoo.exe -module197= -opengllib197= -ver197=0 -flag197=-2013265886 -flagg197=0 -tflag197=0 -initx197=0 -inity197=0 -minx197=0 -miny197=0 -maxx197=0 -maxy197=0 -posx197=50 -posy197=50 -sizx197=800 -sizy197=600 -maxfps197=0 -initts197=0 -title198=Doom 95 -path198=D:\Games\Doom95\DOOM95.EXE -module198= -opengllib198= -ver198=0 -flag198=134217762 -flagg198=2113536 -tflag198=258 -initx198=0 -inity198=0 -minx198=0 -miny198=0 -maxx198=0 -maxy198=0 -posx198=50 -posy198=50 -sizx198=800 -sizy198=600 -maxfps198=20 -initts198=-9 -title199=Urban Assault CD -path199=D:\Games\Urban Assault CD\UA.EXE -module199= -opengllib199= -ver199=0 -flag199=671236130 -flagg199=33024 -tflag199=258 -initx199=0 -inity199=0 -minx199=0 -miny199=0 -maxx199=0 -maxy199=0 -posx199=50 -posy199=50 -sizx199=800 -sizy199=600 -maxfps199=0 -initts199=0 -title200=Starcraft -path200=D:\Games\Starcraft\StarCraft.exe -module200= -opengllib200= -ver200=0 -flag200=134234115 -flagg200=2179088 -tflag200=258 -initx200=0 -inity200=0 -minx200=0 -miny200=0 -maxx200=0 -maxy200=0 -posx200=50 -posy200=50 -sizx200=800 -sizy200=600 -maxfps200=0 -initts200=0 -title201=Battle Commander -path201=D:\Games\Battle Commander\bcommand.exe -module201= -opengllib201= -ver201=0 -flag201=134217794 -flagg201=0 -tflag201=2 -initx201=0 -inity201=0 -minx201=0 -miny201=0 -maxx201=0 -maxy201=0 -posx201=50 -posy201=50 -sizx201=800 -sizy201=600 -maxfps201=0 -initts201=0 -title202=Pandemonium 2 -path202=D:\Games\Pandemonium 2\pandy.exe -module202= -opengllib202= -ver202=0 -flag202=671219714 -flagg202=1 -tflag202=0 -initx202=0 -inity202=0 -minx202=0 -miny202=0 -maxx202=0 -maxy202=0 -posx202=50 -posy202=50 -sizx202=800 -sizy202=600 -maxfps202=0 -initts202=0 -title203=Pharaoh -path203=D:\Games\Pharaoh\Pharaoh.exe -module203= -opengllib203= -ver203=0 -flag203=1208483874 -flagg203=1048576 -tflag203=0 -initx203=0 -inity203=0 -minx203=0 -miny203=0 -maxx203=0 -maxy203=0 -posx203=50 -posy203=50 -sizx203=800 -sizy203=600 -maxfps203=0 -initts203=0 -title204=Postal -path204=D:\Games\Postal\POSTAL.EXE -module204= -opengllib204= -ver204=1 -flag204=537133059 -flagg204=65600 -tflag204=266 -initx204=0 -inity204=0 -minx204=0 -miny204=0 -maxx204=0 -maxy204=0 -posx204=50 -posy204=50 -sizx204=800 -sizy204=600 -maxfps204=0 -initts204=-3 -title205=Test Drive 5 (D3D) -path205=D:\Games\Test Drive 5\TD5_D3D.exe -module205= -opengllib205= -ver205=0 -flag205=536870944 -flagg205=-2147483648 -tflag205=263 -initx205=0 -inity205=0 -minx205=0 -miny205=0 -maxx205=0 -maxy205=0 -posx205=50 -posy205=50 -sizx205=800 -sizy205=600 -maxfps205=0 -initts205=0 -title206=Take no Prisoners -path206=D:\Games\Take no Prisoners\TNP.EXE -module206= -opengllib206= -ver206=0 -flag206=2 -flagg206=16777248 -tflag206=0 -initx206=0 -inity206=0 -minx206=0 -miny206=0 -maxx206=0 -maxy206=0 -posx206=50 -posy206=50 -sizx206=800 -sizy206=600 -maxfps206=0 -initts206=0 -title207=Fallen Heaven -path207=D:\Games\Fallen haven\Exe\FALLEN.EXE -module207=MFC42.dll MSVCRT.DLL mciavi32.dll -opengllib207= -ver207=1 -flag207=135004674 -flagg207=1049120 -tflag207=259 -initx207=0 -inity207=0 -minx207=0 -miny207=0 -maxx207=0 -maxy207=0 -posx207=50 -posy207=50 -sizx207=800 -sizy207=600 -maxfps207=0 -initts207=0 -title208=Grand Theft Auto 2 -path208=D:\Games\GTA2\gta2.exe -module208=binkw32 d3ddll -opengllib208= -ver208=0 -flag208=671096866 -flagg208=1048576 -tflag208=3 -initx208=0 -inity208=0 -minx208=0 -miny208=0 -maxx208=0 -maxy208=0 -posx208=50 -posy208=50 -sizx208=400 -sizy208=300 -maxfps208=0 -initts208=0 -title209=Grand Prix Legends MAX -module209= -opengllib209= -path209=D:\Games\Grand Prix Legends MAX\gpl.exe -ver209=7 -flag209=537001986 -flagg209=134217729 -tflag209=3 -initx209=0 -inity209=0 -minx209=0 -miny209=0 -maxx209=0 -maxy209=0 -posx209=50 -posy209=50 -sizx209=800 -sizy209=600 -maxfps209=0 -initts209=0 -title210=688I Hunter Killer -path210=D:\Games\688\688I_HK.EXE -module210= -opengllib210= -ver210=0 -flag210=134479906 -flagg210=134217728 -tflag210=3 -initx210=0 -inity210=0 -minx210=0 -miny210=0 -maxx210=0 -maxy210=0 -posx210=50 -posy210=50 -sizx210=640 -sizy210=480 -maxfps210=0 -initts210=0 -title211=Gruntz -path211=D:\Games\gruntz\GRUNTZ.EXE -module211= -opengllib211= -ver211=0 -flag211=34 -flagg211=134217728 -tflag211=0 -initx211=0 -inity211=0 -minx211=0 -miny211=0 -maxx211=0 -maxy211=0 -posx211=50 -posy211=50 -sizx211=800 -sizy211=600 -maxfps211=0 -initts211=0 -title212=Grand Touring -path212=D:\Games\Grand Touring\gt.exe -module212= -opengllib212= -ver212=0 -flag212=16388 -flagg212=134283264 -tflag212=275 -initx212=0 -inity212=0 -minx212=0 -miny212=0 -maxx212=0 -maxy212=0 -posx212=50 -posy212=50 -sizx212=400 -sizy212=300 -maxfps212=0 -initts212=8 -title213=Gunman Chronicles -path213=D:\Games\Gunman\gunman.exe -module213= -opengllib213= -ver213=0 -flag213=0 -flagg213=-2013134848 -tflag213=0 -initx213=0 -inity213=0 -minx213=0 -miny213=0 -maxx213=0 -maxy213=0 -posx213=0 -posy213=0 -sizx213=400 -sizy213=300 -maxfps213=0 -initts213=0 -title214=Nocturne -path214=D:\Games\Nocturne\nocturne.exe -module214= -opengllib214= -ver214=0 -flag214=2 -flagg214=402653264 -tflag214=387 -initx214=0 -inity214=0 -minx214=0 -miny214=0 -maxx214=0 -maxy214=0 -posx214=50 -posy214=50 -sizx214=400 -sizy214=300 -maxfps214=0 -initts214=0 -title215=Koplio -path215=D:\Games\Koplio\KOPLIO.exe -module215= -opengllib215= -ver215=0 -flag215=545259520 -flagg215=134217729 -tflag215=0 -initx215=0 -inity215=0 -minx215=0 -miny215=0 -maxx215=0 -maxy215=0 -posx215=50 -posy215=50 -sizx215=800 -sizy215=600 -maxfps215=0 -initts215=0 -title216=Nightmare Ned -path216=D:\Games\Ned\NITENED.EXE -module216= -opengllib216= -ver216=0 -flag216=537395202 -flagg216=135266305 -tflag216=0 -initx216=0 -inity216=0 -minx216=0 -miny216=0 -maxx216=0 -maxy216=0 -posx216=0 -posy216=0 -sizx216=800 -sizy216=600 -maxfps216=0 -initts216=0 -title217=Rollcage -path217=D:\Games\Rollcage\Direct3D\Rollcage.exe -module217= -opengllib217= -ver217=0 -flag217=268698112 -flagg217=-2013200384 -tflag217=387 -initx217=0 -inity217=0 -minx217=0 -miny217=0 -maxx217=0 -maxy217=0 -posx217=50 -posy217=50 -sizx217=800 -sizy217=600 -maxfps217=0 -initts217=3 -title218=Rogue Spear (BAD) -module218= -opengllib218= -path218=D:\Games\Rogue Spear\RogueSpear.exe -ver218=1 -flag218=16388 -flagg218=134217984 -tflag218=2 -initx218=0 -inity218=0 -minx218=0 -miny218=0 -maxx218=0 -maxy218=0 -posx218=50 -posy218=50 -sizx218=400 -sizy218=300 -maxfps218=0 -initts218=0 -title219=Black Thorn -path219=D:\Games\BlackThorn\BlackThorn.exe -module219= -opengllib219= -ver219=0 -flag219=0 -flagg219=-2013265664 -tflag219=66 -initx219=0 -inity219=0 -minx219=0 -miny219=0 -maxx219=0 -maxy219=0 -posx219=50 -posy219=50 -sizx219=800 -sizy219=600 -maxfps219=0 -initts219=0 -title220=Wargames (demo) -path220=D:\Games\Wargames\wargames.exe -module220= -opengllib220= -ver220=0 -flag220=268436642 -flagg220=134217728 -tflag220=3 -initx220=0 -inity220=0 -minx220=0 -miny220=0 -maxx220=0 -maxy220=0 -posx220=50 -posy220=50 -sizx220=800 -sizy220=600 -maxfps220=0 -initts220=0 -title221=Silent Storm Demo -path221=D:\Games\Silent Storm Demo\SilentStormDemo.exe -module221= -opengllib221= -ver221=0 -flag221=536870913 -flagg221=-2013265664 -tflag221=3 -initx221=0 -inity221=0 -minx221=0 -miny221=0 -maxx221=0 -maxy221=0 -posx221=50 -posy221=50 -sizx221=800 -sizy221=600 -maxfps221=0 -initts221=0 -title222=glsample.exe -path222=D:\DxWnd\code examples\glsample\Debug\glsample.exe -module222= -opengllib222= -ver222=0 -flag222=0 -flagg222=134348800 -tflag222=3 -initx222=0 -inity222=0 -minx222=0 -miny222=0 -maxx222=0 -maxy222=0 -posx222=0 -posy222=0 -sizx222=800 -sizy222=600 -maxfps222=0 -initts222=0 -flagh0=0 -flagi0=0 -flagh1=0 -flagi1=0 -flagh2=0 -flagi2=0 -flagh3=0 -flagi3=0 -flagh4=0 -flagi4=0 -flagh5=0 -flagi5=0 -flagh6=0 -flagi6=0 -flagh7=0 -flagi7=0 -flagh8=0 -flagi8=0 -flagh9=0 -flagi9=0 -flagh10=2 -flagi10=0 -flagh11=0 -flagi11=0 -flagh12=0 -flagi12=0 -flagh13=0 -flagi13=0 -flagh14=0 -flagi14=0 -flagh15=0 -flagi15=0 -flagh16=0 -flagi16=0 -flagh17=0 -flagi17=0 -flagh18=0 -flagi18=0 -flagh19=0 -flagi19=0 -flagh20=0 -flagi20=0 -flagh21=0 -flagi21=0 -flagh22=0 -flagi22=0 -flagh23=0 -flagi23=0 -flagh24=0 -flagi24=0 -flagh25=0 -flagi25=0 -flagh26=0 -flagi26=0 -flagh27=0 -flagi27=0 -flagh28=0 -flagi28=0 -flagh29=0 -flagi29=0 -flagh30=0 -flagi30=0 -flagh31=0 -flagi31=0 -flagh32=0 -flagi32=0 -flagh33=0 -flagi33=0 -flagh34=0 -flagi34=0 -flagh35=0 -flagi35=0 -flagh36=0 -flagi36=0 -flagh37=0 -flagi37=0 -flagh38=0 -flagi38=0 -flagh39=0 -flagi39=0 -flagh40=0 -flagi40=0 -flagh41=0 -flagi41=0 -flagh42=0 -flagi42=0 -flagh43=0 -flagi43=0 -flagh44=0 -flagi44=0 -flagh45=0 -flagi45=0 -flagh46=0 -flagi46=0 -flagh47=0 -flagi47=0 -flagh48=0 -flagi48=0 -flagh49=0 -flagi49=0 -flagh50=0 -flagi50=0 -flagh51=0 -flagi51=0 -flagh52=0 -flagi52=0 -flagh53=0 -flagi53=0 -flagh54=0 -flagi54=0 -flagh55=0 -flagi55=0 -flagh56=0 -flagi56=0 -flagh57=0 -flagi57=0 -flagh58=0 -flagi58=0 -flagh59=0 -flagi59=0 -flagh60=2 -flagi60=0 -flagh61=0 -flagi61=0 -flagh62=0 -flagi62=0 -flagh63=0 -flagi63=0 -flagh64=0 -flagi64=0 -flagh65=0 -flagi65=0 -flagh66=0 -flagi66=0 -flagh67=0 -flagi67=0 -flagh68=0 -flagi68=0 -flagh69=0 -flagi69=0 -flagh70=0 -flagi70=0 -flagh71=0 -flagi71=0 -flagh72=0 -flagi72=0 -flagh73=0 -flagi73=0 -flagh74=0 -flagi74=0 -flagh75=0 -flagi75=0 -flagh76=0 -flagi76=0 -flagh77=0 -flagi77=0 -flagh78=0 -flagi78=0 -flagh79=0 -flagi79=0 -flagh80=0 -flagi80=0 -flagh81=0 -flagi81=0 -flagh82=0 -flagi82=0 -flagh83=0 -flagi83=0 -flagh84=0 -flagi84=0 -flagh85=0 -flagi85=0 -flagh86=0 -flagi86=0 -flagh87=0 -flagi87=0 -flagh88=0 -flagi88=0 -flagh89=0 -flagi89=0 -flagh90=0 -flagi90=0 -flagh91=0 -flagi91=0 -flagh92=0 -flagi92=0 -flagh93=0 -flagi93=0 -flagh94=0 -flagi94=0 -flagh95=0 -flagi95=0 -flagh96=0 -flagi96=0 -flagh97=0 -flagi97=0 -flagh98=0 -flagi98=0 -flagh99=0 -flagi99=0 -flagh100=0 -flagi100=0 -flagh101=0 -flagi101=0 -flagh102=0 -flagi102=0 -flagh103=0 -flagi103=0 -flagh104=0 -flagi104=0 -flagh105=0 -flagi105=0 -flagh106=0 -flagi106=0 -flagh107=0 -flagi107=0 -flagh108=0 -flagi108=0 -flagh109=0 -flagi109=0 -flagh110=0 -flagi110=0 -flagh111=0 -flagi111=0 -flagh112=0 -flagi112=0 -flagh113=0 -flagi113=0 -flagh114=0 -flagi114=0 -flagh115=0 -flagi115=0 -flagh116=0 -flagi116=0 -flagh117=0 -flagi117=0 -flagh118=0 -flagi118=0 -flagh119=0 -flagi119=0 -flagh120=0 -flagi120=0 -flagh121=0 -flagi121=0 -flagh122=0 -flagi122=0 -flagh123=0 -flagi123=0 -flagh124=0 -flagi124=0 -flagh125=0 -flagi125=0 -flagh126=0 -flagi126=0 -flagh127=0 -flagi127=0 -flagh128=0 -flagi128=0 -flagh129=0 -flagi129=0 -flagh130=0 -flagi130=0 -flagh131=0 -flagi131=0 -flagh132=0 -flagi132=0 -flagh133=0 -flagi133=0 -flagh134=0 -flagi134=0 -flagh135=0 -flagi135=0 -flagh136=0 -flagi136=0 -flagh137=0 -flagi137=0 -flagh138=0 -flagi138=0 -flagh139=0 -flagi139=0 -flagh140=0 -flagi140=0 -flagh141=0 -flagi141=0 -flagh142=0 -flagi142=0 -flagh143=0 -flagi143=0 -flagh144=0 -flagi144=0 -flagh145=0 -flagi145=0 -flagh146=0 -flagi146=0 -flagh147=0 -flagi147=0 -flagh148=0 -flagi148=0 -flagh149=0 -flagi149=0 -flagh150=0 -flagi150=0 -flagh151=0 -flagi151=0 -flagh152=0 -flagi152=0 -flagh153=0 -flagi153=0 -flagh154=0 -flagi154=0 -flagh155=0 -flagi155=0 -flagh156=0 -flagi156=0 -flagh157=0 -flagi157=0 -flagh158=0 -flagi158=0 -flagh159=0 -flagi159=0 -flagh160=0 -flagi160=0 -flagh161=0 -flagi161=0 -flagh162=0 -flagi162=0 -flagh163=0 -flagi163=0 -flagh164=0 -flagi164=0 -flagh165=0 -flagi165=0 -flagh166=0 -flagi166=0 -flagh167=0 -flagi167=0 -flagh168=0 -flagi168=0 -flagh169=0 -flagi169=0 -flagh170=0 -flagi170=0 -flagh171=0 -flagi171=0 -flagh172=0 -flagi172=0 -flagh173=0 -flagi173=0 -flagh174=0 -flagi174=0 -flagh175=0 -flagi175=0 -flagh176=2 -flagi176=0 -flagh177=0 -flagi177=0 -flagh178=0 -flagi178=0 -flagh179=0 -flagi179=0 -flagh180=0 -flagi180=0 -flagh181=0 -flagi181=0 -flagh182=0 -flagi182=0 -flagh183=0 -flagi183=0 -flagh184=0 -flagi184=0 -flagh185=0 -flagi185=0 -flagh186=0 -flagi186=0 -flagh187=0 -flagi187=0 -flagh188=0 -flagi188=0 -flagh189=0 -flagi189=0 -flagh190=0 -flagi190=0 -flagh191=0 -flagi191=0 -flagh192=0 -flagi192=0 -flagh193=0 -flagi193=0 -flagh194=0 -flagi194=0 -flagh195=0 -flagi195=0 -flagh196=0 -flagi196=0 -flagh197=0 -flagi197=0 -flagh198=0 -flagi198=0 -flagh199=0 -flagi199=0 -flagh200=0 -flagi200=0 -flagh201=0 -flagi201=0 -flagh202=0 -flagi202=0 -flagh203=0 -flagi203=0 -flagh204=0 -flagi204=0 -flagh205=2 -flagi205=0 -flagh206=0 -flagi206=0 -flagh207=0 -flagi207=0 -flagh208=0 -flagi208=0 -flagh209=0 -flagi209=0 -flagh210=0 -flagi210=0 -flagh211=0 -flagi211=0 -flagh212=0 -flagi212=0 -flagh213=0 -flagi213=0 -flagh214=0 -flagi214=0 -flagh215=0 -flagi215=0 -flagh216=0 -flagi216=0 -flagh217=0 -flagi217=0 -flagh218=0 -flagi218=0 -flagh219=0 -flagi219=0 -flagh220=0 -flagi220=0 -flagh221=0 -flagi221=0 -flagh222=0 -flagi222=0 -title223=Dungeon Keeper D3D -path223=D:\Games\Keeper95\keepd3d.exe -module223= -opengllib223= -ver223=0 -flag223=134217760 -flagg223=134217728 -flagh223=1 -flagi223=0 -tflag223=3 -initx223=0 -inity223=0 -minx223=0 -miny223=0 -maxx223=0 -maxy223=0 -posx223=50 -posy223=50 -sizx223=800 -sizy223=600 -maxfps223=0 -initts223=0 -title224=Gangsters -path224=D:\Games\Gangsters\gangsters.exe -module224= -opengllib224= -ver224=0 -flag224=134217730 -flagg224=135266304 -flagh224=0 -flagi224=0 -tflag224=0 -initx224=0 -inity224=0 -minx224=0 -miny224=0 -maxx224=0 -maxy224=0 -posx224=50 -posy224=50 -sizx224=800 -sizy224=600 -maxfps224=0 -initts224=0 [window] -posx=1443 -posy=162 -sizx=320 -sizy=527 +posx=2 +posy=2 +sizx=300 +sizy=138 diff --git a/build/readme-relnotes.txt b/build/readme-relnotes.txt index a04251d..20df778 100644 --- a/build/readme-relnotes.txt +++ b/build/readme-relnotes.txt @@ -111,7 +111,12 @@ Disabled hooking of system libraries Fixed a nasty bug that caused your desktop to freeze until shutdown !!! Fixed GetWindowRect handling for windows not created by the task: Diablo queries the explorer window size! Now the retrieved RECT can't be larger than the virtual desktop +v2.02.20 +Fixed an error in D3D10/11 preliminary code: AoE III working again +Added "Hook all DLLs" option to simplify congiguration: see new Diablo setup +Added screen coordinates to log +Some code rearrangement - - +v2.02.21 +it's a w.i.p. release, wait 'till finished.... diff --git a/dll/dxhook.cpp b/dll/dxhook.cpp index 1f4adb6..98dba3d 100644 --- a/dll/dxhook.cpp +++ b/dll/dxhook.cpp @@ -20,6 +20,9 @@ dxwCore dxw; extern void InitScreenParameters(); +void HookModule(HMODULE, int); +static void RecoverScreenMode(); +static void LockScreenMode(DWORD, DWORD, DWORD); extern HANDLE hTraceMutex; @@ -48,7 +51,7 @@ static char *Flag2Names[32]={ }; static char *Flag3Names[32]={ - "FORCEHOOKOPENGL", "", "", "", + "FORCEHOOKOPENGL", "MARKBLIT", "HOOKDLLS", "SUPPRESSD3DEXT", "", "", "", "", "", "", "", "", "", "", "", "", @@ -147,6 +150,68 @@ static void dx_ToggleLogging() GetHookInfo()->isLogging=(dxw.dwTFlags & OUTTRACE); } +void HookDlls(HMODULE module) +{ + PIMAGE_NT_HEADERS pnth; + PIMAGE_IMPORT_DESCRIPTOR pidesc; + DWORD base, rva; + PSTR impmodule; + PIMAGE_THUNK_DATA ptname; + extern char *SysNames[]; + + base=(DWORD)module; + OutTraceB("HookDlls: base=%x\n", base); + __try{ + pnth = PIMAGE_NT_HEADERS(PBYTE(base) + PIMAGE_DOS_HEADER(base)->e_lfanew); + if(!pnth) { + OutTraceB("HookDlls: ERROR no pnth at %d\n", __LINE__); + return; + } + rva = pnth->OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_IMPORT].VirtualAddress; + if(!rva) { + OutTraceB("HookDlls: ERROR no rva at %d\n", __LINE__); + return; + } + + for(pidesc = (PIMAGE_IMPORT_DESCRIPTOR)(base + rva); pidesc->FirstThunk; pidesc++){ + HMODULE DllBase; + int idx; + extern HMODULE SysLibs[]; + + impmodule = (PSTR)(base + pidesc->Name); + + // skip dxwnd and system dll + if(!lstrcmpi(impmodule, "DxWnd")) continue; + idx=dxw.GetDLLIndex(impmodule); + if(!lstrcmpi(impmodule,dxw.CustomOpenGLLib))idx=SYSLIBIDX_OPENGL; + if(idx != -1) { + DllBase=GetModuleHandle(impmodule); + SysLibs[idx]=DllBase; + OutTraceB("HookDlls: system module %s at %x\n", impmodule, DllBase); + continue; + } + + OutTraceB("HookDlls: ENTRY timestamp=%x module=%s forwarderchain=%x\n", + pidesc->TimeDateStamp, impmodule, pidesc->ForwarderChain); + if(pidesc->OriginalFirstThunk) { + ptname = (PIMAGE_THUNK_DATA)(base + (DWORD)pidesc->OriginalFirstThunk); + } + else{ + ptname = 0; + OutTraceB("HookDlls: no PE OFTs - stripped module=%s\n", impmodule); + } + + DllBase=GetModuleHandle(impmodule); + if(DllBase) HookModule(DllBase, 0); + } + } + __except(EXCEPTION_EXECUTE_HANDLER) + { + OutTraceD("HookDlls: EXCEPTION\n"); + } + return; +} + void DumpImportTable(HMODULE module) { PIMAGE_NT_HEADERS pnth; @@ -221,7 +286,12 @@ void SetHook(void *target, void *hookproc, void **hookedproc, char *hookname) dwTmp = *(DWORD *)target; if(dwTmp == (DWORD)hookproc) return; // already hooked if((dwTmp <= MaxHook) && (dwTmp >= MinHook)) return; // already hooked - if(!VirtualProtect(target, 4, PAGE_READWRITE, &oldprot)) return; // error condition + if(!VirtualProtect(target, 4, PAGE_READWRITE, &oldprot)) { + sprintf(msg,"SetHook ERROR: target=%x err=%d\n", target, GetLastError()); + OutTraceD(msg); + if (IsAssertEnabled) MessageBox(0, msg, "SetHook", MB_OK | MB_ICONEXCLAMATION); + return; // error condition + } *(DWORD *)target = (DWORD)hookproc; VirtualProtect(target, 4, oldprot, &oldprot); tmp=(void *)dwTmp; @@ -273,7 +343,7 @@ void *HookAPI(HMODULE module, char *dll, void *apiproc, const char *apiname, voi pidesc ++; } if(!pidesc->FirstThunk) { - if (IsDebug) OutTraceD("HookAPI: PE unreferenced dll=%s\n", dll); + OutTraceB("HookAPI: PE unreferenced dll=%s\n", dll); return 0; } @@ -386,7 +456,7 @@ void AdjustWindowFrame(HWND hwnd, DWORD width, DWORD height) HRESULT res=0; WNDPROC pWindowProc; - OutTraceD("AdjustWindowFrame hwnd=%x, wxh=%dx%d\n", hwnd, width, height); + OutTraceD("AdjustWindowFrame hwnd=%x, size=(%d,%d)\n", hwnd, width, height); dxw.SetScreenSize(width, height); if (hwnd==NULL) return; @@ -394,7 +464,7 @@ void AdjustWindowFrame(HWND hwnd, DWORD width, DWORD height) (*pSetWindowLong)(hwnd, GWL_STYLE, (dxw.dwFlags2 & MODALSTYLE) ? 0 : WS_OVERLAPPEDWINDOW); (*pSetWindowLong)(hwnd, GWL_EXSTYLE, 0); (*pShowWindow)(hwnd, SW_SHOWNORMAL); - OutTraceD("AdjustWindowFrame hwnd=%x, set style=WS_OVERLAPPEDWINDOW extstyle=0\n", hwnd); + OutTraceD("AdjustWindowFrame hwnd=%x, set style=%s extstyle=0\n", hwnd, (dxw.dwFlags2 & MODALSTYLE) ? "0" : "WS_OVERLAPPEDWINDOW"); AdjustWindowPos(hwnd, width, height); // fixing windows message handling procedure @@ -1111,39 +1181,7 @@ void HookSysLibs(HMODULE module) tmp = HookAPI(module, "user32.dll", MoveWindow, "MoveWindow", extMoveWindow); if(tmp) pMoveWindow = (MoveWindow_Type)tmp; - if(dxw.dwFlags2 & LIMITRESOURCES){ - tmp = HookAPI(module, "kernel32.dll", GetDiskFreeSpaceA, "GetDiskFreeSpaceA", extGetDiskFreeSpaceA); - if(tmp) pGetDiskFreeSpaceA = (GetDiskFreeSpaceA_Type)tmp; - tmp = HookAPI(module, "kernel32.dll", GlobalMemoryStatus, "GlobalMemoryStatus", extGlobalMemoryStatus); - if(tmp) pGlobalMemoryStatus = (GlobalMemoryStatus_Type)tmp; - } - - if(dxw.dwFlags2 & TIMESTRETCH){ - tmp = HookAPI(module, "kernel32.dll", GetTickCount, "GetTickCount", extGetTickCount); - if(tmp) pGetTickCount = (GetTickCount_Type)tmp; - tmp = HookAPI(module, "kernel32.dll", GetLocalTime, "GetLocalTime", extGetLocalTime); - if(tmp) pGetLocalTime = (GetLocalTime_Type)tmp; - tmp = HookAPI(module, "kernel32.dll", GetSystemTime, "GetSystemTime", extGetSystemTime); - if(tmp) pGetSystemTime = (GetSystemTime_Type)tmp; - tmp = HookAPI(module, "kernel32.dll", GetSystemTimeAsFileTime, "GetSystemTimeAsFileTime", extGetSystemTimeAsFileTime); - if(tmp) pGetSystemTimeAsFileTime = (GetSystemTimeAsFileTime_Type)tmp; - tmp = HookAPI(module, "kernel32.dll", Sleep, "Sleep", extSleep); - if(tmp) pSleep = (Sleep_Type)tmp; - tmp = HookAPI(module, "kernel32.dll", SleepEx, "SleepEx", extSleepEx); - if(tmp) pSleepEx = (SleepEx_Type)tmp; - tmp = HookAPI(module, "user32.dll", SetTimer, "SetTimer", extSetTimer); - if(tmp) pSetTimer = (SetTimer_Type)tmp; - tmp = HookAPI(module, "winmm.dll", NULL, "timeGetTime", exttimeGetTime); - if(tmp) ptimeGetTime = (timeGetTime_Type)tmp; - } - - if(dxw.dwFlags2 & FAKEVERSION){ - tmp = HookAPI(module, "kernel32.dll", GetVersion, "GetVersion", extGetVersion); - if(tmp) pGetVersion = (GetVersion_Type)tmp; - tmp = HookAPI(module, "kernel32.dll", GetVersionEx, "GetVersionEx", extGetVersionEx); - if(tmp) pGetVersionEx = (GetVersionEx_Type)tmp; - } - + HookKernel32(module); return; } @@ -1158,6 +1196,23 @@ static void RecoverScreenMode() if(res) OutTraceE("ChangeDisplaySettings: ERROR err=%d at %d\n", GetLastError(), __LINE__); } +static void LockScreenMode(DWORD dmPelsWidth, DWORD dmPelsHeight, DWORD dmBitsPerPel) +{ + DEVMODE InitDevMode; + BOOL res; + EnumDisplaySettings(NULL, ENUM_REGISTRY_SETTINGS, &InitDevMode); + OutTraceD("ChangeDisplaySettings: LOCK wxh=(%dx%d) BitsPerPel=%d -> wxh=(%dx%d) BitsPerPel=%d\n", + InitDevMode.dmPelsWidth, InitDevMode.dmPelsHeight, InitDevMode.dmBitsPerPel, + dmPelsWidth, dmPelsHeight, dmBitsPerPel); + if( (dmPelsWidth != InitDevMode.dmPelsWidth) || + (dmPelsHeight !=InitDevMode.dmPelsHeight) || + (dmBitsPerPel != InitDevMode.dmBitsPerPel)){ + res=(*pChangeDisplaySettings)(&InitDevMode, 0); + if(res) OutTraceE("ChangeDisplaySettings: ERROR err=%d at %d\n", GetLastError(), __LINE__); + } +} + + // to do: find a logic in the exception codes (0xc0000095 impies a bitmask ?) // idem for ExceptionFlags // generalize, find OPCODE length and set number of NOPs accordingly! @@ -1292,8 +1347,10 @@ int HookInit(TARGETMAP *target, HWND hwnd) dxw.hParentWnd=GetParent(hwnd); dxw.hChildWnd=hwnd; - OutTraceD("HookInit: path=\"%s\" module=\"%s\" dxversion=%s hWnd=%x dxw.hParentWnd=%x desktop=%x\n", - target->path, target->module, dxversions[dxw.dwTargetDDVersion], hwnd, dxw.hParentWnd, GetDesktopWindow()); + OutTraceD("HookInit: path=\"%s\" module=\"%s\" dxversion=%s pos=(%d,%d) size=(%d,%d) hWnd=%x dxw.hParentWnd=%x desktop=%x\n", + target->path, target->module, dxversions[dxw.dwTargetDDVersion], + target->posx, target->posy, target->sizx, target->sizy, + hwnd, dxw.hParentWnd, GetDesktopWindow()); if (IsDebug){ DWORD dwStyle, dwExStyle; dwStyle=GetWindowLong(dxw.GethWnd(), GWL_STYLE); @@ -1323,11 +1380,8 @@ int HookInit(TARGETMAP *target, HWND hwnd) OutTraceB("HookInit: base hmodule=%x\n", base); HookModule(base, dxw.dwTargetDDVersion); - // ListProcessModules needs to be fixed: it hangs the exe.... - //if(1){ - // extern BOOL ListProcessModules(BOOL); - // ListProcessModules(true); - //} + if (dxw.dwFlags3 & HOOKDLLS) HookDlls(base); + strncpy(sModuleBuf, dxw.gsModules, 60); sModule=strtok(sModuleBuf," ;"); while (sModule) { diff --git a/dll/dxhook.h b/dll/dxhook.h index ffbeb6b..e0f2ba9 100644 --- a/dll/dxhook.h +++ b/dll/dxhook.h @@ -4,7 +4,22 @@ extern int HookDirect3D(HMODULE, int); extern int HookOle32(HMODULE, int); extern int HookDirectInput(HMODULE, int); extern void HookImeLib(HMODULE); +extern void HookKernel32(HMODULE); + extern void InitPosition(int, int, int, int, int, int); //void InitWindowPos(int, int, int, int); extern LPCSTR ProcToString(LPCSTR proc); -extern HRESULT HookDxDiag(REFIID, LPVOID FAR*); \ No newline at end of file +extern HRESULT HookDxDiag(REFIID, LPVOID FAR*); + +extern FARPROC Remap_ddraw_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_d3d8_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_d3d9_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_d3d10_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_d3d10_1_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_d3d11_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_gl_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_smack_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_user32_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_kernel32_ProcAddress(LPCSTR, HMODULE); +extern FARPROC Remap_ole32_ProcAddress(LPCSTR, HMODULE); + diff --git a/dll/dxkernel32.cpp b/dll/dxkernel32.cpp new file mode 100644 index 0000000..1b516aa --- /dev/null +++ b/dll/dxkernel32.cpp @@ -0,0 +1,331 @@ +#include "dxwnd.h" +#include "dxwcore.hpp" +#include "syslibs.h" +#include "dxhook.h" + +void HookKernel32(HMODULE module) +{ + void *tmp; + + if(dxw.dwFlags2 & LIMITRESOURCES){ + tmp = HookAPI(module, "kernel32.dll", GetDiskFreeSpaceA, "GetDiskFreeSpaceA", extGetDiskFreeSpaceA); + if(tmp) pGetDiskFreeSpaceA = (GetDiskFreeSpaceA_Type)tmp; + tmp = HookAPI(module, "kernel32.dll", GlobalMemoryStatus, "GlobalMemoryStatus", extGlobalMemoryStatus); + if(tmp) pGlobalMemoryStatus = (GlobalMemoryStatus_Type)tmp; + } + + if(dxw.dwFlags2 & TIMESTRETCH){ + tmp = HookAPI(module, "kernel32.dll", GetTickCount, "GetTickCount", extGetTickCount); + if(tmp) pGetTickCount = (GetTickCount_Type)tmp; + tmp = HookAPI(module, "kernel32.dll", GetLocalTime, "GetLocalTime", extGetLocalTime); + if(tmp) pGetLocalTime = (GetLocalTime_Type)tmp; + tmp = HookAPI(module, "kernel32.dll", GetSystemTime, "GetSystemTime", extGetSystemTime); + if(tmp) pGetSystemTime = (GetSystemTime_Type)tmp; + tmp = HookAPI(module, "kernel32.dll", GetSystemTimeAsFileTime, "GetSystemTimeAsFileTime", extGetSystemTimeAsFileTime); + if(tmp) pGetSystemTimeAsFileTime = (GetSystemTimeAsFileTime_Type)tmp; + tmp = HookAPI(module, "kernel32.dll", Sleep, "Sleep", extSleep); + if(tmp) pSleep = (Sleep_Type)tmp; + tmp = HookAPI(module, "kernel32.dll", SleepEx, "SleepEx", extSleepEx); + if(tmp) pSleepEx = (SleepEx_Type)tmp; + tmp = HookAPI(module, "user32.dll", SetTimer, "SetTimer", extSetTimer); + if(tmp) pSetTimer = (SetTimer_Type)tmp; + tmp = HookAPI(module, "winmm.dll", NULL, "timeGetTime", exttimeGetTime); + if(tmp) ptimeGetTime = (timeGetTime_Type)tmp; + } + + if(dxw.dwFlags2 & FAKEVERSION){ + tmp = HookAPI(module, "kernel32.dll", GetVersion, "GetVersion", extGetVersion); + if(tmp) pGetVersion = (GetVersion_Type)tmp; + tmp = HookAPI(module, "kernel32.dll", GetVersionEx, "GetVersionEx", extGetVersionEx); + if(tmp) pGetVersionEx = (GetVersionEx_Type)tmp; + } +} + +FARPROC Remap_kernel32_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + if (!strcmp(proc,"IsDebuggerPresent")){ + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extIsDebuggerPresent); + return (FARPROC)extIsDebuggerPresent; + } + if(dxw.dwFlags2 & LIMITRESOURCES){ + if (!strcmp(proc,"GetDiskFreeSpaceA")){ + pGetDiskFreeSpaceA=(GetDiskFreeSpaceA_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extGetDiskFreeSpaceA); + return (FARPROC)extGetDiskFreeSpaceA; + } + if (!strcmp(proc,"GlobalMemoryStatus")){ + pGlobalMemoryStatus=(GlobalMemoryStatus_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extGlobalMemoryStatus); + return (FARPROC)extGlobalMemoryStatus; + } + } + if(dxw.dwFlags2 & TIMESTRETCH){ + if (!strcmp(proc,"GetTickCount")){ + pGetTickCount=(GetTickCount_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extGetTickCount); + return (FARPROC)extGetTickCount; + } + if (!strcmp(proc,"GetLocalTime")){ + pGetLocalTime=(GetLocalTime_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extGetLocalTime); + return (FARPROC)extGetLocalTime; + } + if (!strcmp(proc,"GetSystemTime")){ + pGetSystemTime=(GetSystemTime_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extGetSystemTime); + return (FARPROC)extGetSystemTime; + } + if (!strcmp(proc,"GetSystemTimeAsFileTime")){ + pGetSystemTimeAsFileTime=(GetSystemTimeAsFileTime_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extGetSystemTimeAsFileTime); + return (FARPROC)extGetSystemTimeAsFileTime; + } + if (!strcmp(proc,"Sleep")){ + pSleep=(Sleep_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extSleep); + return (FARPROC)extSleep; + } + if (!strcmp(proc,"SleepEx")){ + pSleepEx=(SleepEx_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extSleepEx); + return (FARPROC)extSleepEx; + } + if (!strcmp(proc,"SetTimer")){ + pSetTimer=(SetTimer_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extSetTimer); + return (FARPROC)extSetTimer; + } + } + if(dxw.dwFlags2 & FAKEVERSION){ + if (!strcmp(proc,"GetVersion")){ + pGetVersion=(GetVersion_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extGetVersion); + return (FARPROC)extGetVersion; + } + if (!strcmp(proc,"GetVersionEx")){ + pGetVersionEx=(GetVersionEx_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extGetVersionEx); + return (FARPROC)extGetVersionEx; + } + } + return NULL; +} + + +int WINAPI extIsDebuggerPresent(void) +{ + OutTraceD("extIsDebuggerPresent: return FALSE\n"); + return FALSE; +} + +BOOL WINAPI extGetDiskFreeSpaceA(LPCSTR lpRootPathName, LPDWORD lpSectorsPerCluster, LPDWORD lpBytesPerSector, LPDWORD lpNumberOfFreeClusters, LPDWORD lpTotalNumberOfClusters) +{ + BOOL ret; + OutTraceD("GetDiskFreeSpace: RootPathName=\"%s\"\n", lpRootPathName); + ret=(*pGetDiskFreeSpaceA)(lpRootPathName, lpSectorsPerCluster, lpBytesPerSector, lpNumberOfFreeClusters, lpTotalNumberOfClusters); + if(!ret) OutTraceE("GetDiskFreeSpace: ERROR err=%d at %d\n", GetLastError(), __LINE__); + *lpNumberOfFreeClusters = 16000; + return ret; +} + +/* ------------------------------------------------------------------------------- + +GlobalMemoryStatus: MSDN documents that on modern PCs that have more than DWORD +memory values the GlobalMemoryStatus sets the fields to -1 (0xFFFFFFFF) and you +should use GlobalMemoryStatusEx instead. +But in some cases the value is less that DWORD max, but greater that DWORD>>1, that +is the calling application may get a big value and see it as a signed negative +value, as it happened to Nocturne on my PC. That's why it's not adviseable to write: +if(lpBuffer->dwTotalPhys== -1) ... +but this way: +if ((int)lpBuffer->dwTotalPhys < 0) ... +and also don't set +BIGENOUGH 0x80000000 // possibly negative!!! +but: +BIGENOUGH 0x20000000 // surely positive !!! + +/* ---------------------------------------------------------------------------- */ +#define BIGENOUGH 0x20000000 + +void WINAPI extGlobalMemoryStatus(LPMEMORYSTATUS lpBuffer) +{ + (*pGlobalMemoryStatus)(lpBuffer); + OutTraceD("GlobalMemoryStatus: Length=%x MemoryLoad=%x " + "TotalPhys=%x AvailPhys=%x TotalPageFile=%x AvailPageFile=%x TotalVirtual=%x AvailVirtual=%x\n", + lpBuffer->dwMemoryLoad, lpBuffer->dwTotalPhys, lpBuffer->dwAvailPhys, + lpBuffer->dwTotalPageFile, lpBuffer->dwAvailPageFile, lpBuffer->dwTotalVirtual, lpBuffer->dwAvailVirtual); + if(lpBuffer->dwLength==sizeof(MEMORYSTATUS)){ + if ((int)lpBuffer->dwTotalPhys < 0) lpBuffer->dwTotalPhys = BIGENOUGH; + if ((int)lpBuffer->dwAvailPhys < 0) lpBuffer->dwAvailPhys = BIGENOUGH; + if ((int)lpBuffer->dwTotalPageFile < 0) lpBuffer->dwTotalPageFile = BIGENOUGH; + if ((int)lpBuffer->dwAvailPageFile < 0) lpBuffer->dwAvailPageFile = BIGENOUGH; + if ((int)lpBuffer->dwTotalVirtual < 0) lpBuffer->dwTotalVirtual = BIGENOUGH; + if ((int)lpBuffer->dwAvailVirtual < 0) lpBuffer->dwAvailVirtual = BIGENOUGH; + } +} + +/* +From MSDN: +Operating system Version number dwMajorVersion dwMinorVersion Other +Windows 8 6.2 6 2 OSVERSIONINFOEX.wProductType == VER_NT_WORKSTATION +Windows Server 2012 6.2 6 2 OSVERSIONINFOEX.wProductType != VER_NT_WORKSTATION +Windows 7 6.1 6 1 OSVERSIONINFOEX.wProductType == VER_NT_WORKSTATION +Windows Server 2008 R2 6.1 6 1 OSVERSIONINFOEX.wProductType != VER_NT_WORKSTATION +Windows Server 2008 6.0 6 0 OSVERSIONINFOEX.wProductType != VER_NT_WORKSTATION +Windows Vista 6.0 6 0 OSVERSIONINFOEX.wProductType == VER_NT_WORKSTATION +Windows Server 2003 R2 5.2 5 2 GetSystemMetrics(SM_SERVERR2) != 0 +Windows Home Server 5.2 5 2 OSVERSIONINFOEX.wSuiteMask & VER_SUITE_WH_SERVER +Windows Server 2003 5.2 5 2 GetSystemMetrics(SM_SERVERR2) == 0 +Windows XP Pro x64 Ed. 5.2 5 2 (OSVERSIONINFOEX.wProductType == VER_NT_WORKSTATION) && (SYSTEM_INFO.wProcessorArchitecture==PROCESSOR_ARCHITECTURE_AMD64) +Windows XP 5.1 5 1 Not applicable +Windows 2000 5.0 5 0 Not applicable +From http://delphi.about.com/cs/adptips2000/a/bltip1100_2.htm +Windows 95 4.0 4 0 +Windows 98/SE" 4.10 4 10 if osVerInfo.szCSDVersion[1] = 'A' then Windows98SE +Windows ME 4.90 4 90 +*/ + +static struct {char bMajor; char bMinor; char *sName;} WinVersions[9]= +{ + {4, 0, "Windows 95"}, + {4,10, "Windows 98/SE"}, + {4,90, "Windows ME"}, + {5, 0, "Windows 2000"}, + {5, 1, "Windows XP"}, + {5, 2, "Windows Server 2003"}, + {6, 0, "Windows Vista"}, + {6, 1, "Windows 7"}, + {6, 2, "Windows 8"} +}; + +BOOL WINAPI extGetVersionEx(LPOSVERSIONINFO lpVersionInfo) +{ + BOOL ret; + + ret=(*pGetVersionEx)(lpVersionInfo); + if(!ret) { + OutTraceE("GetVersionEx: ERROR err=%d\n", GetLastError()); + return ret; + } + + OutTraceD("GetVersionEx: version=%d.%d build=(%d)\n", + lpVersionInfo->dwMajorVersion, lpVersionInfo->dwMinorVersion, lpVersionInfo->dwBuildNumber); + + if(dxw.dwFlags2 & FAKEVERSION) { + // fake Win XP build 0 + lpVersionInfo->dwMajorVersion = WinVersions[dxw.FakeVersionId].bMajor; + lpVersionInfo->dwMinorVersion = WinVersions[dxw.FakeVersionId].bMinor; + lpVersionInfo->dwBuildNumber = 0; + OutTraceD("GetVersionEx: FIXED version=%d.%d build=(%d) os=\"%s\"\n", + lpVersionInfo->dwMajorVersion, lpVersionInfo->dwMinorVersion, lpVersionInfo->dwBuildNumber, + WinVersions[dxw.FakeVersionId].sName); + } + return TRUE; +} + +DWORD WINAPI extGetVersion(void) +{ + DWORD dwVersion; + DWORD dwMajorVersion; + DWORD dwMinorVersion; + DWORD dwBuild = 0; + + dwVersion = (*pGetVersion)(); + + // Get the Windows version. + + dwMajorVersion = (DWORD)(LOBYTE(LOWORD(dwVersion))); + dwMinorVersion = (DWORD)(HIBYTE(LOWORD(dwVersion))); + + // Get the build number. + + if (dwVersion < 0x80000000) + dwBuild = (DWORD)(HIWORD(dwVersion)); + + OutTraceD("GetVersion: version=%d.%d build=(%d)\n", dwMajorVersion, dwMinorVersion, dwBuild); + + if(dxw.dwFlags2 & FAKEVERSION) { + dwVersion = WinVersions[dxw.FakeVersionId].bMajor | (WinVersions[dxw.FakeVersionId].bMinor << 8); + dwMajorVersion = (DWORD)(LOBYTE(LOWORD(dwVersion))); + dwMinorVersion = (DWORD)(HIBYTE(LOWORD(dwVersion))); + dwBuild = (DWORD)(HIWORD(dwVersion)); + OutTraceD("GetVersion: FIXED version=%d.%d build=(%d) os=\"%s\"\n", + dwMajorVersion, dwMinorVersion, dwBuild, WinVersions[dxw.FakeVersionId].sName); + } + + return dwVersion; +} + +/* ------------------------------------------------------------------------------- + +time related APIs + +/* ---------------------------------------------------------------------------- */ + +DWORD WINAPI extGetTickCount(void) +{ + return dxw.GetTickCount(); +} + +void WINAPI extGetSystemTime(LPSYSTEMTIME lpSystemTime) +{ + dxw.GetSystemTime(lpSystemTime); + if (IsDebug) OutTrace("GetSystemTime: %02d:%02d:%02d.%03d\n", + lpSystemTime->wHour, lpSystemTime->wMinute, lpSystemTime->wSecond, lpSystemTime->wMilliseconds); +} + +void WINAPI extGetLocalTime(LPSYSTEMTIME lpLocalTime) +{ + SYSTEMTIME SystemTime; + dxw.GetSystemTime(&SystemTime); + SystemTimeToTzSpecificLocalTime(NULL, &SystemTime, lpLocalTime); + if (IsDebug) OutTrace("GetLocalTime: %02d:%02d:%02d.%03d\n", + lpLocalTime->wHour, lpLocalTime->wMinute, lpLocalTime->wSecond, lpLocalTime->wMilliseconds); +} + +UINT_PTR WINAPI extSetTimer(HWND hWnd, UINT_PTR nIDEvent, UINT uElapse, TIMERPROC lpTimerFunc) +{ + UINT uShiftedElapse; + // beware: the quicker the time flows, the more the time clicks are incremented, + // and the lesser the pauses must be lasting! Shift operations are reverted in + // GetSystemTime vs. Sleep or SetTimer + uShiftedElapse = dxw.StretchTime(uElapse); + if (IsDebug) OutTrace("SetTimer: elapse=%d->%d timeshift=%d\n", uElapse, uShiftedElapse, dxw.TimeShift); + return (*pSetTimer)(hWnd, nIDEvent, uShiftedElapse, lpTimerFunc); +} + +VOID WINAPI extSleep(DWORD dwMilliseconds) +{ + DWORD dwNewDelay; + dwNewDelay=dwMilliseconds; + if (dwMilliseconds!=INFINITE && dwMilliseconds!=0){ + dwNewDelay = dxw.StretchTime(dwMilliseconds); + if (dwNewDelay==0){ // oh oh! troubles... + if (dxw.TimeShift > 0) dwNewDelay=1; // minimum allowed... + else dwNewDelay = INFINITE-1; // maximum allowed !!! + } + } + if (IsDebug) OutTrace("Sleep: msec=%d->%d timeshift=%d\n", dwMilliseconds, dwNewDelay, dxw.TimeShift); + (*pSleep)(dwNewDelay); +} + +DWORD WINAPI extSleepEx(DWORD dwMilliseconds, BOOL bAlertable) +{ + DWORD dwNewDelay; + dwNewDelay=dwMilliseconds; + if (dwMilliseconds!=INFINITE && dwMilliseconds!=0){ + dwNewDelay = dxw.StretchTime(dwMilliseconds); + if (dwNewDelay==0){ // oh oh! troubles... + if (dxw.TimeShift > 0) dwNewDelay=1; // minimum allowed... + else dwNewDelay = INFINITE-1; // maximum allowed !!! + } + } + if (IsDebug) OutTrace("SleepEx: msec=%d->%d alertable=%x, timeshift=%d\n", dwMilliseconds, dwNewDelay, bAlertable, dxw.TimeShift); + return (*pSleepEx)(dwNewDelay, bAlertable); +} + +void WINAPI extGetSystemTimeAsFileTime(LPFILETIME lpSystemTimeAsFileTime) +{ + if (IsDebug) OutTrace("GetSystemTimeAsFileTime\n"); + dxw.GetSystemTimeAsFileTime(lpSystemTimeAsFileTime); +} \ No newline at end of file diff --git a/dll/dxole32.cpp b/dll/dxole32.cpp new file mode 100644 index 0000000..6778c96 --- /dev/null +++ b/dll/dxole32.cpp @@ -0,0 +1,100 @@ +#include +#include "dxwnd.h" +#include "dxwcore.hpp" +#include "syslibs.h" +#include "dxhook.h" +#include "dxhelper.h" + +extern HRESULT WINAPI extDirectDrawCreate(GUID FAR *, LPDIRECTDRAW FAR *, IUnknown FAR *); +extern HRESULT WINAPI extDirectDrawCreateEx(GUID FAR *, LPDIRECTDRAW FAR *, REFIID, IUnknown FAR *); + +FARPROC Remap_ole32_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + if (!strcmp(proc,"CoCreateInstance")){ + pCoCreateInstance=(CoCreateInstance_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pCoCreateInstance); + return (FARPROC)extCoCreateInstance; + } + return NULL; +} + +// ------------------------------------------------------------------------------------- +// Ole32 CoCreateInstance handling: you can create DirectDraw objects through it! +// utilized so far in a single game: Axiz & Allies +// ------------------------------------------------------------------------------------- + +static void HookDDSession(LPDIRECTDRAW *, int); +//CoCreateInstance_Type pCoCreateInstance=NULL; + +HRESULT STDAPICALLTYPE extCoCreateInstance(REFCLSID rclsid, LPUNKNOWN pUnkOuter, DWORD dwClsContext, REFIID riid, LPVOID FAR* ppv) +{ + HRESULT res; + OutTraceD("CoCreateInstance: rclsid=%x UnkOuter=%x ClsContext=%x refiid=%x\n", + rclsid, pUnkOuter, dwClsContext, riid); + + // CLSID e436ebb3 implies loading quartz.dll to play movies through dshow: + // quartz.dll must be hooked. + if (*(DWORD *)&rclsid==0xe436ebb3){ + HMODULE qlib; + OutTraceD("CoCreateInstance: CLSID_FilterGraph RIID=%x\n", *(DWORD *)&riid); + qlib=(*pLoadLibraryA)("quartz.dll"); + OutTraceD("CoCreateInstance: quartz lib handle=%x\n", qlib); + extern void HookSysLibs(HMODULE); + HookSysLibs(qlib); + } + + res=(*pCoCreateInstance)(rclsid, pUnkOuter, dwClsContext, riid, ppv); + if(res) + OutTraceE("CoCreateInstance: ERROR res=%x\n", res); + else + OutTraceD("CoCreateInstance: ppv=%x->%x\n", *ppv, *(DWORD *)*ppv); + + if (*(DWORD *)&rclsid==*(DWORD *)&CLSID_DirectDraw){ + LPDIRECTDRAW lpOldDDraw; + OutTraceD("CoCreateInstance: CLSID_DirectDraw object\n"); + switch (*(DWORD *)&riid){ + case 0x6C14DB80: + OutTraceD("DirectDrawCreate: IID_DirectDraw RIID\n"); + res=extDirectDrawCreate(NULL, (LPDIRECTDRAW *)&ppv, 0); + if(res)OutTraceD("DirectDrawCreate: res=%x(%s)\n", res, ExplainDDError(res)); + break; + case 0xB3A6F3E0: + OutTraceD("DirectDrawCreate: IID_DirectDraw2 RIID\n"); + res=extDirectDrawCreate(NULL, &lpOldDDraw, 0); + if(res)OutTraceD("DirectDrawCreate: res=%x(%s)\n", res, ExplainDDError(res)); + res=lpOldDDraw->QueryInterface(IID_IDirectDraw2, (LPVOID *)&ppv); + if(res)OutTraceD("QueryInterface: res=%x(%s)\n", res, ExplainDDError(res)); + lpOldDDraw->Release(); + break; + case 0x9c59509a: + OutTraceD("DirectDrawCreate: IID_DirectDraw4 RIID\n"); + res=extDirectDrawCreate(NULL, &lpOldDDraw, 0); + if(res)OutTraceD("DirectDrawCreate: res=%x(%s)\n", res, ExplainDDError(res)); + res=lpOldDDraw->QueryInterface(IID_IDirectDraw4, (LPVOID *)&ppv); + if(res)OutTraceD("QueryInterface: res=%x(%s)\n", res, ExplainDDError(res)); + lpOldDDraw->Release(); + case 0x15e65ec0: + OutTraceD("CoCreateInstance: IID_DirectDraw7 RIID\n"); + res=extDirectDrawCreateEx(NULL, (LPDIRECTDRAW *)&ppv, IID_IDirectDraw7, 0); + if(res)OutTraceD("DirectDrawCreateEx: res=%x(%s)\n", res, ExplainDDError(res)); + break; + case 0xe436ebb3: + break; + } + } + else + if (*(DWORD *)&rclsid==*(DWORD *)&CLSID_DxDiagProvider) res=HookDxDiag(riid, ppv); + + return res; +} + +int HookOle32(HMODULE module, int version) +{ + // used by Axis & Allies .... + void *tmp; + //return 0; + OutTraceD("HookOle32 version=%d\n", version); //GHO + tmp = HookAPI(module, "ole32.dll", NULL, "CoCreateInstance", extCoCreateInstance); + if(tmp) pCoCreateInstance = (CoCreateInstance_Type)tmp; + return 0; +} diff --git a/dll/dxuser32.cpp b/dll/dxuser32.cpp new file mode 100644 index 0000000..fa1e24a --- /dev/null +++ b/dll/dxuser32.cpp @@ -0,0 +1,140 @@ +#include "dxwnd.h" +#include "dxwcore.hpp" +#include "syslibs.h" +#include "dxhook.h" + +FARPROC Remap_user32_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + if (!strcmp(proc,"ChangeDisplaySettingsA")){ + pChangeDisplaySettings=(ChangeDisplaySettings_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pChangeDisplaySettings); + return (FARPROC)extChangeDisplaySettings; + } + if (!strcmp(proc,"ChangeDisplaySettingsExA")){ + pChangeDisplaySettingsEx=(ChangeDisplaySettingsEx_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pChangeDisplaySettingsEx); + return (FARPROC)extChangeDisplaySettingsEx; + } + if (!strcmp(proc,"BeginPaint")){ + pBeginPaint=(BeginPaint_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pBeginPaint); + return (FARPROC)extBeginPaint; + } + if (!strcmp(proc,"EndPaint")){ + pEndPaint=(EndPaint_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pEndPaint); + return (FARPROC)extEndPaint; + } + if (!strcmp(proc,"ShowCursor")){ + pShowCursor=(ShowCursor_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pShowCursor); + return (FARPROC)extShowCursor; + } + /* + if(dxw.dwFlags1 & MAPGDITOPRIMARY){ + tmp = HookAPI(module, "user32.dll", GetDC, "GetDC", extDDGetDC); + if(tmp) pGDIGetDC = (GDIGetDC_Type)tmp; + tmp = HookAPI(module, "user32.dll", GetWindowDC, "GetWindowDC", extDDGetWindowDC); + if(tmp) pGDIGetWindowDC = (GDIGetDC_Type)tmp; + tmp = HookAPI(module, "user32.dll", ReleaseDC, "ReleaseDC", extDDReleaseDC); + if(tmp) pGDIReleaseDC = (GDIReleaseDC_Type)tmp; + tmp = HookAPI(module, "user32.dll", InvalidateRect, "InvalidateRect", extDDInvalidateRect); + if(tmp) pInvalidateRect = (InvalidateRect_Type)tmp; + } + else{ + tmp = HookAPI(module, "user32.dll", GetDC, "GetDC", extGDIGetDC); + if(tmp) pGDIGetDC = (GDIGetDC_Type)tmp; + tmp = HookAPI(module, "user32.dll", GetWindowDC, "GetWindowDC", extGDIGetWindowDC); + if(tmp) pGDIGetWindowDC = (GDIGetDC_Type)tmp; + tmp = HookAPI(module, "user32.dll", ReleaseDC, "ReleaseDC", extGDIReleaseDC); + if(tmp) pGDIReleaseDC = (GDIReleaseDC_Type)tmp; + tmp = HookAPI(module, "user32.dll", InvalidateRect, "InvalidateRect", extInvalidateRect); + if(tmp) pInvalidateRect = (InvalidateRect_Type)tmp; + } + + if (dxw.dwFlags1 & CLIENTREMAPPING){ + tmp = HookAPI(module, "user32.dll", ScreenToClient, "ScreenToClient", extScreenToClient); + if(tmp) pScreenToClient = (ScreenToClient_Type)tmp; + tmp = HookAPI(module, "user32.dll", ClientToScreen, "ClientToScreen", extClientToScreen); + if(tmp) pClientToScreen = (ClientToScreen_Type)tmp; + tmp = HookAPI(module, "user32.dll", GetClientRect, "GetClientRect", extGetClientRect); + if(tmp) pGetClientRect = (GetClientRect_Type)tmp; + tmp = HookAPI(module, "user32.dll", GetWindowRect, "GetWindowRect", extGetWindowRect); + if(tmp) pGetWindowRect = (GetWindowRect_Type)tmp; + tmp = HookAPI(module, "user32.dll", MapWindowPoints, "MapWindowPoints", extMapWindowPoints); + if(tmp) pMapWindowPoints = (MapWindowPoints_Type)tmp; + } + + // get / change display settings + tmp = HookAPI(module, "user32.dll", ChangeDisplaySettingsA, "ChangeDisplaySettingsA", extChangeDisplaySettings); + if(tmp) pChangeDisplaySettings = (ChangeDisplaySettings_Type)tmp; + tmp = HookAPI(module, "user32.dll", ChangeDisplaySettingsExA, "ChangeDisplaySettingsExA", extChangeDisplaySettingsEx); + if(tmp) pChangeDisplaySettingsEx = (ChangeDisplaySettingsEx_Type)tmp; + tmp = HookAPI(module, "user32.dll", EnumDisplaySettingsA, "EnumDisplaySettingsA", extEnumDisplaySettings); + if(tmp) pEnumDisplaySettings = (EnumDisplaySettings_Type)tmp; + + // handle cursor clipping + tmp = HookAPI(module, "user32.dll", GetClipCursor, "GetClipCursor", extGetClipCursor); + if(tmp) pGetClipCursor = (GetClipCursor_Type)tmp; + + tmp = HookAPI(module, "user32.dll", ClipCursor, "ClipCursor", extClipCursor); + if(tmp) pClipCursor = (ClipCursor_Type)tmp; + tmp = HookAPI(module, "user32.dll", FillRect, "FillRect", extFillRect); + if(tmp) pFillRect = (FillRect_Type)tmp; + if (dxw.dwFlags1 & MESSAGEPROC) { + tmp = HookAPI(module, "user32.dll", PeekMessageA, "PeekMessageA", extPeekMessage); // added for GPL + if(tmp) pPeekMessage = (PeekMessage_Type)tmp; + tmp = HookAPI(module, "user32.dll", GetMessageA, "GetMessageA", extGetMessage); // added for GPL + if(tmp) pGetMessage = (GetMessage_Type)tmp; + } + tmp = HookAPI(module, "user32.dll", DefWindowProcA, "DefWindowProcA", extDefWindowProc); // added for WarWind background erase + if(tmp) pDefWindowProc = (DefWindowProc_Type)tmp; + tmp = HookAPI(module, "user32.dll", CreateWindowExA, "CreateWindowExA", extCreateWindowExA); + if(tmp) pCreateWindowExA = (CreateWindowExA_Type)tmp; + tmp = HookAPI(module, "user32.dll", RegisterClassExA, "RegisterClassExA", extRegisterClassExA); + if(tmp) pRegisterClassExA = (RegisterClassExA_Type)tmp; + if (dxw.dwFlags1 & (PREVENTMAXIMIZE|FIXWINFRAME|LOCKWINPOS|LOCKWINSTYLE)){ + tmp = HookAPI(module, "user32.dll", ShowWindow, "ShowWindow", extShowWindow); + if(tmp) pShowWindow = (ShowWindow_Type)tmp; + tmp = HookAPI(module, "user32.dll", SetWindowLongA, "SetWindowLongA", extSetWindowLong); + if(tmp) pSetWindowLong = (SetWindowLong_Type)tmp; + tmp = HookAPI(module, "user32.dll", GetWindowLongA, "GetWindowLongA", extGetWindowLong); + if(tmp) pGetWindowLong = (GetWindowLong_Type)tmp; + tmp = HookAPI(module, "user32.dll", SetWindowPos, "SetWindowPos", extSetWindowPos); + if(tmp) pSetWindowPos = (SetWindowPos_Type)tmp; + tmp = HookAPI(module, "user32.dll", DeferWindowPos, "DeferWindowPos", extDeferWindowPos); + if(tmp) pGDIDeferWindowPos = (DeferWindowPos_Type)tmp; + tmp = HookAPI(module, "user32.dll", CallWindowProcA, "CallWindowProcA", extCallWindowProc); + if(tmp) pCallWindowProc = (CallWindowProc_Type)tmp; + } + tmp = HookAPI(module, "user32.dll", GetSystemMetrics, "GetSystemMetrics", extGetSystemMetrics); + if(tmp) pGetSystemMetrics = (GetSystemMetrics_Type)tmp; + + tmp = HookAPI(module, "user32.dll", GetDesktopWindow, "GetDesktopWindow", extGetDesktopWindow); + if(tmp) pGetDesktopWindow = (GetDesktopWindow_Type)tmp; + + if(dxw.dwFlags1 & MODIFYMOUSE){ + tmp = HookAPI(module, "user32.dll", GetCursorPos, "GetCursorPos", extGetCursorPos); + if(tmp) pGetCursorPos = (GetCursorPos_Type)tmp; + //tmp = HookAPI(module, "user32.dll", GetPhysicalCursorPos, "", extGetCursorPos); + tmp = HookAPI(module, "user32.dll", SetCursor, "SetCursor", extSetCursor); + if(tmp) pSetCursor = (SetCursor_Type)tmp; + //tmp = HookAPI(module, "user32.dll", SetPhysicalCursorPos, "", extSetCursorPos); + tmp = HookAPI(module, "user32.dll", SendMessageA, "SendMessageA", extSendMessage); + if(tmp) pSendMessage = (SendMessage_Type)tmp; + } + + if((dxw.dwFlags1 & (MODIFYMOUSE|SLOWDOWN|KEEPCURSORWITHIN)) || (dxw.dwFlags2 & KEEPCURSORFIXED)){ + tmp = HookAPI(module, "user32.dll", SetCursorPos, "SetCursorPos", extSetCursorPos); + if(tmp) pSetCursorPos = (SetCursorPos_Type)tmp; + } + + tmp = HookAPI(module, "user32.dll", CreateDialogIndirectParamA, "CreateDialogIndirectParamA", extCreateDialogIndirectParam); + if(tmp) pCreateDialogIndirectParam = (CreateDialogIndirectParam_Type)tmp; + tmp = HookAPI(module, "user32.dll", CreateDialogParamA, "CreateDialogParamA", extCreateDialogParam); + if(tmp) pCreateDialogParam = (CreateDialogParam_Type)tmp; + tmp = HookAPI(module, "user32.dll", MoveWindow, "MoveWindow", extMoveWindow); + if(tmp) pMoveWindow = (MoveWindow_Type)tmp; + */ + return NULL; +} diff --git a/dll/dxwcore.cpp b/dll/dxwcore.cpp index d71c6b9..47bf6e7 100644 --- a/dll/dxwcore.cpp +++ b/dll/dxwcore.cpp @@ -657,6 +657,11 @@ void dxwCore::GetSystemTime(LPSYSTEMTIME lpSystemTime) } } +void dxwCore::ShowFPS() +{ + this->ShowFPS(GetDC(hWnd)); +} + void dxwCore::ShowFPS(HDC xdc) { char sBuf[81]; @@ -741,13 +746,14 @@ void dxwCore::ShowBanner(HWND hwnd) HBITMAP g_hbmBall; RECT client; - if(JustOnce || (dwFlags2 & NOBANNER)) return; JustOnce=TRUE; hClientDC=GetDC(hwnd); (*pGetClientRect)(hwnd, &client); - //BitBlt(hClientDC, 0, 0, wp.cx, wp.cy, NULL, 0, 0, BLACKNESS); BitBlt(hClientDC, 0, 0, client.right, client.bottom, NULL, 0, 0, BLACKNESS); + + if(JustOnce || (dwFlags2 & NOBANNER)) return; + g_hbmBall = LoadBitmap(hInst, MAKEINTRESOURCE(IDB_BANNER)); HDC hdcMem = CreateCompatibleDC(hClientDC); HBITMAP hbmOld = (HBITMAP)SelectObject(hdcMem, g_hbmBall); @@ -770,4 +776,57 @@ void dxwCore::ShowBanner(HWND hwnd) SelectObject(hdcMem, hbmOld); DeleteDC(hdcMem); Sleep(200); +} + +int dxwCore::GetDLLIndex(char *lpFileName) +{ + int idx; + char *lpName, *lpNext; + char *SysNames[]={ + "kernel32", + "USER32", + "GDI32", + "ADVAPI32", + "ole32", + "ddraw", + "d3d8", + "d3d9", + "d3d10", + "d3d10_1", + "d3d11", + "opengl32", + "msvfw32", + "smackw32", + "version", + "dplayx", + "dsound", + "winmm", + "imm32", + "wsock32", + "dinput", + "dinput8", + "shfolder", + "shell32", + "ws2_32", + "tapi32", + "netapi32", + NULL + }; + + lpName=lpFileName; + while (lpNext=strchr(lpName,'\\')) lpName=lpNext+1; + for(idx=0; SysNames[idx]; idx++){ + char SysNameExt[81]; + strcpy(SysNameExt, SysNames[idx]); + strcat(SysNameExt, ".dll"); + if( + (!lstrcmpi(lpName,SysNames[idx])) || + (!lstrcmpi(lpName,SysNameExt)) + ){ + OutTraceB("Registered DLL FileName=%s\n", lpFileName); + break; + } + } + if (!SysNames[idx]) return -1; + return idx; } \ No newline at end of file diff --git a/dll/dxwcore.hpp b/dll/dxwcore.hpp index 66da8bf..0c59672 100644 --- a/dll/dxwcore.hpp +++ b/dll/dxwcore.hpp @@ -55,12 +55,14 @@ public: // methods void GetSystemTimeAsFileTime(LPFILETIME lpSystemTimeAsFileTime); DWORD StretchTime(DWORD); void ShowFPS(LPDIRECTDRAWSURFACE); + void ShowFPS(void); void ShowFPS(HDC); char *GetTSCaption(int); char *GetTSCaption(void); void DoSlow(int); void ShowBanner(HWND); POINT ScreenToClient(POINT); + int GetDLLIndex(char *); public: // simple data variables DDPIXELFORMAT ActualPixelFormat; @@ -105,3 +107,32 @@ protected: }; extern dxwCore dxw; + +typedef enum { + SYSLIBIDX_KERNEL32 = 0, + SYSLIBIDX_USER32, + SYSLIBIDX_GDI32, + SYSLIBIDX_ADVAPI32, + SYSLIBIDX_OLE32, + SYSLIBIDX_DIRECTDRAW, + SYSLIBIDX_DIRECT3D8, + SYSLIBIDX_DIRECT3D9, + SYSLIBIDX_DIRECT3D10, + SYSLIBIDX_DIRECT3D10_1, + SYSLIBIDX_DIRECT2D11, + SYSLIBIDX_OPENGL, + SYSLIBIDX_MSVFW, + SYSLIBIDX_SMACK, + SYSLIBIDX_VERSION, + SYSLIBIDX_DPLAYX, + SYSLIBIDX_DSOUND, + SYSLIBIDX_WINMM, + SYSLIBIDX_WSOCK, + SYSLIBIDX_DINPUT, + SYSLIBIDX_DINPUT8, + SYSLIBIDX_SHFOLDER, + SYSLIBIDX_SHELL32, + SYSLIBIDX_WS2_32, + SYSLIBIDX_TAPI32, + SYSLIBIDX_NETAPI32, + SYSLIBIDX_MAX } enum_syslibraries; \ No newline at end of file diff --git a/dll/dxwnd.cpp b/dll/dxwnd.cpp index a7a6cc6..e56299c 100644 --- a/dll/dxwnd.cpp +++ b/dll/dxwnd.cpp @@ -24,7 +24,7 @@ along with this program. If not, see . #include "dxwnd.h" #include "dxwcore.hpp" -#define VERSION "2.02.19" +#define VERSION "2.02.21" LRESULT CALLBACK HookProc(int ncode, WPARAM wparam, LPARAM lparam); diff --git a/dll/dxwnd.vs2008.suo b/dll/dxwnd.vs2008.suo index 399e48003bd6bdf9e2208b226007d5989e2a8871..069e44e2e089c9ef973a4ef74d0b8989be04f878 100644 GIT binary patch literal 108032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lvt4%>rNG$A;xc!VzJ7enr@EV&4662E0sugJ9H4S zNsPDtHPE!X#i;KQTPwx~<$Yos#klXWNo_X^CVr61%Xu4RnSQ=Q3*o|UC!Ip}x6yxE8_?d_ zKTLc;J89#5h`Kq|YiAve%tBpv7T + + + + + + @@ -356,6 +368,10 @@ RelativePath=".\msvfwhook.cpp" > + + diff --git a/dll/dxwnd.vs2008.vcproj.User-PC.User.user b/dll/dxwnd.vs2008.vcproj.User-PC.User.user deleted file mode 100644 index 21df666..0000000 --- a/dll/dxwnd.vs2008.vcproj.User-PC.User.user +++ /dev/null @@ -1,65 +0,0 @@ - - - - - - - - - - - diff --git a/dll/glhook.cpp b/dll/glhook.cpp index fc6fcf3..ab83054 100644 --- a/dll/glhook.cpp +++ b/dll/glhook.cpp @@ -9,6 +9,8 @@ FARPROC Remap_gl_ProcAddress(LPCSTR proc, HMODULE hModule) { + if(!(dxw.dwFlags2 & HOOKOPENGL)) return NULL; + if (!strcmp(proc,"glViewport") && !pglViewport){ pglViewport=(glViewport_Type)(*pGetProcAddress)(hModule, proc); OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pglViewport); @@ -254,6 +256,7 @@ void WINAPI extglDrawBuffer(GLenum mode) } } (*pglDrawBuffer)(mode); + if (dxw.dwFlags2 & SHOWFPSOVERLAY) dxw.ShowFPS(); } void WINAPI extglPolygonMode(GLenum face, GLenum mode) diff --git a/dll/glhook.h b/dll/glhook.h index e161d91..799040e 100644 --- a/dll/glhook.h +++ b/dll/glhook.h @@ -1,6 +1,5 @@ #include "gl.h" -extern FARPROC Remap_gl_ProcAddress(LPCSTR, HMODULE); extern void HookOpenGLLibs(HMODULE, char *); typedef void (WINAPI *glViewport_Type)(GLint, GLint, GLsizei, GLsizei); diff --git a/dll/hd3d.cpp b/dll/hd3d.cpp index 7a108ab..0edb66a 100644 --- a/dll/hd3d.cpp +++ b/dll/hd3d.cpp @@ -6,11 +6,20 @@ #include #include "dxwnd.h" #include "dxwcore.hpp" +#include "dxhook.h" + +#define HOOKD3D10ANDLATER 1 + +typedef HRESULT (WINAPI *QueryInterface_Type)(void *, REFIID riid, void** ppvObj); typedef void* (WINAPI *Direct3DCreate8_Type)(UINT); typedef void* (WINAPI *Direct3DCreate9_Type)(UINT); +typedef HRESULT (WINAPI *Direct3DCreate9Ex_Type)(UINT, IDirect3D9Ex **); + typedef UINT (WINAPI *GetAdapterCount_Type)(void *); +typedef HRESULT (WINAPI *GetAdapterIdentifier_Type)(void *, UINT, DWORD, D3DADAPTER_IDENTIFIER9 *); typedef HRESULT (WINAPI *CreateDevice_Type)(void *, UINT, D3DDEVTYPE, HWND, DWORD, void *, void **); +typedef HRESULT (WINAPI *CreateDeviceEx_Type)(void *, UINT, D3DDEVTYPE, HWND, DWORD, void *, D3DDISPLAYMODEEX *, void **); typedef HRESULT (WINAPI *EnumAdapterModes8_Type)(void *, UINT, UINT, D3DDISPLAYMODE *); typedef HRESULT (WINAPI *EnumAdapterModes9_Type)(void *, UINT, D3DFORMAT ,UINT, D3DDISPLAYMODE *); typedef HRESULT (WINAPI *GetAdapterDisplayMode_Type)(void *, UINT, D3DDISPLAYMODE *); @@ -18,6 +27,10 @@ typedef HRESULT (WINAPI *GetDisplayMode_Type)(void *, D3DDISPLAYMODE *); typedef HRESULT (WINAPI *Present_Type)(void *, CONST RECT *, CONST RECT *, HWND, CONST RGNDATA *); typedef HRESULT (WINAPI *SetRenderState_Type)(void *, D3DRENDERSTATETYPE, DWORD); typedef HRESULT (WINAPI *GetRenderState_Type)(void *, D3DRENDERSTATETYPE, DWORD ); +typedef HRESULT (WINAPI *CreateAdditionalSwapChain_Type)(void *, D3DPRESENT_PARAMETERS *, IDirect3DSwapChain9 **); +typedef HRESULT (WINAPI *GetDirect3D_Type)(void *, IDirect3D9 **); +typedef HRESULT (WINAPI *GetViewport_Type)(void *, D3DVIEWPORT9 *); +typedef HRESULT (WINAPI *SetViewport_Type)(void *, D3DVIEWPORT9 *); typedef HRESULT (WINAPI *D3D10CreateDevice_Type)(IDXGIAdapter *, D3D10_DRIVER_TYPE, HMODULE, UINT, UINT, ID3D10Device **); typedef HRESULT (WINAPI *D3D10CreateDeviceAndSwapChain_Type)(IDXGIAdapter *, D3D10_DRIVER_TYPE, HMODULE, UINT, UINT, DXGI_SWAP_CHAIN_DESC *, IDXGISwapChain **, ID3D10Device **); @@ -25,11 +38,21 @@ typedef HRESULT (WINAPI *D3D10CreateDevice1_Type)(IDXGIAdapter *, D3D10_DRIVER_T typedef HRESULT (WINAPI *D3D10CreateDeviceAndSwapChain1_Type)(IDXGIAdapter *, D3D10_DRIVER_TYPE, HMODULE, UINT, UINT, DXGI_SWAP_CHAIN_DESC *, IDXGISwapChain **, ID3D10Device **); typedef HRESULT (WINAPI *D3D11CreateDevice_Type)(IDXGIAdapter *, D3D_DRIVER_TYPE, HMODULE, UINT, const D3D_FEATURE_LEVEL *, UINT, UINT, ID3D11Device **, D3D_FEATURE_LEVEL *, ID3D11DeviceContext **); typedef HRESULT (WINAPI *D3D11CreateDeviceAndSwapChain_Type)(IDXGIAdapter *, D3D_DRIVER_TYPE, HMODULE, UINT, const D3D_FEATURE_LEVEL *, UINT, UINT, const DXGI_SWAP_CHAIN_DESC *, IDXGISwapChain **, ID3D11Device **, D3D_FEATURE_LEVEL *, ID3D11DeviceContext **); +typedef void (WINAPI *RSSetViewports_Type)(void *, UINT, D3D11_VIEWPORT *); + +HRESULT WINAPI extQueryInterfaceD3D8(void *, REFIID, void** ); +HRESULT WINAPI extQueryInterfaceDev8(void *, REFIID, void** ); +HRESULT WINAPI extQueryInterfaceD3D9(void *, REFIID, void** ); +HRESULT WINAPI extQueryInterfaceDev9(void *, REFIID, void** ); +HRESULT WINAPI extGetDirect3D(void *, IDirect3D9 **); void* WINAPI extDirect3DCreate8(UINT); void* WINAPI extDirect3DCreate9(UINT); +HRESULT WINAPI extDirect3DCreate9Ex(UINT, IDirect3D9Ex **); UINT WINAPI extGetAdapterCount(void *); +HRESULT WINAPI extGetAdapterIdentifier(void *, UINT, DWORD, D3DADAPTER_IDENTIFIER9 *); HRESULT WINAPI extCreateDevice(void *, UINT, D3DDEVTYPE, HWND, DWORD, D3DPRESENT_PARAMETERS *, void **); +HRESULT WINAPI extCreateDeviceEx(void *, UINT, D3DDEVTYPE, HWND, DWORD, D3DPRESENT_PARAMETERS *, D3DDISPLAYMODEEX *, void **); HRESULT WINAPI extEnumAdapterModes8(void *, UINT, UINT , D3DDISPLAYMODE *); HRESULT WINAPI extEnumAdapterModes9(void *, UINT, D3DFORMAT, UINT , D3DDISPLAYMODE *); HRESULT WINAPI extGetAdapterDisplayMode(void *, UINT, D3DDISPLAYMODE *); @@ -37,6 +60,9 @@ HRESULT WINAPI extGetDisplayMode(void *, D3DDISPLAYMODE *); HRESULT WINAPI extPresent(void *, CONST RECT *, CONST RECT *, HWND, CONST RGNDATA *); HRESULT WINAPI extSetRenderState(void *, D3DRENDERSTATETYPE, DWORD); HRESULT WINAPI extGetRenderState(void *, D3DRENDERSTATETYPE, DWORD); +HRESULT WINAPI extCreateAdditionalSwapChain(void *, D3DPRESENT_PARAMETERS *, IDirect3DSwapChain9 **); +HRESULT WINAPI extGetViewport(void *, D3DVIEWPORT9 *); +HRESULT WINAPI extSetViewport(void *, D3DVIEWPORT9 *); HRESULT WINAPI extD3D10CreateDevice(IDXGIAdapter *, D3D10_DRIVER_TYPE, HMODULE, UINT, UINT, ID3D10Device **); HRESULT WINAPI extD3D10CreateDeviceAndSwapChain(IDXGIAdapter *, D3D10_DRIVER_TYPE, HMODULE, UINT, UINT, DXGI_SWAP_CHAIN_DESC *, IDXGISwapChain **, ID3D10Device **); @@ -44,20 +70,33 @@ HRESULT WINAPI extD3D10CreateDevice1(IDXGIAdapter *, D3D10_DRIVER_TYPE, HMODULE, HRESULT WINAPI extD3D10CreateDeviceAndSwapChain1(IDXGIAdapter *, D3D10_DRIVER_TYPE, HMODULE, UINT, UINT, DXGI_SWAP_CHAIN_DESC *, IDXGISwapChain **, ID3D10Device **); HRESULT WINAPI extD3D11CreateDevice(IDXGIAdapter *, D3D_DRIVER_TYPE, HMODULE, UINT, const D3D_FEATURE_LEVEL *, UINT, UINT, ID3D11Device **, D3D_FEATURE_LEVEL *, ID3D11DeviceContext **); HRESULT WINAPI extD3D11CreateDeviceAndSwapChain(IDXGIAdapter *, D3D_DRIVER_TYPE, HMODULE, UINT, const D3D_FEATURE_LEVEL *, UINT, UINT, const DXGI_SWAP_CHAIN_DESC *, IDXGISwapChain **, ID3D11Device **, D3D_FEATURE_LEVEL *, ID3D11DeviceContext **); +void WINAPI extRSSetViewports(ID3D11DeviceContext *, UINT, D3D11_VIEWPORT *); extern char *ExplainDDError(DWORD); +QueryInterface_Type pQueryInterfaceD3D8; +QueryInterface_Type pQueryInterfaceDev8; +QueryInterface_Type pQueryInterfaceD3D9; +QueryInterface_Type pQueryInterfaceDev9; + +GetDirect3D_Type pGetDirect3D; Direct3DCreate8_Type pDirect3DCreate8 = 0; Direct3DCreate9_Type pDirect3DCreate9 = 0; +Direct3DCreate9Ex_Type pDirect3DCreate9Ex = 0; GetAdapterCount_Type pGetAdapterCount; +GetAdapterIdentifier_Type pGetAdapterIdentifier; CreateDevice_Type pCreateDevice; +CreateDeviceEx_Type pCreateDeviceEx; EnumAdapterModes8_Type pEnumAdapterModes8; EnumAdapterModes9_Type pEnumAdapterModes9; GetAdapterDisplayMode_Type pGetAdapterDisplayMode; GetDisplayMode_Type pGetDisplayMode; -Present_Type pPresent; +Present_Type pPresent = 0; SetRenderState_Type pSetRenderState; GetRenderState_Type pGetRenderState; +CreateAdditionalSwapChain_Type pCreateAdditionalSwapChain; +GetViewport_Type pGetViewport; +SetViewport_Type pSetViewport; D3D10CreateDevice_Type pD3D10CreateDevice; D3D10CreateDeviceAndSwapChain_Type pD3D10CreateDeviceAndSwapChain; @@ -65,9 +104,121 @@ D3D10CreateDevice1_Type pD3D10CreateDevice1; D3D10CreateDeviceAndSwapChain1_Type pD3D10CreateDeviceAndSwapChain1; D3D11CreateDevice_Type pD3D11CreateDevice; D3D11CreateDeviceAndSwapChain_Type pD3D11CreateDeviceAndSwapChain; +RSSetViewports_Type pRSSetViewports; DWORD dwD3DVersion; +FARPROC Remap_d3d8_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + if (!strcmp(proc,"Direct3DCreate8") && !pDirect3DCreate8){ + pDirect3DCreate8=(Direct3DCreate8_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pDirect3DCreate8); + return (FARPROC)extDirect3DCreate8; + } + // NULL -> keep the original call address + return NULL; +} + +HRESULT WINAPI voidDirect3DShaderValidatorCreate9(void) +{ + OutTraceD("Direct3DShaderValidatorCreate9: SUPPRESSED\n"); + return 0; +} + +void WINAPI voidDebugSetLevel(void) +{ + OutTraceD("DebugSetLevel: SUPPRESSED\n"); +} + +void WINAPI voidDebugSetMute(void) +{ + OutTraceD("DebugSetMute: SUPPRESSED\n"); +} + +FARPROC Remap_d3d9_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + // NULL -> keep the original call address + // (FARPROC)-1 -> returns NULL + + if (!strcmp(proc,"Direct3DCreate9") && !pDirect3DCreate9){ + pDirect3DCreate9=(Direct3DCreate9_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pDirect3DCreate9); + return (FARPROC)extDirect3DCreate9; + } + if (!strcmp(proc,"Direct3DCreate9Ex") && !pDirect3DCreate9Ex){ + pDirect3DCreate9Ex=(Direct3DCreate9Ex_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pDirect3DCreate9Ex); + return (FARPROC)extDirect3DCreate9Ex; + } + + if (!(dxw.dwFlags3 & SUPPRESSD3DEXT)) return NULL; + + if (!strcmp(proc,"Direct3DShaderValidatorCreate9")){ + OutTraceD("GetProcAddress: suppressing Direct3DShaderValidatorCreate9\n"); + return (FARPROC)voidDirect3DShaderValidatorCreate9; + //return (FARPROC)-1; + } + if (!strcmp(proc,"DebugSetLevel")){ + OutTraceD("GetProcAddress: suppressing DebugSetLevel\n"); + return (FARPROC)voidDebugSetLevel; + //return (FARPROC)-1; + } + if (!strcmp(proc,"DebugSetMute")){ + OutTraceD("GetProcAddress: suppressing DebugSetMute\n"); + return (FARPROC)voidDebugSetMute; + //return (FARPROC)-1; + } + return NULL; +} + +FARPROC Remap_d3d10_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + if (!strcmp(proc,"D3D10CreateDevice") && !pD3D10CreateDevice){ + pD3D10CreateDevice=(D3D10CreateDevice_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pD3D10CreateDevice); + return (FARPROC)extD3D10CreateDevice; + } + if (!strcmp(proc,"D3D10CreateDeviceAndSwapChain") && !pD3D10CreateDeviceAndSwapChain){ + pD3D10CreateDeviceAndSwapChain=(D3D10CreateDeviceAndSwapChain_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pD3D10CreateDeviceAndSwapChain); + return (FARPROC)extD3D10CreateDeviceAndSwapChain; + } + // NULL -> keep the original call address + return NULL; +} + +FARPROC Remap_d3d10_1_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + if (!strcmp(proc,"D3D10CreateDevice1") && !pD3D10CreateDevice1){ + pD3D10CreateDevice1=(D3D10CreateDevice1_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pD3D10CreateDevice1); + return (FARPROC)extD3D10CreateDevice1; + } + if (!strcmp(proc,"D3D10CreateDeviceAndSwapChain1") && !pD3D10CreateDeviceAndSwapChain1){ + pD3D10CreateDeviceAndSwapChain1=(D3D10CreateDeviceAndSwapChain1_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pD3D10CreateDeviceAndSwapChain1); + return (FARPROC)extD3D10CreateDeviceAndSwapChain1; + } + // NULL -> keep the original call address + return NULL; +} + +FARPROC Remap_d3d11_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + if (!strcmp(proc,"D3D11CreateDevice") && !pD3D11CreateDevice){ + pD3D11CreateDevice=(D3D11CreateDevice_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pD3D11CreateDevice); + return (FARPROC)extD3D11CreateDevice; + } + if (!strcmp(proc,"D3D11CreateDeviceAndSwapChain") && !pD3D11CreateDeviceAndSwapChain){ + pD3D11CreateDeviceAndSwapChain=(D3D11CreateDeviceAndSwapChain_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pD3D11CreateDeviceAndSwapChain); + return (FARPROC)extD3D11CreateDeviceAndSwapChain; + } + // NULL -> keep the original call address + return NULL; +} + int HookDirect3D(HMODULE module, int version){ HINSTANCE hinst; void *tmp; @@ -84,13 +235,16 @@ int HookDirect3D(HMODULE module, int version){ // D3D9 tmp = HookAPI(module, "d3d9.dll", NULL, "Direct3DCreate9", extDirect3DCreate9); if(tmp) pDirect3DCreate9 = (Direct3DCreate9_Type)tmp; + tmp = HookAPI(module, "d3d9.dll", NULL, "Direct3DCreate9Ex", extDirect3DCreate9Ex); + if(tmp) pDirect3DCreate9Ex = (Direct3DCreate9Ex_Type)tmp; +#ifdef HOOKD3D10ANDLATER // D3D10 tmp = HookAPI(module, "d3d10.dll", NULL, "D3D10CreateDevice", extD3D10CreateDevice); if(tmp) pD3D10CreateDevice = (D3D10CreateDevice_Type)tmp; tmp = HookAPI(module, "d3d10.dll", NULL, "D3D10CreateDeviceAndSwapChain", extD3D10CreateDeviceAndSwapChain); if(tmp) pD3D10CreateDeviceAndSwapChain = (D3D10CreateDeviceAndSwapChain_Type)tmp; // D3D10.1 - tmp = HookAPI(module, "d3d10_1.dll", NULL, "D3D10CreateDevice1", extD3D10CreateDevice); + tmp = HookAPI(module, "d3d10_1.dll", NULL, "D3D10CreateDevice1", extD3D10CreateDevice1); if(tmp) pD3D10CreateDevice1 = (D3D10CreateDevice1_Type)tmp; tmp = HookAPI(module, "d3d10_1.dll", NULL, "D3D10CreateDeviceAndSwapChain1", extD3D10CreateDeviceAndSwapChain); if(tmp) pD3D10CreateDeviceAndSwapChain1 = (D3D10CreateDeviceAndSwapChain1_Type)tmp; @@ -99,6 +253,7 @@ int HookDirect3D(HMODULE module, int version){ if(tmp) pD3D11CreateDevice = (D3D11CreateDevice_Type)tmp; tmp = HookAPI(module, "d3d11.dll", NULL, "D3D11CreateDeviceAndSwapChain", extD3D11CreateDeviceAndSwapChain); if(tmp) pD3D11CreateDeviceAndSwapChain = (D3D11CreateDeviceAndSwapChain_Type)tmp; +#endif break; case 8: hinst = LoadLibrary("d3d8.dll"); @@ -118,6 +273,7 @@ int HookDirect3D(HMODULE module, int version){ if(lpd3d) lpd3d->Release(); } break; +#ifdef HOOKD3D10ANDLATER case 10: hinst = LoadLibrary("d3d10.dll"); pD3D10CreateDevice = @@ -207,6 +363,7 @@ int HookDirect3D(HMODULE module, int version){ pD3D11CreateDeviceAndSwapChain = (D3D11CreateDeviceAndSwapChain_Type)GetProcAddress(hinst, "D3D11CreateDeviceAndSwapChain"); break; +#endif } if(pDirect3DCreate8 || pDirect3DCreate9) return 1; return 0; @@ -219,9 +376,9 @@ void* WINAPI extDirect3DCreate8(UINT sdkversion) dwD3DVersion = 8; lpd3d = (*pDirect3DCreate8)(sdkversion); if(!lpd3d) return 0; - //OutTrace("DEBUG: Hooking lpd3d=%x\n", lpd3d); - //OutTrace("DEBUG: Hooking %x -> %x as CreateDevice(D8)\n", (void *)(*(DWORD *)lpd3d + 60), extCreateDevice); + SetHook((void *)(*(DWORD *)lpd3d + 0), extQueryInterfaceD3D8, (void **)&pQueryInterfaceD3D8, "QueryInterface(D8)"); SetHook((void *)(*(DWORD *)lpd3d + 16), extGetAdapterCount, (void **)&pGetAdapterCount, "GetAdapterCount(D8)"); + SetHook((void *)(*(DWORD *)lpd3d + 20), extGetAdapterIdentifier, (void **)&pGetAdapterIdentifier, "GetAdapterIdentifier(D8)"); SetHook((void *)(*(DWORD *)lpd3d + 28), extEnumAdapterModes8, (void **)&pEnumAdapterModes8, "EnumAdapterModes(D8)"); SetHook((void *)(*(DWORD *)lpd3d + 32), extGetAdapterDisplayMode, (void **)&pGetAdapterDisplayMode, "GetAdapterDisplayMode(D8)"); SetHook((void *)(*(DWORD *)lpd3d + 60), extCreateDevice, (void **)&pCreateDevice, "CreateDevice(D8)"); @@ -238,7 +395,9 @@ void* WINAPI extDirect3DCreate9(UINT sdkversion) dwD3DVersion = 9; lpd3d = (*pDirect3DCreate9)(sdkversion); if(!lpd3d) return 0; + SetHook((void *)(*(DWORD *)lpd3d + 0), extQueryInterfaceD3D9, (void **)&pQueryInterfaceD3D9, "QueryInterface(D9)"); SetHook((void *)(*(DWORD *)lpd3d + 16), extGetAdapterCount, (void **)&pGetAdapterCount, "GetAdapterCount(D9)"); + SetHook((void *)(*(DWORD *)lpd3d + 20), extGetAdapterIdentifier, (void **)&pGetAdapterIdentifier, "GetAdapterIdentifier(D9)"); SetHook((void *)(*(DWORD *)lpd3d + 28), extEnumAdapterModes9, (void **)&pEnumAdapterModes9, "EnumAdapterModes(D9)"); SetHook((void *)(*(DWORD *)lpd3d + 32), extGetAdapterDisplayMode, (void **)&pGetAdapterDisplayMode, "GetAdapterDisplayMode(D9)"); SetHook((void *)(*(DWORD *)lpd3d + 64), extCreateDevice, (void **)&pCreateDevice, "CreateDevice(D9)"); @@ -249,6 +408,32 @@ void* WINAPI extDirect3DCreate9(UINT sdkversion) return lpd3d; } +HRESULT WINAPI extDirect3DCreate9Ex(UINT sdkversion, IDirect3D9Ex **ppD3D) +{ + void *lpd3d; + HRESULT res; + + dwD3DVersion = 9; + res = (*pDirect3DCreate9Ex)(sdkversion, ppD3D); + if(res) { + OutTraceD("Direct3DCreate9Ex: ERROR res=%x SDKVERSION=%x\n", res, sdkversion); + return res; + } + lpd3d = *ppD3D; + SetHook((void *)(*(DWORD *)lpd3d + 0), extQueryInterfaceD3D9, (void **)&pQueryInterfaceD3D9, "QueryInterface(D9)"); + SetHook((void *)(*(DWORD *)lpd3d + 16), extGetAdapterCount, (void **)&pGetAdapterCount, "GetAdapterCount(D9)"); + SetHook((void *)(*(DWORD *)lpd3d + 20), extGetAdapterIdentifier, (void **)&pGetAdapterIdentifier, "GetAdapterIdentifier(D9)"); + SetHook((void *)(*(DWORD *)lpd3d + 28), extEnumAdapterModes9, (void **)&pEnumAdapterModes9, "EnumAdapterModes(D9)"); + SetHook((void *)(*(DWORD *)lpd3d + 32), extGetAdapterDisplayMode, (void **)&pGetAdapterDisplayMode, "GetAdapterDisplayMode(D9)"); + SetHook((void *)(*(DWORD *)lpd3d + 64), extCreateDevice, (void **)&pCreateDevice, "CreateDevice(D9)"); + SetHook((void *)(*(DWORD *)lpd3d + 80), extCreateDeviceEx, (void **)&pCreateDeviceEx, "CreateDeviceEx(D9)"); + + OutTraceD("Direct3DCreate9Ex: SDKVERSION=%x pCreateDeviceEx=%x\n", + sdkversion, pDirect3DCreate9Ex); + + return res; +} + UINT WINAPI extGetAdapterCount(void *lpd3d) { UINT res; @@ -261,19 +446,31 @@ UINT WINAPI extGetAdapterCount(void *lpd3d) return res; } +HRESULT WINAPI extGetAdapterIdentifier(void *pd3dd, UINT Adapter, DWORD Flags, D3DADAPTER_IDENTIFIER9 *pIdentifier) +{ + HRESULT res; + OutTraceD("GetAdapterIdentifier: Adapter=%d flags=%x\n", Adapter, Flags); + res=pGetAdapterIdentifier(pd3dd, Adapter, Flags, pIdentifier); + OutTraceD("GetAdapterIdentifier: ret=%x\n", res); + return res; +} + HRESULT WINAPI extReset(void *pd3dd, D3DPRESENT_PARAMETERS* pPresentationParameters) { - OutTraceD("DEBUG: neutralizing pd3dd->Reset()\n"); + OutTraceD("Reset: SUPPRESSED\n"); return D3D_OK; } HRESULT WINAPI extPresent(void *pd3dd, CONST RECT *pSourceRect, CONST RECT *pDestRect, HWND hDestWindowOverride, CONST RGNDATA *pDirtyRegion) { - if (IsDebug) OutTrace("Present\n"); + HRESULT res; + OutTraceB("Present\n"); // frame counter handling.... if (dxw.HandleFPS()) return D3D_OK; // proxy .... - return (*pPresent)(pd3dd, pSourceRect, pDestRect, hDestWindowOverride, pDirtyRegion); + res=(*pPresent)(pd3dd, pSourceRect, pDestRect, hDestWindowOverride, pDirtyRegion); + if (dxw.dwFlags2 & SHOWFPSOVERLAY) dxw.ShowFPS(); + return res; } HRESULT WINAPI extGetDisplayMode(void *lpd3d, D3DDISPLAYMODE *pMode) @@ -322,6 +519,23 @@ HRESULT WINAPI extGetAdapterDisplayMode(void *lpd3d, UINT Adapter, D3DDISPLAYMOD return res; } +//HRESULT extValidateDevice(void *, DWORD *pNumPasses); +//HRESULT extGetDeviceCaps(void *, D3DCAPS9 *pCaps); +//typedef HRESULT (WINAPI *ValidateDevice_Type)(void *, DWORD *); +//typedef HRESULT (WINAPI *GetDeviceCapsD3D_Type)(void *, D3DCAPS9 *); +//ValidateDevice_Type pValidateDevice; +//GetDeviceCapsD3D_Type pGetDeviceCapsD3D; +//HRESULT extValidateDevice(void *lpd3dd, DWORD *pNumPasses) +//{ +// OutTrace("ValidateDevice hooked\n"); +// return (*pValidateDevice)(lpd3dd, pNumPasses); +//} +//HRESULT extGetDeviceCapsD3D(void *lpd3dd, D3DCAPS9 *pCaps) +//{ +// OutTrace("GetDeviceCaps hooked\n"); +// return (*pGetDeviceCapsD3D)(lpd3dd, pCaps); +//} + HRESULT WINAPI extCreateDevice(void *lpd3d, UINT adapter, D3DDEVTYPE devicetype, HWND hfocuswindow, DWORD behaviorflags, D3DPRESENT_PARAMETERS *ppresentparam, void **ppd3dd) { @@ -361,11 +575,6 @@ HRESULT WINAPI extCreateDevice(void *lpd3d, UINT adapter, D3DDEVTYPE devicetype, param[2] = mode.Format; OutTraceD(" Current Format = 0x%x\n", mode.Format); - // useless ... - //param[0] = 0; //defaulting to window width - //param[1] = 0; //defaulting to window height - //param[2] = D3DFMT_UNKNOWN; // try - if(dwD3DVersion == 9){ param[7] = 0; //hDeviceWindow dxw.SetFullScreen(~param[8]?TRUE:FALSE); @@ -391,7 +600,10 @@ HRESULT WINAPI extCreateDevice(void *lpd3d, UINT adapter, D3DDEVTYPE devicetype, if(dwD3DVersion == 8){ void *pReset; pReset=NULL; // to avoid assert condition - SetHook((void *)(*(DWORD *)lpd3d + 32), extGetDisplayMode, (void **)&pGetDisplayMode, "GetDisplayMode(D8)"); + SetHook((void *)(**(DWORD **)ppd3dd + 0), extQueryInterfaceDev8, (void **)&pQueryInterfaceDev8, "QueryInterface(D8)"); + SetHook((void *)(**(DWORD **)ppd3dd + 24), extGetDirect3D, (void **)&pGetDirect3D, "GetDirect3D(D8)"); + //SetHook((void *)(**(DWORD **)ppd3dd + 32), extGetDisplayMode, (void **)&pGetDisplayMode, "GetDisplayMode(D8)"); + SetHook((void *)(**(DWORD **)ppd3dd + 52), extCreateAdditionalSwapChain, (void **)&pCreateAdditionalSwapChain, "CreateAdditionalSwapChain(D8)"); SetHook((void *)(**(DWORD **)ppd3dd + 56), extReset, (void **)&pReset, "Reset(D8)"); SetHook((void *)(**(DWORD **)ppd3dd + 60), extPresent, (void **)&pPresent, "Present(D8)"); if(dxw.dwFlags2 & WIREFRAME){ @@ -403,14 +615,98 @@ HRESULT WINAPI extCreateDevice(void *lpd3d, UINT adapter, D3DDEVTYPE devicetype, else { void *pReset; pReset=NULL; // to avoid assert condition - SetHook((void *)(*(DWORD *)lpd3d + 32), extGetDisplayMode, (void **)&pGetDisplayMode, "GetDisplayMode(D9)"); + SetHook((void *)(**(DWORD **)ppd3dd + 0), extQueryInterfaceDev9, (void **)&pQueryInterfaceDev9, "QueryInterface(D9)"); + SetHook((void *)(**(DWORD **)ppd3dd + 24), extGetDirect3D, (void **)&pGetDirect3D, "GetDirect3D(D9)"); + //SetHook((void *)(**(DWORD **)ppd3dd + 32), extGetDisplayMode, (void **)&pGetDisplayMode, "GetDisplayMode(D9)"); + SetHook((void *)(**(DWORD **)ppd3dd + 52), extCreateAdditionalSwapChain, (void **)&pCreateAdditionalSwapChain, "CreateAdditionalSwapChain(D9)"); SetHook((void *)(**(DWORD **)ppd3dd + 64), extReset, (void **)&pReset, "Reset(D9)"); SetHook((void *)(**(DWORD **)ppd3dd + 68), extPresent, (void **)&pPresent, "Present(D9)"); + //SetHook((void *)(**(DWORD **)ppd3dd +188), extSetViewport, (void **)&pSetViewport, "SetViewport(D9)"); + //SetHook((void *)(**(DWORD **)ppd3dd +192), extGetViewport, (void **)&pGetViewport, "GetViewport(D9)"); if(dxw.dwFlags2 & WIREFRAME){ SetHook((void *)(**(DWORD **)ppd3dd + 228), extSetRenderState, (void **)&pSetRenderState, "SetRenderState(D9)"); SetHook((void *)(**(DWORD **)ppd3dd + 232), extGetRenderState, (void **)&pGetRenderState, "GetRenderState(D9)"); (*pSetRenderState)((void *)*ppd3dd, D3DRS_FILLMODE, D3DFILL_WIREFRAME); } + //SetHook((void *)(**(DWORD **)ppd3dd +280), extValidateDevice, (void **)&pValidateDevice, "ValidateDevice(D9)"); + //SetHook((void *)(**(DWORD **)ppd3dd + 28), extGetDeviceCapsD3D, (void **)&pGetDeviceCapsD3D, "GetDeviceCaps(D9)"); + } + + GetHookInfo()->IsFullScreen = dxw.IsFullScreen(); + GetHookInfo()->DXVersion=(short)dwD3DVersion; + GetHookInfo()->Height=(short)dxw.GetScreenHeight(); + GetHookInfo()->Width=(short)dxw.GetScreenWidth(); + GetHookInfo()->ColorDepth=(short)dxw.VirtualPixelFormat.dwRGBBitCount; + + return 0; +} + +HRESULT WINAPI extCreateDeviceEx(void *lpd3d, UINT adapter, D3DDEVTYPE devicetype, + HWND hfocuswindow, DWORD behaviorflags, D3DPRESENT_PARAMETERS *ppresentparam, D3DDISPLAYMODEEX *pFullscreenDisplayMode, void **ppd3dd) +{ + HRESULT res; + DWORD param[64], *tmp; + D3DDISPLAYMODE mode; + int Windowed; + + memcpy(param, ppresentparam, 56); + dxw.SethWnd(hfocuswindow); + dxw.SetScreenSize(param[0], param[1]); + AdjustWindowFrame(dxw.GethWnd(), dxw.GetScreenWidth(), dxw.GetScreenHeight()); + + tmp = param; + OutTraceD("D3D%d::CreateDeviceEx\n", dwD3DVersion); + OutTraceD(" Adapter = %i\n", adapter); + OutTraceD(" DeviceType = %i\n", devicetype); + OutTraceD(" hFocusWindow = 0x%x\n", hfocuswindow); + OutTraceD(" BehaviorFlags = 0x%x\n", behaviorflags); + OutTraceD(" BackBufferWidth = %i\n", *(tmp ++)); + OutTraceD(" BackBufferHeight = %i\n", *(tmp ++)); + OutTraceD(" BackBufferFormat = %i\n", *(tmp ++)); + OutTraceD(" BackBufferCount = %i\n", *(tmp ++)); + OutTraceD(" MultiSampleType = %i\n", *(tmp ++)); + OutTraceD(" MultiSampleQuality = %i\n", *(tmp ++)); + OutTraceD(" SwapEffect = 0x%x\n", *(tmp ++)); + OutTraceD(" hDeviceWindow = 0x%x\n", *(tmp ++)); + OutTraceD(" Windowed = %i\n", (Windowed=*(tmp ++))); + OutTraceD(" EnableAutoDepthStencil = %i\n", *(tmp ++)); + OutTraceD(" AutoDepthStencilFormat = %i\n", *(tmp ++)); + OutTraceD(" Flags = 0x%x\n", *(tmp ++)); + OutTraceD(" FullScreen_RefreshRateInHz = %i\n", *(tmp ++)); + OutTraceD(" PresentationInterval = 0x%x\n", *(tmp ++)); + + //((LPDIRECT3D9)lpd3d)->GetAdapterDisplayMode(0, &mode); + (*pGetAdapterDisplayMode)(lpd3d, 0, &mode); + param[2] = mode.Format; + OutTraceD(" Current Format = 0x%x\n", mode.Format); + + //param[7] = 0; //hDeviceWindow + param[7] = (DWORD)dxw.GethWnd(); //hDeviceWindow + dxw.SetFullScreen(~param[8]?TRUE:FALSE); + param[8] = 1; //Windowed + param[12] = 0; //FullScreen_RefreshRateInHz; + param[13] = D3DPRESENT_INTERVAL_DEFAULT; //PresentationInterval + + res = (*pCreateDeviceEx)(lpd3d, 0, devicetype, hfocuswindow, behaviorflags, param, pFullscreenDisplayMode, ppd3dd); + if(res){ + OutTraceD("FAILED! %x\n", res); + return res; + } + OutTraceD("SUCCESS!\n"); + + void *pReset; + pReset=NULL; // to avoid assert condition + SetHook((void *)(**(DWORD **)ppd3dd + 0), extQueryInterfaceDev9, (void **)&pQueryInterfaceDev9, "QueryInterface(D9)"); + SetHook((void *)(**(DWORD **)ppd3dd + 32), extGetDisplayMode, (void **)&pGetDisplayMode, "GetDisplayMode(D9)"); + SetHook((void *)(**(DWORD **)ppd3dd + 52), extCreateAdditionalSwapChain, (void **)&pCreateAdditionalSwapChain, "CreateAdditionalSwapChain(D9)"); + SetHook((void *)(**(DWORD **)ppd3dd + 64), extReset, (void **)&pReset, "Reset(D9)"); + SetHook((void *)(**(DWORD **)ppd3dd + 68), extPresent, (void **)&pPresent, "Present(D9)"); + //SetHook((void *)(**(DWORD **)ppd3dd +188), extSetViewport, (void **)&pSetViewport, "SetViewport(D9)"); + //SetHook((void *)(**(DWORD **)ppd3dd +192), extGetViewport, (void **)&pGetViewport, "GetViewport(D9)"); + if(dxw.dwFlags2 & WIREFRAME){ + SetHook((void *)(**(DWORD **)ppd3dd + 228), extSetRenderState, (void **)&pSetRenderState, "SetRenderState(D9)"); + SetHook((void *)(**(DWORD **)ppd3dd + 232), extGetRenderState, (void **)&pGetRenderState, "GetRenderState(D9)"); + (*pSetRenderState)((void *)*ppd3dd, D3DRS_FILLMODE, D3DFILL_WIREFRAME); } GetHookInfo()->IsFullScreen = dxw.IsFullScreen(); @@ -433,10 +729,83 @@ HRESULT WINAPI extGetRenderState(void *pd3dd, D3DRENDERSTATETYPE State, DWORD Va return (*pGetRenderState)(pd3dd, State, Value); } -// to do: -// hook IDirect3DDevice9::CreateAdditionalSwapChain to intercept Present method on further Swap Chains -// hook SetCursorPosition ShowCursor to handle cursor +HRESULT WINAPI extGetViewport(void *pd3dd, D3DVIEWPORT9 *pViewport) +{ + return (*pGetViewport)(pd3dd, pViewport); +} +HRESULT WINAPI extSetViewport(void *pd3dd, D3DVIEWPORT9 *pViewport) +{ + RECT client; + POINT p={0,0}; + (*pGetClientRect)(dxw.GethWnd(), &client); + OutTraceD("SetViewport: declared pos=(%d,%d) size=(%d,%d) depth=(%f;%f)\n", + pViewport->X, pViewport->Y, pViewport->Width, pViewport->Height, pViewport->MinZ, pViewport->MaxZ); + if(IsDebug) OutTrace("glViewport: DEBUG win=(%d,%d) screen=(%d,%d)\n", + client.right, client.bottom, dxw.GetScreenWidth(), dxw.GetScreenHeight()); + pViewport->X = (pViewport->X * (int)client.right) / (int)dxw.GetScreenWidth(); + pViewport->Y = (pViewport->Y * (int)client.bottom) / (int)dxw.GetScreenHeight(); + pViewport->Width = (pViewport->Width * (int)client.right) / (int)dxw.GetScreenWidth(); + pViewport->Height = (pViewport->Height * (int)client.bottom) / (int)dxw.GetScreenHeight(); + OutTraceD("SetViewport: remapped pos=(%d,%d) size=(%d,%d)\n", + pViewport->X, pViewport->Y, pViewport->Width, pViewport->Height); + return (*pSetViewport)(pd3dd, pViewport); +} + +HRESULT WINAPI extCreateAdditionalSwapChain(void *lpd3d, D3DPRESENT_PARAMETERS *pPresentationParameters, IDirect3DSwapChain9 **ppSwapChain) +{ + HRESULT res; + DWORD param[64], *tmp; + D3DDISPLAYMODE mode; + int Windowed; + + memcpy(param, pPresentationParameters, (dwD3DVersion == 9)?56:52); + dxw.SetScreenSize(param[0], param[1]); + AdjustWindowFrame(dxw.GethWnd(), dxw.GetScreenWidth(), dxw.GetScreenHeight()); + + tmp = param; + OutTraceD("D3D%d::CreateAdditionalSwapChain\n", dwD3DVersion); + OutTraceD(" BackBufferWidth = %i\n", *(tmp ++)); + OutTraceD(" BackBufferHeight = %i\n", *(tmp ++)); + OutTraceD(" BackBufferFormat = %i\n", *(tmp ++)); + OutTraceD(" BackBufferCount = %i\n", *(tmp ++)); + OutTraceD(" MultiSampleType = %i\n", *(tmp ++)); + if(dwD3DVersion == 9) OutTraceD(" MultiSampleQuality = %i\n", *(tmp ++)); + OutTraceD(" SwapEffect = 0x%x\n", *(tmp ++)); + OutTraceD(" hDeviceWindow = 0x%x\n", *(tmp ++)); + OutTraceD(" Windowed = %i\n", (Windowed=*(tmp ++))); + OutTraceD(" EnableAutoDepthStencil = %i\n", *(tmp ++)); + OutTraceD(" AutoDepthStencilFormat = %i\n", *(tmp ++)); + OutTraceD(" Flags = 0x%x\n", *(tmp ++)); + OutTraceD(" FullScreen_RefreshRateInHz = %i\n", *(tmp ++)); + OutTraceD(" PresentationInterval = 0x%x\n", *(tmp ++)); + + //((LPDIRECT3D9)lpd3d)->GetAdapterDisplayMode(0, &mode); + (*pGetAdapterDisplayMode)(lpd3d, 0, &mode); + param[2] = mode.Format; + OutTraceD(" Current Format = 0x%x\n", mode.Format); + + if(dwD3DVersion == 9){ + param[7] = 0; //hDeviceWindow + dxw.SetFullScreen(~param[8]?TRUE:FALSE); + param[8] = 1; //Windowed + param[12] = 0; //FullScreen_RefreshRateInHz; + param[13] = D3DPRESENT_INTERVAL_DEFAULT; //PresentationInterval + } + else{ + param[6] = 0; //hDeviceWindow + dxw.SetFullScreen(~param[7]?TRUE:FALSE); + param[7] = 1; //Windowed + param[11] = 0; //FullScreen_RefreshRateInHz; + param[12] = D3DPRESENT_INTERVAL_DEFAULT; //PresentationInterval + } + res=(*pCreateAdditionalSwapChain)(lpd3d, (D3DPRESENT_PARAMETERS *)param, ppSwapChain); + if(res) OutTraceE("CreateAdditionalSwapChain ERROR: res=%x\n", res); + return res; +} + +// to do: +// hook SetCursorPosition ShowCursor to handle cursor HRESULT WINAPI extD3D10CreateDevice( IDXGIAdapter *pAdapter, @@ -447,9 +816,23 @@ HRESULT WINAPI extD3D10CreateDevice( ID3D10Device **ppDevice) { HRESULT res; - OutTraceD("D3D10CreateDevice\n"); + D3D10_VIEWPORT ViewPort; + OutTraceD("D3D10CreateDevice: DriverType=%x Flags=%x SDKVersion=%x\n", DriverType, Flags, SDKVersion); + //return 0x887a0004; res=(*pD3D10CreateDevice)(pAdapter, DriverType, Software, Flags, SDKVersion, ppDevice); - OutTraceD("D3D10CreateDevice ret=%x\n", res); + if(res){ + OutTraceD("D3D10CreateDevice: ret=%x\n", res); + return res; + } + SetHook((void *)(*(DWORD *)*ppDevice + 100), extRSSetViewports, (void **)&pRSSetViewports, "RSSetViewports(D10)"); + ViewPort.TopLeftX=dxw.iPosX; + ViewPort.TopLeftY=dxw.iPosY; + ViewPort.Width=dxw.iSizX; + ViewPort.Height=dxw.iSizY; + ViewPort.MinDepth=1.0; + ViewPort.MaxDepth=1.0; + (*pRSSetViewports)((void *)*ppDevice, 1, (D3D11_VIEWPORT *)&ViewPort); + OutTraceD("D3D10CreateDevice: ret=%x\n", res); return res; } @@ -463,9 +846,10 @@ HRESULT WINAPI extD3D10CreateDevice1( ID3D10Device **ppDevice) { HRESULT res; - OutTraceD("D3D10CreateDevice1\n"); + OutTraceD("D3D10CreateDevice1: DriverType=%x Flags=%x HardwareLevel=%x SDKVersion=%x\n", DriverType, Flags, HardwareLevel, SDKVersion); res=(*pD3D10CreateDevice1)(pAdapter, DriverType, Software, Flags, HardwareLevel, SDKVersion, ppDevice); - OutTraceD("D3D10CreateDevice1 ret=%x\n", res); + SetHook((void *)(*(DWORD *)*ppDevice + 100), extRSSetViewports, (void **)&pRSSetViewports, "RSSetViewports(D10)"); + OutTraceD("D3D10CreateDevice1: ret=%x\n", res); return res; } @@ -480,7 +864,8 @@ HRESULT WINAPI extD3D10CreateDeviceAndSwapChain( ID3D10Device **ppDevice) { HRESULT res; - OutTraceD("D3D10CreateDeviceAndSwapChain\n"); + OutTraceD("D3D10CreateDeviceAndSwapChain: DriverType=%x Flags=%x SDKVersion=%x\n", DriverType, Flags, SDKVersion); + //return 0x887a0004; pSwapChainDesc->OutputWindow = dxw.GethWnd(); pSwapChainDesc->Windowed = true; res=(*pD3D10CreateDeviceAndSwapChain)(pAdapter, DriverType, Software, Flags, SDKVersion, pSwapChainDesc, ppSwapChain, ppDevice); @@ -499,7 +884,8 @@ HRESULT WINAPI extD3D10CreateDeviceAndSwapChain1( ID3D10Device **ppDevice) { HRESULT res; - OutTraceD("D3D10CreateDeviceAndSwapChain1\n"); + OutTraceD("D3D10CreateDeviceAndSwapChain1: DriverType=%x Flags=%x SDKVersion=%x\n", DriverType, Flags, SDKVersion); + //return 0x887a0004; pSwapChainDesc->OutputWindow = dxw.GethWnd(); pSwapChainDesc->Windowed = true; res=(*pD3D10CreateDeviceAndSwapChain1)(pAdapter, DriverType, Software, Flags, SDKVersion, pSwapChainDesc, ppSwapChain, ppDevice); @@ -520,8 +906,15 @@ HRESULT WINAPI extD3D11CreateDevice( ID3D11DeviceContext **ppImmediateContext) { HRESULT res; - OutTraceD("D3D11CreateDevice\n"); + OutTraceD("D3D11CreateDevice: DriverType=%x Flags=%x FeatureLevels=%x SDKVersion=%x\n", DriverType, Flags, FeatureLevels, SDKVersion); + //return 0x887a0004; res=(*pD3D11CreateDevice)(pAdapter, DriverType, Software, Flags, pFeatureLevels, FeatureLevels, SDKVersion, ppDevice, pFeatureLevel, ppImmediateContext); + if(res){ + OutTraceD("D3D11CreateDevice: ret=%x\n", res); + return res; + } + SetHook((void *)(*(DWORD *)ppImmediateContext + 148), extRSSetViewports, (void **)&pRSSetViewports, "RSSetViewports(D11)"); + //SetHook((void *)(*(DWORD *)ppImmediateContext + 152), extRSSetScissorRects, (void **)&pRSSetScissorRects, "RSSetScissorRects(D11)"); OutTraceD("D3D11CreateDevice ret=%x\n", res); return res; } @@ -542,8 +935,81 @@ HRESULT WINAPI extD3D11CreateDeviceAndSwapChain( { HRESULT res; OutTraceD("D3D11CreateDeviceAndSwapChain\n"); - //res=(*pD3D11CreateDeviceAndSwapChain)(pAdapter, DriverType, Software, Flags, pFeatureLevels, FeatureLevels, SDKVersion, pSwapChainDesc, ppSwapChain, *ppDevice, pFeatureLevel, ppImmediateContext); - res=DD_OK; + return 0x887a0004; + res=(*pD3D11CreateDeviceAndSwapChain)(pAdapter, DriverType, Software, Flags, pFeatureLevels, FeatureLevels, SDKVersion, pSwapChainDesc, ppSwapChain, ppDevice, pFeatureLevel, ppImmediateContext); OutTraceD("D3D11CreateDeviceAndSwapChain ret=%x\n", res); return res; } + +void WINAPI extRSSetViewports(ID3D11DeviceContext *This, UINT NumViewports, D3D11_VIEWPORT *pViewports) +{ + OutTraceD("RSSetViewports: NumViewports=%d\n", NumViewports); + + if(NumViewports==1){ + pViewports->TopLeftX=dxw.iPosX; + pViewports->TopLeftY=dxw.iPosY; + pViewports->Width=dxw.iSizX; + pViewports->Height=dxw.iSizY; + } + + (*pRSSetViewports)(This, NumViewports, pViewports); +} + +HRESULT WINAPI extQueryInterfaceD3D8(void *obj, REFIID riid, void** ppvObj) +{ + HRESULT res; + OutTraceD("D3D::QueryInterface(8)\n"); + res=pQueryInterfaceD3D8(obj, riid, ppvObj); + return res; +} + +HRESULT WINAPI extQueryInterfaceDev8(void *obj, REFIID riid, void** ppvObj) +{ + HRESULT res; + OutTraceD("Device::QueryInterface(8)\n"); + res=pQueryInterfaceDev8(obj, riid, ppvObj); + return res; +} + +HRESULT WINAPI extQueryInterfaceD3D9(void *obj, REFIID riid, void** ppvObj) +{ + HRESULT res; + OutTraceD("D3D::QueryInterface(9)\n"); + res=pQueryInterfaceD3D9(obj, riid, ppvObj); + return res; +} + +HRESULT WINAPI extQueryInterfaceDev9(void *obj, REFIID riid, void** ppvObj) +{ + HRESULT res; + OutTraceD("Device::QueryInterface(9): lpd3dd=%x refiid=%x\n", obj, riid); + res=pQueryInterfaceDev9(obj, riid, ppvObj); + if(res){ + OutTraceD("Device::QueryInterface(9): ERROR ret=%x\n", res); + return res; + } + OutTraceD("Device::QueryInterface(9): ppvObj=%x\n", *ppvObj); + + void *pReset; + pReset=NULL; // to avoid assert condition + SetHook((void *)(**(DWORD **)ppvObj + 0), extQueryInterfaceDev9, (void **)&pQueryInterfaceDev9, "QueryInterface(D9)"); + SetHook((void *)(**(DWORD **)ppvObj + 32), extGetDisplayMode, (void **)&pGetDisplayMode, "GetDisplayMode(D9)"); + SetHook((void *)(**(DWORD **)ppvObj + 52), extCreateAdditionalSwapChain, (void **)&pCreateAdditionalSwapChain, "CreateAdditionalSwapChain(D9)"); + SetHook((void *)(**(DWORD **)ppvObj + 64), extReset, (void **)&pReset, "Reset(D9)"); + SetHook((void *)(**(DWORD **)ppvObj + 68), extPresent, (void **)&pPresent, "Present(D9)"); + SetHook((void *)(**(DWORD **)ppvObj +188), extSetViewport, (void **)&pSetViewport, "SetViewport(D9)"); + SetHook((void *)(**(DWORD **)ppvObj +192), extGetViewport, (void **)&pGetViewport, "GetViewport(D9)"); + if(dxw.dwFlags2 & WIREFRAME){ + SetHook((void *)(**(DWORD **)ppvObj + 228), extSetRenderState, (void **)&pSetRenderState, "SetRenderState(D9)"); + SetHook((void *)(**(DWORD **)ppvObj + 232), extGetRenderState, (void **)&pGetRenderState, "GetRenderState(D9)"); + (*pSetRenderState)((void *)*ppvObj, D3DRS_FILLMODE, D3DFILL_WIREFRAME); + } + + return res; +} + +HRESULT WINAPI extGetDirect3D(void *lpdd3dd, IDirect3D9 **ppD3D9) +{ + OutTraceD("Device::GetDirect3D\n"); + return (*pGetDirect3D)(lpdd3dd, ppD3D9); +} diff --git a/dll/hddraw.cpp b/dll/hddraw.cpp index 207a068..1bac199 100644 --- a/dll/hddraw.cpp +++ b/dll/hddraw.cpp @@ -227,6 +227,32 @@ LPVOID rSurface = NULL; static char *SetPixFmt(LPDDSURFACEDESC2); int FlipChainLength=0; +FARPROC Remap_ddraw_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + if (!strcmp(proc,"DirectDrawCreate")){ + pDirectDrawCreate=(DirectDrawCreate_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pDirectDrawCreate); + return (FARPROC)extDirectDrawCreate; + } + if (!strcmp(proc,"DirectDrawCreateEx")){ + pDirectDrawCreateEx=(DirectDrawCreateEx_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pDirectDrawCreateEx); + return (FARPROC)extDirectDrawCreateEx; + } + if (!strcmp(proc,"DirectDrawEnumerateA")){ + pDirectDrawEnumerate=(DirectDrawEnumerate_Type)(*pGetProcAddress)(hModule, proc); + OutTraceP("GetProcAddress: hooking proc=%s at addr=%x\n", proc, pDirectDrawEnumerate); + return (FARPROC)extDirectDrawEnumerateProxy; + } + if (!strcmp(proc,"DirectDrawEnumerateExA")){ + pDirectDrawEnumerateEx=(DirectDrawEnumerateEx_Type)(*pGetProcAddress)(hModule, proc); + OutTraceP("GetProcAddress: hooking proc=%s at addr=%x\n", proc, pDirectDrawEnumerateEx); + return (FARPROC)extDirectDrawEnumerateExProxy; + } + // NULL -> keep the original call address + return NULL; +} + /* ------------------------------------------------------------------------------ */ // auxiliary (static) functions /* ------------------------------------------------------------------------------ */ @@ -467,87 +493,6 @@ void FixPixelFormat(int ColorDepth, DDPIXELFORMAT *pf) } } -// ------------------------------------------------------------------------------------- -// Ole32 CoCreateInstance handling: you can create DirectDraw objects through it! -// utilized so far in a single game: Axiz & Allies -// ------------------------------------------------------------------------------------- - -static void HookDDSession(LPDIRECTDRAW *, int); -//CoCreateInstance_Type pCoCreateInstance=NULL; - -HRESULT STDAPICALLTYPE extCoCreateInstance(REFCLSID rclsid, LPUNKNOWN pUnkOuter, DWORD dwClsContext, REFIID riid, LPVOID FAR* ppv) -{ - HRESULT res; - OutTraceD("CoCreateInstance: rclsid=%x UnkOuter=%x ClsContext=%x refiid=%x\n", - rclsid, pUnkOuter, dwClsContext, riid); - - // CLSID e436ebb3 implies loading quartz.dll to play movies through dshow: - // quartz.dll must be hooked. - if (*(DWORD *)&rclsid==0xe436ebb3){ - HMODULE qlib; - OutTraceD("CoCreateInstance: CLSID_FilterGraph RIID=%x\n", *(DWORD *)&riid); - qlib=(*pLoadLibraryA)("quartz.dll"); - OutTraceD("CoCreateInstance: quartz lib handle=%x\n", qlib); - extern void HookSysLibs(HMODULE); - HookSysLibs(qlib); - } - - res=(*pCoCreateInstance)(rclsid, pUnkOuter, dwClsContext, riid, ppv); - if(res) - OutTraceE("CoCreateInstance: ERROR res=%x\n", res); - else - OutTraceD("CoCreateInstance: ppv=%x->%x\n", *ppv, *(DWORD *)*ppv); - - if (*(DWORD *)&rclsid==*(DWORD *)&CLSID_DirectDraw){ - LPDIRECTDRAW lpOldDDraw; - OutTraceD("CoCreateInstance: CLSID_DirectDraw object\n"); - switch (*(DWORD *)&riid){ - case 0x6C14DB80: - OutTraceD("DirectDrawCreate: IID_DirectDraw RIID\n"); - res=extDirectDrawCreate(NULL, (LPDIRECTDRAW *)&ppv, 0); - if(res)OutTraceD("DirectDrawCreate: res=%x(%s)\n", res, ExplainDDError(res)); - break; - case 0xB3A6F3E0: - OutTraceD("DirectDrawCreate: IID_DirectDraw2 RIID\n"); - res=extDirectDrawCreate(NULL, &lpOldDDraw, 0); - if(res)OutTraceD("DirectDrawCreate: res=%x(%s)\n", res, ExplainDDError(res)); - res=lpOldDDraw->QueryInterface(IID_IDirectDraw2, (LPVOID *)&ppv); - if(res)OutTraceD("QueryInterface: res=%x(%s)\n", res, ExplainDDError(res)); - lpOldDDraw->Release(); - break; - case 0x9c59509a: - OutTraceD("DirectDrawCreate: IID_DirectDraw4 RIID\n"); - res=extDirectDrawCreate(NULL, &lpOldDDraw, 0); - if(res)OutTraceD("DirectDrawCreate: res=%x(%s)\n", res, ExplainDDError(res)); - res=lpOldDDraw->QueryInterface(IID_IDirectDraw4, (LPVOID *)&ppv); - if(res)OutTraceD("QueryInterface: res=%x(%s)\n", res, ExplainDDError(res)); - lpOldDDraw->Release(); - case 0x15e65ec0: - OutTraceD("CoCreateInstance: IID_DirectDraw7 RIID\n"); - res=extDirectDrawCreateEx(NULL, (LPDIRECTDRAW *)&ppv, IID_IDirectDraw7, 0); - if(res)OutTraceD("DirectDrawCreateEx: res=%x(%s)\n", res, ExplainDDError(res)); - break; - case 0xe436ebb3: - break; - } - } - else - if (*(DWORD *)&rclsid==*(DWORD *)&CLSID_DxDiagProvider) res=HookDxDiag(riid, ppv); - - return res; -} - -int HookOle32(HMODULE module, int version) -{ - // used by Axis & Allies .... - void *tmp; - //return 0; - OutTraceD("HookOle32 version=%d\n", version); //GHO - tmp = HookAPI(module, "ole32.dll", NULL, "CoCreateInstance", extCoCreateInstance); - if(tmp) pCoCreateInstance = (CoCreateInstance_Type)tmp; - return 0; -} - int HookDirectDraw(HMODULE module, int version) { HINSTANCE hinst; @@ -2424,6 +2369,7 @@ HRESULT WINAPI sBlt(char *api, LPDIRECTDRAWSURFACE lpdds, LPRECT lpdestrect, res=0; // blit only when source and dest surface are different. Should make ScreenRefresh faster. if (lpdds != lpddssrc) { + if (dxw.dwFlags2 & SHOWFPSOVERLAY) dxw.ShowFPS(lpddssrc); if (IsDebug) BlitTrace("PRIM-NOEMU", lpsrcrect, &destrect, __LINE__); res= (*pBlt)(lpdds, &destrect, lpddssrc, lpsrcrect, dwflags, lpddbltfx); } diff --git a/dll/smack.cpp b/dll/smack.cpp new file mode 100644 index 0000000..bb71d1a --- /dev/null +++ b/dll/smack.cpp @@ -0,0 +1,52 @@ +#include +#include "dxwnd.h" +#include "dxwcore.hpp" +#include "syslibs.h" +#include "dxhook.h" + +#pragma pack(1) + +typedef struct { + UINT32 version; + UINT32 width; + UINT32 height; + UINT32 frame_count; + UINT32 mspf; + char unknown[864]; + UINT32 frame_number; +} SmackStruct; + +typedef SmackStruct * (WINAPI *SmackOpen_Type)(HANDLE, UINT32, INT32); + +SmackOpen_Type pSmackOpen = NULL; + +SmackStruct * WINAPI extSmackOpen(HANDLE, UINT32, INT32); + +FARPROC Remap_smack_ProcAddress(LPCSTR proc, HMODULE hModule) +{ + if (!strcmp(proc,"_SmackOpen@12") && !pSmackOpen){ + pSmackOpen=(SmackOpen_Type)(*pGetProcAddress)(hModule, proc); + OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pSmackOpen); + return (FARPROC)extSmackOpen; + } + // NULL -> keep the original call address + return NULL; +} + +SmackStruct * WINAPI extSmackOpen(HANDLE SmackFile, UINT32 flags, INT32 unknown) +{ + SmackStruct *ret; + OutTraceD("SmackOpen: SmackFile=%x flags=%x unknown=%x\n", SmackFile, flags, unknown); + if(!pSmackOpen) OutTraceE("ASSERT: NULL pSmackOpen\n"); + ret=(*pSmackOpen)(SmackFile, flags, unknown); + OutTraceD("SmackOpen: ret=%x\n", ret); + if (ret) { + OutTraceD("SmackOpen: version=%x screen=(%dx%d) frame_count=%d frame_number=%d\n", + ret->version, ret->width, ret->height, ret->frame_count, ret->frame_number); + //ret->width=800; + //ret->height=600; + } + return ret; +} + + diff --git a/dll/syslibs.cpp b/dll/syslibs.cpp index 0525b66..6c6a6d3 100644 --- a/dll/syslibs.cpp +++ b/dll/syslibs.cpp @@ -1177,22 +1177,19 @@ LONG WINAPI MyChangeDisplaySettings(char *fname, DEVMODE *lpDevMode, DWORD dwfla if(lpDevMode) dxw.SetScreenSize(lpDevMode->dmPelsWidth, lpDevMode->dmPelsHeight); - if (dxw.dwFlags1 & EMULATESURFACE){ - OutTraceD("%s: BYPASS res=DISP_CHANGE_SUCCESSFUL\n", fname); - return DISP_CHANGE_SUCCESSFUL; - } - else{ - if ((dwflags==0 || dwflags==CDS_FULLSCREEN) && lpDevMode){ + if ((dwflags==0 || dwflags==CDS_FULLSCREEN) && lpDevMode){ + + // v2.2.21: save desired mode to possible use in EnumDisplaySettings wrapper v2.2.21 + SetDevMode=*lpDevMode; + pSetDevMode=&SetDevMode; + + if (dxw.dwFlags1 & EMULATESURFACE){ + OutTraceD("%s: BYPASS res=DISP_CHANGE_SUCCESSFUL\n", fname); + return DISP_CHANGE_SUCCESSFUL; + } + else{ DEVMODE NewMode, TryMode; int i; - //EnumDisplaySettings_Type pEnum; - - // find what address call to use - // pEnum = pEnumDisplaySettings ? pEnumDisplaySettings : EnumDisplaySettings; - // pEnum = EnumDisplaySettings; - - SetDevMode=*lpDevMode; - pSetDevMode=&SetDevMode; // set the proper mode NewMode = *lpDevMode; @@ -1223,9 +1220,9 @@ LONG WINAPI MyChangeDisplaySettings(char *fname, DEVMODE *lpDevMode, DWORD dwfla res, ExplainDisplaySettingsRetcode(res)); return res; } - else - return (*ChangeDisplaySettings)(lpDevMode, dwflags); } + else + return (*ChangeDisplaySettings)(lpDevMode, dwflags); } LONG WINAPI extChangeDisplaySettings(DEVMODE *lpDevMode, DWORD dwflags) @@ -1466,44 +1463,19 @@ BOOL WINAPI extGetMessage(LPMSG lpMsg, HWND hwnd, UINT wMsgFilterMin, UINT wMsgF // intercept GetProcAddress to initialize DirectDraw hook pointers. // This is necessary in "The Sims" game, that loads DirectDraw dinamically -#define SYSLIBIDX_KERNEL32 0 -#define SYSLIBIDX_USER32 1 -#define SYSLIBIDX_GDI32 2 -#define SYSLIBIDX_OLE32 3 -#define SYSLIBIDX_DIRECTDRAW 4 -#define SYSLIBIDX_OPENGL 5 -#define SYSLIBIDX_MSVFW 6 -//#define SYSLIBIDX_SMACK 7 -#define SYSLIBIDX_MAX 7 // array size -HMODULE SysLibs[SYSLIBIDX_MAX]; -char *SysNames[SYSLIBIDX_MAX]={ - "kernel32.dll", - "USER32.dll", - "GDI32.dll", - "ole32.dll", - "ddraw.dll", - "opengl32.dll", - //"msvfw32.dll", - "smackw32.dll" -}; -char *SysNames2[SYSLIBIDX_MAX]={ - "kernel32", - "USER32", - "GDI32", - "ole32", - "ddraw", - "opengl32", - //"msvfw32", - "smackw32" -}; + extern void HookModule(HMODULE, int); extern void HookSysLibs(HMODULE); +HMODULE SysLibs[SYSLIBIDX_MAX]; + HMODULE WINAPI LoadLibraryExWrapper(LPCTSTR lpFileName, HANDLE hFile, DWORD dwFlags, char *api) { HMODULE libhandle; int idx; - char *lpName, *lpNext; + + //if(!strcmp(lpFileName, "d3d9.dll") && GetModuleHandle(lpFileName)) return GetModuleHandle(lpFileName); // attempt to avoid loading same dll twice.... + libhandle=(*pLoadLibraryExA)(lpFileName, hFile, dwFlags); OutTraceD("%s: FileName=%s hFile=%x Flags=%x(%s) hmodule=%x\n", api, lpFileName, hFile, dwFlags, ExplainLoadLibFlags(dwFlags), libhandle); if(!libhandle){ @@ -1515,24 +1487,15 @@ HMODULE WINAPI LoadLibraryExWrapper(LPCTSTR lpFileName, HANDLE hFile, DWORD dwFl // there's no symbol map, then itěs no possible to hook function calls. if(dwFlags & (LOAD_LIBRARY_AS_DATAFILE_EXCLUSIVE|LOAD_LIBRARY_AS_DATAFILE)) return libhandle; - lpName=(char *)lpFileName; - while (lpNext=strchr(lpName,'\\')) lpName=lpNext+1; - for(idx=0; idxFileName=%s\n", api, libhandle, lpFileName); - SysLibs[idx]=libhandle; - break; - } - } + idx=dxw.GetDLLIndex((char *)lpFileName); + if(idx != -1) SysLibs[idx]=libhandle; // handle custom OpenGL library - if(!lstrcmpi(lpName,dxw.CustomOpenGLLib)){ + if(!lstrcmpi(lpFileName,dxw.CustomOpenGLLib)){ idx=SYSLIBIDX_OPENGL; SysLibs[idx]=libhandle; } - if (idx == SYSLIBIDX_MAX) HookModule(libhandle, 0); + //if (idx == SYSLIBIDX_MAX) HookModule(libhandle, 0); + if (idx == -1) HookModule(libhandle, 0); return libhandle; } @@ -1567,12 +1530,6 @@ extern HRESULT WINAPI extDirectDrawCreateEx(GUID FAR *, LPDIRECTDRAW FAR *, REFI extern GetProcAddress_Type pGetProcAddress; //extern HRESULT STDAPICALLTYPE extCoCreateInstance(REFCLSID, LPUNKNOWN, DWORD, REFIID, LPVOID FAR*); -int WINAPI extIsDebuggerPresent(void) -{ - OutTraceD("extIsDebuggerPresent: return FALSE\n"); - return FALSE; -} - FARPROC WINAPI extGetProcAddress(HMODULE hModule, LPCSTR proc) { FARPROC ret; @@ -1596,54 +1553,43 @@ FARPROC WINAPI extGetProcAddress(HMODULE hModule, LPCSTR proc) FARPROC remap; switch(idx){ case SYSLIBIDX_DIRECTDRAW: - if (!strcmp(proc,"DirectDrawCreate")){ - pDirectDrawCreate=(DirectDrawCreate_Type)(*pGetProcAddress)(hModule, proc); - OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pDirectDrawCreate); - return (FARPROC)extDirectDrawCreate; - } - if (!strcmp(proc,"DirectDrawCreateEx")){ - pDirectDrawCreateEx=(DirectDrawCreateEx_Type)(*pGetProcAddress)(hModule, proc); - OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pDirectDrawCreateEx); - return (FARPROC)extDirectDrawCreateEx; - } - if (!strcmp(proc,"DirectDrawEnumerateA")){ - pDirectDrawEnumerate=(DirectDrawEnumerate_Type)(*pGetProcAddress)(hModule, proc); - OutTraceP("GetProcAddress: hooking proc=%s at addr=%x\n", proc, pDirectDrawEnumerate); - return (FARPROC)extDirectDrawEnumerateProxy; - } - if (!strcmp(proc,"DirectDrawEnumerateExA")){ - pDirectDrawEnumerateEx=(DirectDrawEnumerateEx_Type)(*pGetProcAddress)(hModule, proc); - OutTraceP("GetProcAddress: hooking proc=%s at addr=%x\n", proc, pDirectDrawEnumerateEx); - return (FARPROC)extDirectDrawEnumerateExProxy; - } + if (remap=Remap_ddraw_ProcAddress(proc, hModule)) return remap; break; case SYSLIBIDX_USER32: - if (!strcmp(proc,"ChangeDisplaySettingsA")){ - pChangeDisplaySettings=(ChangeDisplaySettings_Type)(*pGetProcAddress)(hModule, proc); - OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pChangeDisplaySettings); - return (FARPROC)extChangeDisplaySettings; - } + if (remap=Remap_user32_ProcAddress(proc, hModule)) return remap; break; case SYSLIBIDX_KERNEL32: - if (!strcmp(proc,"IsDebuggerPresent")){ - OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), extIsDebuggerPresent); - return (FARPROC)extIsDebuggerPresent; - } - case SYSLIBIDX_OLE32: - if (!strcmp(proc,"CoCreateInstance")){ - pCoCreateInstance=(CoCreateInstance_Type)(*pGetProcAddress)(hModule, proc); - OutTraceD("GetProcAddress: hooking proc=%s at addr=%x\n", ProcToString(proc), pCoCreateInstance); - return (FARPROC)extCoCreateInstance; - } + if (remap=Remap_kernel32_ProcAddress(proc, hModule)) return remap; + break; + case SYSLIBIDX_OLE32: + if (remap=Remap_ole32_ProcAddress(proc, hModule)) return remap; + break; + case SYSLIBIDX_DIRECT3D8: + if (remap=Remap_d3d8_ProcAddress(proc, hModule)) return remap; + break; + case SYSLIBIDX_DIRECT3D9: + if (remap=Remap_d3d9_ProcAddress(proc, hModule)) return remap; + break; + case SYSLIBIDX_DIRECT3D10: + if (remap=Remap_d3d10_ProcAddress(proc, hModule)) return remap; + break; + case SYSLIBIDX_DIRECT3D10_1: + if (remap=Remap_d3d10_1_ProcAddress(proc, hModule)) return remap; + break; + case SYSLIBIDX_DIRECT2D11: + if (remap=Remap_d3d11_ProcAddress(proc, hModule)) return remap; break; case SYSLIBIDX_OPENGL: - if(!(dxw.dwFlags2 & HOOKOPENGL)) break; if (remap=Remap_gl_ProcAddress(proc, hModule)) return remap; break; case SYSLIBIDX_MSVFW: if (remap=Remap_vfw_ProcAddress(proc, hModule)) return remap; break; - //default: + case SYSLIBIDX_SMACK: + if (remap=Remap_smack_ProcAddress(proc, hModule)) return remap; + break; + default: + break; } } else { @@ -2445,16 +2391,6 @@ LPTOP_LEVEL_EXCEPTION_FILTER WINAPI extSetUnhandledExceptionFilter(LPTOP_LEVEL_E return (*pSetUnhandledExceptionFilter)(myUnhandledExceptionFilter); } -BOOL WINAPI extGetDiskFreeSpaceA(LPCSTR lpRootPathName, LPDWORD lpSectorsPerCluster, LPDWORD lpBytesPerSector, LPDWORD lpNumberOfFreeClusters, LPDWORD lpTotalNumberOfClusters) -{ - BOOL ret; - OutTraceD("GetDiskFreeSpace: RootPathName=\"%s\"\n", lpRootPathName); - ret=(*pGetDiskFreeSpaceA)(lpRootPathName, lpSectorsPerCluster, lpBytesPerSector, lpNumberOfFreeClusters, lpTotalNumberOfClusters); - if(!ret) OutTraceE("GetDiskFreeSpace: ERROR err=%d at %d\n", GetLastError(), __LINE__); - *lpNumberOfFreeClusters = 16000; - return ret; -} - BOOL WINAPI extSetDeviceGammaRamp(HDC hDC, LPVOID lpRamp) { BOOL ret; @@ -2515,69 +2451,6 @@ LRESULT WINAPI extSendMessage(HWND hwnd, UINT Msg, WPARAM wParam, LPARAM lParam) return ret; } -DWORD WINAPI extGetTickCount(void) -{ - return dxw.GetTickCount(); -} - -void WINAPI extGetSystemTime(LPSYSTEMTIME lpSystemTime) -{ - dxw.GetSystemTime(lpSystemTime); - if (IsDebug) OutTrace("GetSystemTime: %02d:%02d:%02d.%03d\n", - lpSystemTime->wHour, lpSystemTime->wMinute, lpSystemTime->wSecond, lpSystemTime->wMilliseconds); -} - - -void WINAPI extGetLocalTime(LPSYSTEMTIME lpLocalTime) -{ - SYSTEMTIME SystemTime; - dxw.GetSystemTime(&SystemTime); - SystemTimeToTzSpecificLocalTime(NULL, &SystemTime, lpLocalTime); - if (IsDebug) OutTrace("GetLocalTime: %02d:%02d:%02d.%03d\n", - lpLocalTime->wHour, lpLocalTime->wMinute, lpLocalTime->wSecond, lpLocalTime->wMilliseconds); -} - -UINT_PTR WINAPI extSetTimer(HWND hWnd, UINT_PTR nIDEvent, UINT uElapse, TIMERPROC lpTimerFunc) -{ - UINT uShiftedElapse; - // beware: the quicker the time flows, the more the time clicks are incremented, - // and the lesser the pauses must be lasting! Shift operations are reverted in - // GetSystemTime vs. Sleep or SetTimer - uShiftedElapse = dxw.StretchTime(uElapse); - if (IsDebug) OutTrace("SetTimer: elapse=%d->%d timeshift=%d\n", uElapse, uShiftedElapse, dxw.TimeShift); - return (*pSetTimer)(hWnd, nIDEvent, uShiftedElapse, lpTimerFunc); -} - -VOID WINAPI extSleep(DWORD dwMilliseconds) -{ - DWORD dwNewDelay; - dwNewDelay=dwMilliseconds; - if (dwMilliseconds!=INFINITE && dwMilliseconds!=0){ - dwNewDelay = dxw.StretchTime(dwMilliseconds); - if (dwNewDelay==0){ // oh oh! troubles... - if (dxw.TimeShift > 0) dwNewDelay=1; // minimum allowed... - else dwNewDelay = INFINITE-1; // maximum allowed !!! - } - } - if (IsDebug) OutTrace("Sleep: msec=%d->%d timeshift=%d\n", dwMilliseconds, dwNewDelay, dxw.TimeShift); - (*pSleep)(dwNewDelay); -} - -DWORD WINAPI extSleepEx(DWORD dwMilliseconds, BOOL bAlertable) -{ - DWORD dwNewDelay; - dwNewDelay=dwMilliseconds; - if (dwMilliseconds!=INFINITE && dwMilliseconds!=0){ - dwNewDelay = dxw.StretchTime(dwMilliseconds); - if (dwNewDelay==0){ // oh oh! troubles... - if (dxw.TimeShift > 0) dwNewDelay=1; // minimum allowed... - else dwNewDelay = INFINITE-1; // maximum allowed !!! - } - } - if (IsDebug) OutTrace("SleepEx: msec=%d->%d alertable=%x, timeshift=%d\n", dwMilliseconds, dwNewDelay, bAlertable, dxw.TimeShift); - return (*pSleepEx)(dwNewDelay, bAlertable); -} - DWORD WINAPI exttimeGetTime(void) { DWORD ret; @@ -2586,12 +2459,6 @@ DWORD WINAPI exttimeGetTime(void) return ret; } -void WINAPI extGetSystemTimeAsFileTime(LPFILETIME lpSystemTimeAsFileTime) -{ - if (IsDebug) OutTrace("GetSystemTimeAsFileTime\n"); - dxw.GetSystemTimeAsFileTime(lpSystemTimeAsFileTime); -} - int WINAPI extShowCursor(BOOL bShow) { static int iFakeCounter; @@ -2617,130 +2484,3 @@ int WINAPI extShowCursor(BOOL bShow) return ret; } -/* -From MSDN: -Operating system Version number dwMajorVersion dwMinorVersion Other -Windows 8 6.2 6 2 OSVERSIONINFOEX.wProductType == VER_NT_WORKSTATION -Windows Server 2012 6.2 6 2 OSVERSIONINFOEX.wProductType != VER_NT_WORKSTATION -Windows 7 6.1 6 1 OSVERSIONINFOEX.wProductType == VER_NT_WORKSTATION -Windows Server 2008 R2 6.1 6 1 OSVERSIONINFOEX.wProductType != VER_NT_WORKSTATION -Windows Server 2008 6.0 6 0 OSVERSIONINFOEX.wProductType != VER_NT_WORKSTATION -Windows Vista 6.0 6 0 OSVERSIONINFOEX.wProductType == VER_NT_WORKSTATION -Windows Server 2003 R2 5.2 5 2 GetSystemMetrics(SM_SERVERR2) != 0 -Windows Home Server 5.2 5 2 OSVERSIONINFOEX.wSuiteMask & VER_SUITE_WH_SERVER -Windows Server 2003 5.2 5 2 GetSystemMetrics(SM_SERVERR2) == 0 -Windows XP Pro x64 Ed. 5.2 5 2 (OSVERSIONINFOEX.wProductType == VER_NT_WORKSTATION) && (SYSTEM_INFO.wProcessorArchitecture==PROCESSOR_ARCHITECTURE_AMD64) -Windows XP 5.1 5 1 Not applicable -Windows 2000 5.0 5 0 Not applicable -From http://delphi.about.com/cs/adptips2000/a/bltip1100_2.htm -Windows 95 4.0 4 0 -Windows 98/SE" 4.10 4 10 if osVerInfo.szCSDVersion[1] = 'A' then Windows98SE -Windows ME 4.90 4 90 -*/ - -static struct {char bMajor; char bMinor; char *sName;} WinVersions[9]= -{ - {4, 0, "Windows 95"}, - {4,10, "Windows 98/SE"}, - {4,90, "Windows ME"}, - {5, 0, "Windows 2000"}, - {5, 1, "Windows XP"}, - {5, 2, "Windows Server 2003"}, - {6, 0, "Windows Vista"}, - {6, 1, "Windows 7"}, - {6, 2, "Windows 8"} -}; - -BOOL WINAPI extGetVersionEx(LPOSVERSIONINFO lpVersionInfo) -{ - BOOL ret; - - ret=(*pGetVersionEx)(lpVersionInfo); - if(!ret) { - OutTraceE("GetVersionEx: ERROR err=%d\n", GetLastError()); - return ret; - } - - OutTraceD("GetVersionEx: version=%d.%d build=(%d)\n", - lpVersionInfo->dwMajorVersion, lpVersionInfo->dwMinorVersion, lpVersionInfo->dwBuildNumber); - - if(dxw.dwFlags2 & FAKEVERSION) { - // fake Win XP build 0 - lpVersionInfo->dwMajorVersion = WinVersions[dxw.FakeVersionId].bMajor; - lpVersionInfo->dwMinorVersion = WinVersions[dxw.FakeVersionId].bMinor; - lpVersionInfo->dwBuildNumber = 0; - OutTraceD("GetVersionEx: FIXED version=%d.%d build=(%d) os=\"%s\"\n", - lpVersionInfo->dwMajorVersion, lpVersionInfo->dwMinorVersion, lpVersionInfo->dwBuildNumber, - WinVersions[dxw.FakeVersionId].sName); - } - return TRUE; -} - -DWORD WINAPI extGetVersion(void) -{ - DWORD dwVersion; - DWORD dwMajorVersion; - DWORD dwMinorVersion; - DWORD dwBuild = 0; - - dwVersion = (*pGetVersion)(); - - // Get the Windows version. - - dwMajorVersion = (DWORD)(LOBYTE(LOWORD(dwVersion))); - dwMinorVersion = (DWORD)(HIBYTE(LOWORD(dwVersion))); - - // Get the build number. - - if (dwVersion < 0x80000000) - dwBuild = (DWORD)(HIWORD(dwVersion)); - - OutTraceD("GetVersion: version=%d.%d build=(%d)\n", dwMajorVersion, dwMinorVersion, dwBuild); - - if(dxw.dwFlags2 & FAKEVERSION) { - dwVersion = WinVersions[dxw.FakeVersionId].bMajor | (WinVersions[dxw.FakeVersionId].bMinor << 8); - dwMajorVersion = (DWORD)(LOBYTE(LOWORD(dwVersion))); - dwMinorVersion = (DWORD)(HIBYTE(LOWORD(dwVersion))); - dwBuild = (DWORD)(HIWORD(dwVersion)); - OutTraceD("GetVersion: FIXED version=%d.%d build=(%d) os=\"%s\"\n", - dwMajorVersion, dwMinorVersion, dwBuild, WinVersions[dxw.FakeVersionId].sName); - } - - return dwVersion; -} - -/* ------------------------------------------------------------------------------- - -GlobalMemoryStatus: MSDN documents that on modern PCs that have more than DWORD -memory values the GlobalMemoryStatus sets the fields to -1 (0xFFFFFFFF) and you -should use GlobalMemoryStatusEx instead. -But in some cases the value is less that DWORD max, but greater that DWORD>>1, that -is the calling application may get a big value and see it as a signed negative -value, as it happened to Nocturne on my PC. That's why it's not adviseable to write: -if(lpBuffer->dwTotalPhys== -1) ... -but this way: -if ((int)lpBuffer->dwTotalPhys < 0) ... -and also don't set -BIGENOUGH 0x80000000 // possibly negative!!! -but: -BIGENOUGH 0x20000000 // surely positive !!! - -/* ---------------------------------------------------------------------------- */ -#define BIGENOUGH 0x20000000 - -void WINAPI extGlobalMemoryStatus(LPMEMORYSTATUS lpBuffer) -{ - (*pGlobalMemoryStatus)(lpBuffer); - OutTraceD("GlobalMemoryStatus: Length=%x MemoryLoad=%x " - "TotalPhys=%x AvailPhys=%x TotalPageFile=%x AvailPageFile=%x TotalVirtual=%x AvailVirtual=%x\n", - lpBuffer->dwMemoryLoad, lpBuffer->dwTotalPhys, lpBuffer->dwAvailPhys, - lpBuffer->dwTotalPageFile, lpBuffer->dwAvailPageFile, lpBuffer->dwTotalVirtual, lpBuffer->dwAvailVirtual); - if(lpBuffer->dwLength==sizeof(MEMORYSTATUS)){ - if ((int)lpBuffer->dwTotalPhys < 0) lpBuffer->dwTotalPhys = BIGENOUGH; - if ((int)lpBuffer->dwAvailPhys < 0) lpBuffer->dwAvailPhys = BIGENOUGH; - if ((int)lpBuffer->dwTotalPageFile < 0) lpBuffer->dwTotalPageFile = BIGENOUGH; - if ((int)lpBuffer->dwAvailPageFile < 0) lpBuffer->dwAvailPageFile = BIGENOUGH; - if ((int)lpBuffer->dwTotalVirtual < 0) lpBuffer->dwTotalVirtual = BIGENOUGH; - if ((int)lpBuffer->dwAvailVirtual < 0) lpBuffer->dwAvailVirtual = BIGENOUGH; - } -} diff --git a/dll/syslibs.h b/dll/syslibs.h index b5e3d18..329fdb5 100644 --- a/dll/syslibs.h +++ b/dll/syslibs.h @@ -278,6 +278,7 @@ extern DWORD WINAPI extGetTickCount(void); extern DWORD WINAPI extGetVersion(void); extern BOOL WINAPI extGetVersionEx(LPOSVERSIONINFO); extern void WINAPI extGlobalMemoryStatus(LPMEMORYSTATUS); +extern int WINAPI extIsDebuggerPresent(void); extern HMODULE WINAPI extLoadLibraryA(LPCTSTR); extern HMODULE WINAPI extLoadLibraryExA(LPCTSTR, HANDLE, DWORD); extern HMODULE WINAPI extLoadLibraryW(LPCWSTR); diff --git a/host/MainFrm.cpp b/host/MainFrm.cpp index b0570fd..e09a47f 100644 --- a/host/MainFrm.cpp +++ b/host/MainFrm.cpp @@ -41,6 +41,8 @@ IMPLEMENT_DYNCREATE(CMainFrame, CFrameWnd) BEGIN_MESSAGE_MAP(CMainFrame, CFrameWnd) //{{AFX_MSG_MAP(CMainFrame) ON_WM_CREATE() + ON_WM_MOVE() + ON_WM_SIZE() //}}AFX_MSG_MAP END_MESSAGE_MAP() @@ -64,6 +66,32 @@ CMainFrame::CMainFrame() CMainFrame::~CMainFrame() { + char InitPath[MAX_PATH]; + char val[32]; + GetCurrentDirectory(MAX_PATH, InitPath); + strcat_s(InitPath, sizeof(InitPath), "\\dxwnd.ini"); + + // adjust client win coordinates + RECT rect; + rect.top = y; + rect.bottom = y + cy; + rect.left = x; + rect.right = x + cx; + AdjustWindowRect(&rect, WS_OVERLAPPEDWINDOW, 1); + x = rect.left; + y = rect.top; + cx = rect.right - rect.left; + cy = rect.bottom - rect.top; + + // save window rect + sprintf_s(val, sizeof(val), "%i", x); + WritePrivateProfileString("window", "posx", val, InitPath); + sprintf_s(val, sizeof(val), "%i", y); + WritePrivateProfileString("window", "posy", val, InitPath); + sprintf_s(val, sizeof(val), "%i", cx); + WritePrivateProfileString("window", "sizx", val, InitPath); + sprintf_s(val, sizeof(val), "%i", cy); + WritePrivateProfileString("window", "sizy", val, InitPath); } int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct) @@ -76,13 +104,32 @@ int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct) BOOL CMainFrame::PreCreateWindow(CREATESTRUCT& cs) { - cs.cx = 320; - cs.cy = 200; + char InitPath[MAX_PATH]; + GetCurrentDirectory(MAX_PATH, InitPath); + strcat_s(InitPath, sizeof(InitPath), "\\dxwnd.ini"); + cs.x = GetPrivateProfileInt("window", "posx", 50, InitPath); + cs.y = GetPrivateProfileInt("window", "posy", 50, InitPath); + cs.cx = GetPrivateProfileInt("window", "sizx", 320, InitPath); + cs.cy = GetPrivateProfileInt("window", "sizy", 200, InitPath); if( !CFrameWnd::PreCreateWindow(cs) ) return FALSE; return TRUE; } +void CMainFrame::OnMove(int x, int y) +{ + CFrameWnd::OnMove(x, y); + this->x=x; + this->y=y; +} + +void CMainFrame::OnSize(UINT nType, int cx, int cy) +{ + CFrameWnd::OnSize(nType, cx, cy); + this->cx=cx; + this->cy=cy; +} + ///////////////////////////////////////////////////////////////////////////// // CMainFrame Diagnostic Class diff --git a/host/MainFrm.h b/host/MainFrm.h index d7f61da..945e1f4 100644 --- a/host/MainFrm.h +++ b/host/MainFrm.h @@ -31,6 +31,7 @@ public: // Implementation public: virtual ~CMainFrame(); + int x, y, cx, cy; #ifdef _DEBUG virtual void AssertValid() const; virtual void Dump(CDumpContext& dc) const; @@ -40,6 +41,8 @@ public: protected: //{{AFX_MSG(CMainFrame) afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct); + afx_msg void OnMove(int, int); + afx_msg void OnSize(UINT, int, int); //}}AFX_MSG DECLARE_MESSAGE_MAP() }; diff --git a/host/Resource.h b/host/Resource.h index 0823b97..9d0fc88 100644 --- a/host/Resource.h +++ b/host/Resource.h @@ -124,6 +124,7 @@ #define IDC_LIMITRESOURCES 1071 #define IDC_SUPPRESSIME 1072 #define IDC_SETCOMPATIBILITY 1073 +#define IDC_SUPPRESSD3DEXT 1073 #define IDC_FIXNCHITTEST 1074 #define IDC_LIMITFPS 1075 #define IDC_SKIPFPS 1076 @@ -147,6 +148,8 @@ #define IDC_STARTDEBUG 1093 #define IDC_WIREFRAME 1094 #define IDC_DISABLEGAMMARAMP 1095 +#define IDC_WINDOWIZE2 1095 +#define IDC_HOOKDLLS 1095 #define IDC_FORCEWINRESIZE 1096 #define IDC_TIMESLIDER 1097 #define IDC_FORCEHOOKOPENGL 1098 diff --git a/host/TabCompat.cpp b/host/TabCompat.cpp index 77880e6..5ca314a 100644 --- a/host/TabCompat.cpp +++ b/host/TabCompat.cpp @@ -32,6 +32,7 @@ void CTabCompat::DoDataExchange(CDataExchange* pDX) DDX_Check(pDX, IDC_HANDLEEXCEPTIONS, cTarget->m_HandleExceptions); DDX_Check(pDX, IDC_LIMITRESOURCES, cTarget->m_LimitResources); DDX_Check(pDX, IDC_SUPPRESSIME, cTarget->m_SuppressIME); + DDX_Check(pDX, IDC_SUPPRESSD3DEXT, cTarget->m_SuppressD3DExt); } BEGIN_MESSAGE_MAP(CTabCompat, CDialog) diff --git a/host/TabProgram.cpp b/host/TabProgram.cpp index 5df021c..ea5ecc8 100644 --- a/host/TabProgram.cpp +++ b/host/TabProgram.cpp @@ -32,6 +32,7 @@ void CTabProgram::DoDataExchange(CDataExchange* pDX) DDX_Text(pDX, IDC_TITLE, cTarget->m_Title); DDX_Check(pDX, IDC_UNNOTIFY, cTarget->m_UnNotify); DDX_Check(pDX, IDC_WINDOWIZE, cTarget->m_Windowize); + DDX_Check(pDX, IDC_HOOKDLLS, cTarget->m_HookDLLs); DDX_Check(pDX, IDC_NOBANNER, cTarget->m_NoBanner); DDX_Check(pDX, IDC_STARTDEBUG, cTarget->m_StartDebug); DDX_Check(pDX, IDC_CLIENTREMAPPING, cTarget->m_ClientRemapping); diff --git a/host/TargetDlg.cpp b/host/TargetDlg.cpp index 7c4290c..37ae83f 100644 --- a/host/TargetDlg.cpp +++ b/host/TargetDlg.cpp @@ -35,10 +35,12 @@ CTargetDlg::CTargetDlg(CWnd* pParent /*=NULL*/) m_HandleDC = FALSE; m_HandleExceptions = FALSE; m_SuppressIME = FALSE; + m_SuppressD3DExt = FALSE; m_SetCompatibility = FALSE; m_LimitResources = FALSE; m_UnNotify = FALSE; m_Windowize = TRUE; + m_HookDLLs = FALSE; m_NoBanner = FALSE; m_StartDebug = FALSE; m_FilePath = _T(""); diff --git a/host/TargetDlg.h b/host/TargetDlg.h index c3c1c9b..307de3f 100644 --- a/host/TargetDlg.h +++ b/host/TargetDlg.h @@ -41,6 +41,7 @@ public: BOOL m_HandleDC; BOOL m_UnNotify; BOOL m_Windowize; + BOOL m_HookDLLs; BOOL m_NoBanner; BOOL m_StartDebug; CString m_FilePath; @@ -101,6 +102,7 @@ public: BOOL m_SuppressIME; BOOL m_SetCompatibility; BOOL m_WireFrame; + BOOL m_SuppressD3DExt; int m_InitX; int m_InitY; int m_MaxX; diff --git a/host/dxwnd.ini b/host/dxwnd.ini new file mode 100644 index 0000000..e198da0 --- /dev/null +++ b/host/dxwnd.ini @@ -0,0 +1,5 @@ +[window] +posx=1104 +posy=310 +sizx=303 +sizy=138 diff --git a/host/dxwndhost.aps b/host/dxwndhost.aps index b0ac20a02f9189c4450c5f89cc9aa210de5d9ea7..c5e2e0ee9789bd0aaf9cc796b7aebd8010d8eccc 100644 GIT binary patch delta 4066 zcmZu!3v?9a6~6xvH?JjxCfUtyaCyj4P|-~`$?jSTZZeZ(%4TQTog^DxOCUTffq+no zCL|%&77HSB)k#|gw5i3G3c6U7S_Bn~ROkUzK!MPQM~XSvdaM@9(cXV%CrOjcp6s3b zec!$RQa+L>SZDxId6us5L1Q1FEBvs?0IC#aMtPMS6e&N2mbhWD zK~zi8D7K`HWJ~a&w1N>!0k9`-n?Mo|++#>0Qbk0HRw*I+mS^#mmK4MHuqVwid6}UI zM59tfkGzokBAWvEI&BVpDp4!zx1_R4S!Vpe(3w zZD|qQYrxe?O;j?AQR;!!23%efi7Jr+_?qOP)nS5Fo`=RQEr#y{Y+I0Lq5Be8yDh_I z|A8UoMV88HD!IxF>i{pc6|nnoW`<3;A8<^&Q)mI4+U{VjxFf^fzTSwUsgx_#;eaZa z$w67=JM8s9n?Y8{u@LRBs!CD56W(HIH;ABIEvpq_UQ=%gbR<*Fki$u=6gDKWDy1%o zd7;z5s$@~B#bDvkHJhl^89n1KghvfDq?83hAt^!;{vz0BfKfFN>8pv~ z188R8-503l>HWp<7#_2Zng6)SCA0IV*jF&O0gO`v9g6-uOBqUrRtu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O zE;(}NX7Xs#j{p69GBMz(yVDak!wjzDJ+8m^2Fte5k=rj0!;HQPeE88AZ0O5xyVrO0 zULWa{Ngdm0qZ4R`iu2Sg!+bNqr_ZtvY&3_|vpySroTRa_b~@fLR{=;{iR)Kp84`KX zcTTbnJI!Eg?9@c>X@Qm4*;YHvWH$vC{4+jz+RTz2bQrBVgXXhlW)XhcS-i`AmHPx( zz(L2;_V+P#&dfRmefb=F)j_l9$-l58!Y=&)OaE#%lnw_t-NPOVDElHlb%|#y;HH0>*&*TQe#VZJ(yW~J&qTk6^B@04@XL~{ z8SU0i0Pfwz{?GaBr|>a5?lIF8UiX_m4E=}K64;&lnDyl}!>9cG_B>#_1fB3TJH~C? zg<*tEHjs3~o1*}(r?7rO?$2T7shm7iNLW&_AbG)cE*9b-eIdZs3+rCOb_r`-%Z>?~ z-_Cl4t?OX@+{QI@5q7>iI{54Ttn_J44m-j^+{VHCgoV#V$@U($OOQKmuw%mZ{FC(x zd-Vb97vk>Wlsz&~eHu$mtaKVDFMq{C!oHTm)(cx-$aZlXHzPn;*G!(-!rOEGMb<0G z{4Uln$dm68HvT9ljhyT`%SxwnP`yFe!J8b+;oy!3Y`p+26DZr3OVi`GaIl#Nw|HQf z%7gq|*2@*NJ(u+hn~=xMGx&&xCn-BWk&A#orMoAx5C`e;r`UR78z-|}LUeyJWl8~0 d+sZTDxALHfj}UvfqmcCr#nfWTUN52P{|AeQp6vht diff --git a/host/dxwndhost.h b/host/dxwndhost.h index f2ad8ac..9dd2d45 100644 --- a/host/dxwndhost.h +++ b/host/dxwndhost.h @@ -44,8 +44,6 @@ public: // Implementation //{{AFX_MSG(CDxwndhostApp) afx_msg void OnAppAbout(); - //afx_msg void OnClose(); - //afx_msg void OnAppExit(); //}}AFX_MSG DECLARE_MESSAGE_MAP() }; diff --git a/host/dxwndhost.rc b/host/dxwndhost.rc index 9bcfa59..d1b3efa 100644 --- a/host/dxwndhost.rc +++ b/host/dxwndhost.rc @@ -261,6 +261,7 @@ BEGIN CONTROL "use DLL Injection",IDC_STARTDEBUG,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,170,132,100,12 CONTROL "3D Wireframe",IDC_WIREFRAME,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,170,142,115,12 CONTROL "Remap Client Rect",IDC_CLIENTREMAPPING,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,170,112,115,10 + CONTROL "Hook all DLLs",IDC_HOOKDLLS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,152,124,12 END IDD_TAB_LOG DIALOGEX 0, 0, 300, 240 @@ -412,6 +413,7 @@ BEGIN CONTROL "Handle Exceptions",IDC_HANDLEEXCEPTIONS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,201,109,12 CONTROL "Limit available resources",IDC_LIMITRESOURCES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,212,109,12 CONTROL "Suppress IME",IDC_SUPPRESSIME,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,190,109,12 + CONTROL "Suppress d3d9 extensions",IDC_SUPPRESSD3DEXT,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,179,109,12 END IDD_TAB_GDI DIALOGEX 0, 0, 300, 240 diff --git a/host/dxwndhost.vs2008.suo b/host/dxwndhost.vs2008.suo index 7967bc478742a008c5731515b848a7de7ea2b4f1..f1eff0d4ea2aaafb4b1858414b5cf024d3101ebe 100644 GIT binary patch delta 9212 zcmeHNd3;qxmcFOnk{3wABY9a!LUOYpVF@N7EF#NGj0(sOilVZw$`Uako8*BgsHl+A z97I4|2G_BHAkVgK4H!`rX>r%q?vQqDWfaklGmf(KckZiTf`ZfY_Z)s-s_u7B)vfKE zI#rL*b1|VWV%7yIc1OwiE?TT_a7}TaJay`n{?L_9A^pAUrnrfBJ+=0e2?xn#Sypg* z%@X%uuP+LDXr1D%kCLqm+&*tMn7U~FW2-^>Wp`m!v|BG~J;dV$>tp(cy6E!j-8Db7 zKA=1vaIq1tF>aMwzkhv^H2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TZa2Y#Ll_y@QIaH&$%_D^2e8j$C+1zT73ZmzkLdg)`G!Vd2hx@q!rp=Q~zW{txeq;Z3u>i`p|YO7O|0w|61eK-yX<@mH%t_ z#ZAlRKOt81Lcu^^M7Hx>Onx!#_g-D$9MwgxG&REvN!*`~i~gU7+?ljCR4?C8x7sDl45ZM9`YSb5_f9p0ED^M6xx# diff --git a/host/dxwndhostView.cpp b/host/dxwndhostView.cpp index 4570906..f7c4cee 100644 --- a/host/dxwndhostView.cpp +++ b/host/dxwndhostView.cpp @@ -55,6 +55,9 @@ BEGIN_MESSAGE_MAP(CDxwndhostView, CListView) ON_COMMAND(ID_DXAPP_EXIT, OnExit) ON_WM_RBUTTONDOWN() ON_WM_DESTROY() + ON_WM_MOVE() + ON_WM_SIZE() + ON_WM_DESTROY() ON_COMMAND(ID_RUN, OnRun) ON_COMMAND(ID_TRAY_RESTORE, OnTrayRestore) ON_COMMAND(ID_VIEW_STATUS, OnViewStatus) @@ -98,22 +101,47 @@ CDxwndhostView::CDxwndhostView() EnumDisplaySettings(NULL, ENUM_CURRENT_SETTINGS, &this->InitDevMode); } +void CDxwndhostView::OnMove(int x, int y) +{ + CWnd::OnMove(x, y); + this->LastX=x; + this->LastY=y; +} + +void CDxwndhostView::OnSize(UINT nSize, int cx, int cy) +{ + this->LastCX=cx; + this->LastCY=cy; + // save x,y pos since OnMove is not working .... why? + RECT rect; + this->GetActiveWindow()->GetWindowRect(&rect); + this->LastX=rect.left; + this->LastY=rect.top; +} + void CDxwndhostView::SaveWinPos() { char val[32]; - RECT rect; + //RECT rect; // save window rect - //::GetWindowRect(::GetActiveWindow(), &rect); - this->GetActiveWindow()->GetWindowRect(&rect); - if((rect.top < 0) || (rect.bottom < 0) || (rect.left < 0) || (rect.right < 0)) return; - sprintf_s(val, sizeof(val), "%i", rect.left); + //this->GetActiveWindow()->GetWindowRect(&rect); + //if((rect.top < 0) || (rect.bottom < 0) || (rect.left < 0) || (rect.right < 0)) return; + //sprintf_s(val, sizeof(val), "%i", rect.left); + //WritePrivateProfileString("window", "posx", val, InitPath); + //sprintf_s(val, sizeof(val), "%i", rect.top); + //WritePrivateProfileString("window", "posy", val, InitPath); + //sprintf_s(val, sizeof(val), "%i", rect.right-rect.left); + //WritePrivateProfileString("window", "sizx", val, InitPath); + //sprintf_s(val, sizeof(val), "%i", rect.bottom-rect.top); + //WritePrivateProfileString("window", "sizy", val, InitPath); + sprintf_s(val, sizeof(val), "%i", this->LastX); WritePrivateProfileString("window", "posx", val, InitPath); - sprintf_s(val, sizeof(val), "%i", rect.top); + sprintf_s(val, sizeof(val), "%i", this->LastY); WritePrivateProfileString("window", "posy", val, InitPath); - sprintf_s(val, sizeof(val), "%i", rect.right-rect.left); + sprintf_s(val, sizeof(val), "%i", this->LastCX); WritePrivateProfileString("window", "sizx", val, InitPath); - sprintf_s(val, sizeof(val), "%i", rect.bottom-rect.top); + sprintf_s(val, sizeof(val), "%i", this->LastCY); WritePrivateProfileString("window", "sizy", val, InitPath); } @@ -250,6 +278,12 @@ CDxwndhostView::~CDxwndhostView() } } +void CDxwndhostView::OnDestroy() +{ + this->OnExit(); + exit(0); +} + void CDxwndhostView::OnExit() { // check for running apps .... @@ -287,7 +321,6 @@ void CDxwndhostView::OnInitialUpdate() LV_ITEM listitem; int i; char key[32]; - RECT rect; listcol.mask = LVCF_WIDTH; listcol.cx = 100; @@ -297,16 +330,6 @@ void CDxwndhostView::OnInitialUpdate() strcat_s(InitPath, sizeof(InitPath), "\\"); strcat_s(InitPath, sizeof(InitPath), m_ConfigFileName); - // restore last window pos - AfxGetApp()->m_pMainWnd->GetWindowRect(&rect); - rect.left = GetPrivateProfileInt("window", "posx", 50, InitPath); - rect.top = GetPrivateProfileInt("window", "posy", 50, InitPath); - rect.right = rect.left + GetPrivateProfileInt("window", "sizx", 320, InitPath); - rect.bottom = rect.top + GetPrivateProfileInt("window", "sizy", 200, InitPath); - AfxGetApp()->m_pMainWnd->MoveWindow(&rect, TRUE); - AfxGetApp()->m_pMainWnd->ShowWindow(SW_SHOW); - AfxGetApp()->m_pMainWnd->UpdateWindow(); - for(i = 0; i < MAXTARGETS; i ++){ sprintf_s(key, sizeof(key), "path%i", i); GetPrivateProfileString("target", key, "", TargetMaps[i].path, MAX_PATH, InitPath); @@ -421,6 +444,7 @@ void CDxwndhostView::OnModify() dlg.m_Title = TitleMaps[i].title; dlg.m_UnNotify = TargetMaps[i].flags & UNNOTIFY ? 1 : 0; dlg.m_Windowize = TargetMaps[i].flags2 & WINDOWIZE ? 1 : 0; + dlg.m_HookDLLs = TargetMaps[i].flags3 & HOOKDLLS ? 1 : 0; dlg.m_NoBanner = TargetMaps[i].flags2 & NOBANNER ? 1 : 0; dlg.m_StartDebug = TargetMaps[i].flags2 & STARTDEBUG ? 1 : 0; dlg.m_EmulateSurface = TargetMaps[i].flags & EMULATESURFACE ? 1 : 0; @@ -440,6 +464,7 @@ void CDxwndhostView::OnModify() dlg.m_HandleDC = TargetMaps[i].flags & HANDLEDC ? 1 : 0; dlg.m_HandleExceptions = TargetMaps[i].flags & HANDLEEXCEPTIONS ? 1 : 0; dlg.m_SuppressIME = TargetMaps[i].flags2 & SUPPRESSIME ? 1 : 0; + dlg.m_SuppressD3DExt = TargetMaps[i].flags3 & SUPPRESSD3DEXT ? 1 : 0; dlg.m_SetCompatibility = TargetMaps[i].flags2 & SETCOMPATIBILITY ? 1 : 0; dlg.m_LimitResources = TargetMaps[i].flags2 & LIMITRESOURCES ? 1 : 0; dlg.m_SaveLoad = TargetMaps[i].flags & SAVELOAD ? 1 : 0; @@ -519,6 +544,7 @@ void CDxwndhostView::OnModify() TargetMaps[i].tflags = 0; if(dlg.m_UnNotify) TargetMaps[i].flags |= UNNOTIFY; if(dlg.m_Windowize) TargetMaps[i].flags2 |= WINDOWIZE; + if(dlg.m_HookDLLs) TargetMaps[i].flags3 |= HOOKDLLS; if(dlg.m_NoBanner) TargetMaps[i].flags2 |= NOBANNER; if(dlg.m_StartDebug) TargetMaps[i].flags2 |= STARTDEBUG; if(dlg.m_NoEmulateSurface) { @@ -553,6 +579,7 @@ void CDxwndhostView::OnModify() if(dlg.m_HandleExceptions) TargetMaps[i].flags |= HANDLEEXCEPTIONS; if(dlg.m_LimitResources) TargetMaps[i].flags2 |= LIMITRESOURCES; if(dlg.m_SuppressIME) TargetMaps[i].flags2 |= SUPPRESSIME; + if(dlg.m_SuppressD3DExt) TargetMaps[i].flags3 |= SUPPRESSD3DEXT; if(dlg.m_SetCompatibility) TargetMaps[i].flags2 |= SETCOMPATIBILITY; if(dlg.m_SaveLoad) TargetMaps[i].flags |= SAVELOAD; if(dlg.m_SlowDown) TargetMaps[i].flags |= SLOWDOWN; @@ -822,6 +849,7 @@ void CDxwndhostView::OnAdd() TargetMaps[i].tflags = 0; if(dlg.m_UnNotify) TargetMaps[i].flags |= UNNOTIFY; if(dlg.m_Windowize) TargetMaps[i].flags2 |= WINDOWIZE; + if(dlg.m_HookDLLs) TargetMaps[i].flags3 |= HOOKDLLS; if(dlg.m_NoBanner) TargetMaps[i].flags2 |= NOBANNER; if(dlg.m_StartDebug) TargetMaps[i].flags2 |= STARTDEBUG; if(dlg.m_NoEmulateSurface) { @@ -855,6 +883,7 @@ void CDxwndhostView::OnAdd() if(dlg.m_HandleDC) TargetMaps[i].flags |= HANDLEDC; if(dlg.m_HandleExceptions) TargetMaps[i].flags |= HANDLEEXCEPTIONS; if(dlg.m_SuppressIME) TargetMaps[i].flags2 |= SUPPRESSIME; + if(dlg.m_SuppressD3DExt) TargetMaps[i].flags3 |= SUPPRESSD3DEXT; if(dlg.m_SetCompatibility) TargetMaps[i].flags2 |= SETCOMPATIBILITY; if(dlg.m_LimitResources) TargetMaps[i].flags2 |= LIMITRESOURCES; if(dlg.m_SaveLoad) TargetMaps[i].flags |= SAVELOAD; @@ -1128,7 +1157,6 @@ void CDxwndhostView::OnGoToTrayIcon() void CDxwndhostView::OnSaveFile() { - this->SaveWinPos(); if (this->isUpdated) if (MessageBoxEx(0, "Task list has changed.\n" diff --git a/host/dxwndhostView.h b/host/dxwndhostView.h index 3dfa6e3..a82236c 100644 --- a/host/dxwndhostView.h +++ b/host/dxwndhostView.h @@ -27,6 +27,7 @@ private: BOOL isUpdated; DEVMODE InitDevMode; CSystemTray SystemTray; + int LastX, LastY, LastCX, LastCY; // Attributes public: @@ -43,6 +44,9 @@ public: virtual BOOL PreCreateWindow(CREATESTRUCT& cs); protected: virtual void OnInitialUpdate(); // Called once after the initial construction. + virtual void OnMove(int, int); + virtual void OnSize(UINT, int, int); + virtual void OnDestroy(); //}}AFX_VIRTUAL // Implementation