Author: gbrunmar
Date: Sun Feb 17 16:34:59 2008
New Revision: 32401
URL:
http://svn.reactos.org/svn/reactos?rev=32401&view=rev
Log:
* Updated d3d headers to make it possible to include both d3d and d3d9 at the same time.
* Updated d3dhal.h to support DirectX 9
* Fixed broken d3dnthal.h
* Fixed missing structures in d3d8thk.h
Modified:
trunk/reactos/include/ddk/d3dhal.h
trunk/reactos/include/ddk/d3dnthal.h
trunk/reactos/include/ddk/ddrawi.h
trunk/reactos/include/ddk/ddrawint.h
trunk/reactos/include/psdk/d3d.h
trunk/reactos/include/psdk/d3d9types.h
trunk/reactos/include/psdk/d3dtypes.h
trunk/reactos/include/reactos/dll/directx/d3d8thk.h
Modified: trunk/reactos/include/ddk/d3dhal.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/d3dhal.h?rev=3…
==============================================================================
--- trunk/reactos/include/ddk/d3dhal.h (original)
+++ trunk/reactos/include/ddk/d3dhal.h Sun Feb 17 16:34:59 2008
@@ -26,7 +26,25 @@
extern "C" {
#endif
+#include <ddraw.h>
+#include <d3dtypes.h>
+#include <d3dcaps.h>
#include <d3d.h>
+
+#if (DIRECT3D_VERSION >= 0x0900)
+#include <d3d9.h>
+#endif
+
+#ifndef DDRAWI_DIRECTDRAW_DEFINED
+typedef struct _DDRAWI_DIRECTDRAW_GBL FAR *LPDDRAWI_DIRECTDRAW_GBL;
+typedef struct _DDRAWI_DIRECTDRAW_LCL FAR *LPDDRAWI_DIRECTDRAW_LCL;
+#define DDRAWI_DIRECTDRAW_DEFINED
+#endif
+
+#ifndef DDRAWI_DDRAWSURFACE_DEFINED
+typedef struct _DDRAWI_DDRAWSURFACE_LCL FAR *LPDDRAWI_DDRAWSURFACE_LCL;
+#define DDRAWI_DDRAWSURFACE_DEFINED
+#endif
#define D3DERR_COMMAND_UNPARSED 0x88760BB8;
@@ -579,6 +597,155 @@
DWORD dwLOD;
} D3DHAL_DP2SETTEXLOD,*LPD3DHAL_DP2SETTEXLOD;
+
+#if (DIRECT3D_VERSION >= 0x0900)
+
+#define DX9_DDI_VERSION 4
+
+#ifndef D3DVTXPCAPS_NO_VSDT_UBYTE4
+#define D3DVTXPCAPS_NO_VSDT_UBYTE4 0x00000080
+#endif
+
+#define D3DPMISCCAPS_LINEPATTERNREP 0x00000004
+
+#define D3DDEVCAPS_HWVERTEXBUFFER 0x02000000
+#define D3DDEVCAPS_HWINDEXBUFFER 0x04000000
+#define D3DDEVCAPS_SUBVOLUMELOCK 0x08000000
+
+#ifndef D3DPMISCCAPS_FOGINFVF
+#define D3DPMISCCAPS_FOGINFVF 0x00002000
+#endif
+
+#ifndef D3DFVF_FOG
+#define D3DFVF_FOG 0x00002000
+#endif
+
+typedef struct _DD_GETDRIVERINFO2DATA
+{
+ DWORD dwReserved;
+ DWORD dwMagic;
+ DWORD dwType;
+ DWORD dwExpectedSize;
+} DD_GETDRIVERINFO2DATA;
+
+/**
+ * A driver must check DD_GETDRIVERINFO2DATA.dwHeight for
+ * D3DGDI2_MAGIC to see if the passed GUID is GUID_GetDriverInfo2
+ * or a GUID_DDStereoMode.
+ */
+#define GUID_GetDriverInfo2 GUID_DDStereoMode
+
+/**
+ * Magic number used in DD_GETDRIVERINFO2DATA.dwHeight when
+ * GUID_GetDriverInfo2/GUID_DDStereoMode is specified in a
+ * GetDriverInfo call.
+ */
+#define D3DGDI2_MAGIC 0xFFFFFFFF
+
+#define D3DGDI2_TYPE_GETD3DCAPS8 0x00000001
+#define D3DGDI2_TYPE_GETFORMATCOUNT 0x00000002
+#define D3DGDI2_TYPE_GETFORMAT 0x00000003
+#define D3DGDI2_TYPE_DXVERSION 0x00000004 /* Make driver aware of
currently used DirectX version */
+#define D3DGDI2_TYPE_GETD3DCAPS9 0x00000010
+#define D3DGDI2_TYPE_GETEXTENDEDMODECOUNT 0x00000011
+#define D3DGDI2_TYPE_GETEXTENDEDMODE 0x00000012
+#define D3DGDI2_TYPE_GETADAPTERGROUP 0x00000013
+#define D3DGDI2_TYPE_GETMULTISAMPLEQUALITYLEVELS 0x00000016
+#define D3DGDI2_TYPE_DEFERRED_AGP_AWARE 0x00000018
+#define D3DGDI2_TYPE_FREE_DEFERRED_AGP 0x00000019
+#define D3DGDI2_TYPE_DEFER_AGP_FREES 0x00000020
+#define D3DGDI2_TYPE_GETD3DQUERYCOUNT 0x00000021
+#define D3DGDI2_TYPE_GETD3DQUERY 0x00000022
+#define D3DGDI2_TYPE_GETDDIVERSION 0x00000023 /* Returns
DX9_DDI_VERSION, used to check which DDK version the driver is compiled against */
+
+typedef struct _DD_GETFORMATCOUNTDATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ DWORD dwFormatCount;
+ DWORD dwReserved;
+} DD_GETFORMATCOUNTDATA;
+
+typedef struct _DD_GETFORMATDATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ DWORD dwFormatIndex;
+ DDPIXELFORMAT format;
+} DD_GETFORMATDATA;
+
+typedef struct _DD_DXVERSION
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ DWORD dwDXVersion;
+ DWORD dwReserved;
+} DD_DXVERSION;
+
+typedef struct _DD_DEFERRED_AGP_AWARE_DATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+} DD_DEFERRED_AGP_AWARE_DATA;
+
+typedef struct _DD_FREE_DEFERRED_AGP_DATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ DWORD dwProcessId;
+} DD_FREE_DEFERRED_AGP_DATA;
+
+typedef struct _DD_GETEXTENDEDMODECOUNTDATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ DWORD dwModeCount;
+ DWORD dwReserved;
+} DD_GETEXTENDEDMODECOUNTDATA;
+
+typedef struct _DD_GETEXTENDEDMODEDATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ DWORD dwModeIndex;
+ D3DDISPLAYMODE mode;
+} DD_GETEXTENDEDMODEDATA;
+
+typedef struct _DD_GETADAPTERGROUPDATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ ULONG_PTR ulUniqueAdapterGroupId;
+ DWORD dwReserved1;
+ DWORD dwReserved2;
+} DD_GETADAPTERGROUPDATA;
+
+typedef struct _DD_MULTISAMPLEQUALITYLEVELSDATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ D3DFORMAT Format;
+ BOOL bFlip : 1;
+ D3DMULTISAMPLE_TYPE MSType : 31;
+ DWORD QualityLevels;
+} DD_MULTISAMPLEQUALITYLEVELSDATA;
+
+typedef struct _DD_GETD3DQUERYCOUNTDATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ DWORD dwNumQueries;
+} DD_GETD3DQUERYCOUNTDATA;
+
+typedef struct _DD_GETD3DQUERYDATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ union
+ {
+ DWORD dwQueryIndex;
+ D3DQUERYTYPE QueryType;
+ };
+} DD_GETD3DQUERYDATA;
+
+typedef struct _DD_GETDDIVERSIONDATA
+{
+ DD_GETDRIVERINFO2DATA gdi2;
+ DWORD dwDXVersion;
+ DWORD dwDDIVersion;
+} DD_GETDDIVERSIONDATA;
+
+#endif /* (DIRECT3D_VERSION >= 0x0900) */
+
#ifdef __cplusplus
} /* extern "C" */
#endif
Modified: trunk/reactos/include/ddk/d3dnthal.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/d3dnthal.h?rev…
==============================================================================
--- trunk/reactos/include/ddk/d3dnthal.h (original)
+++ trunk/reactos/include/ddk/d3dnthal.h Sun Feb 17 16:34:59 2008
@@ -167,7 +167,18 @@
ULONG_PTR dwReserved9;
} D3DNTHAL_CALLBACKS, *LPD3DNTHAL_CALLBACKS;
+
+typedef struct _D3DNTHAL_SETRENDERTARGETDATA
+{
+ ULONG_PTR dwhContext;
+ PDD_SURFACE_LOCAL lpDDS;
+ PDD_SURFACE_LOCAL lpDDSZ;
+ HRESULT ddrval;
+} D3DNTHAL_SETRENDERTARGETDATA;
+typedef D3DNTHAL_SETRENDERTARGETDATA *LPD3DNTHAL_SETRENDERTARGETDATA;
+
typedef DWORD (APIENTRY *LPD3DNTHAL_SETRENDERTARGETCB)(LPD3DNTHAL_SETRENDERTARGETDATA);
+
typedef struct _D3DNTHAL_CALLBACKS2
{
@@ -181,6 +192,55 @@
LPVOID dwReserved4;
} D3DNTHAL_CALLBACKS2, *LPD3DNTHAL_CALLBACKS2;
+
+typedef struct _D3DNTHAL_CLEAR2DATA
+{
+ ULONG_PTR dwhContext;
+ DWORD dwFlags;
+ DWORD dwFillColor;
+ D3DVALUE dvFillDepth;
+ DWORD dwFillStencil;
+ LPD3DRECT lpRects;
+ DWORD dwNumRects;
+ HRESULT ddrval;
+} D3DNTHAL_CLEAR2DATA;
+typedef D3DNTHAL_CLEAR2DATA FAR *LPD3DNTHAL_CLEAR2DATA;
+
+typedef struct _D3DNTHAL_VALIDATETEXTURESTAGESTATEDATA
+{
+ ULONG_PTR dwhContext;
+ DWORD dwFlags;
+ ULONG_PTR dwReserved;
+ DWORD dwNumPasses;
+ HRESULT ddrval;
+} D3DNTHAL_VALIDATETEXTURESTAGESTATEDATA, FAR *LPD3DNTHAL_VALIDATETEXTURESTAGESTATEDATA;
+
+typedef struct _D3DNTHAL_DRAWPRIMITIVES2DATA
+{
+ ULONG_PTR dwhContext;
+ DWORD dwFlags;
+ DWORD dwVertexType;
+ PDD_SURFACE_LOCAL lpDDCommands;
+ DWORD dwCommandOffset;
+ DWORD dwCommandLength;
+ union
+ {
+ PDD_SURFACE_LOCAL lpDDVertex;
+ LPVOID lpVertices;
+ };
+ DWORD dwVertexOffset;
+ DWORD dwVertexLength;
+ DWORD dwReqVertexBufSize;
+ DWORD dwReqCommandBufSize;
+ LPDWORD lpdwRStates;
+ union
+ {
+ DWORD dwVertexSize;
+ HRESULT ddrval;
+ };
+ DWORD dwErrorOffset;
+} D3DNTHAL_DRAWPRIMITIVES2DATA, FAR *LPD3DNTHAL_DRAWPRIMITIVES2DATA;
+
typedef DWORD (APIENTRY *LPD3DNTHAL_CLEAR2CB)(LPD3DNTHAL_CLEAR2DATA);
typedef DWORD (APIENTRY
*LPD3DNTHAL_VALIDATETEXTURESTAGESTATECB)(LPD3DNTHAL_VALIDATETEXTURESTAGESTATEDATA);
typedef DWORD (APIENTRY *LPD3DNTHAL_DRAWPRIMITIVES2CB)(LPD3DNTHAL_DRAWPRIMITIVES2DATA);
@@ -196,42 +256,6 @@
LPD3DNTHAL_DRAWPRIMITIVES2CB DrawPrimitives2;
} D3DNTHAL_CALLBACKS3, *LPD3DNTHAL_CALLBACKS3;
-
-typedef struct _D3DNTHAL_VALIDATETEXTURESTAGESTATEDATA
-{
- ULONG_PTR dwhContext;
- DWORD dwFlags;
- ULONG_PTR dwReserved;
- DWORD dwNumPasses;
- HRESULT ddrval;
-} D3DNTHAL_VALIDATETEXTURESTAGESTATEDATA, FAR *LPD3DNTHAL_VALIDATETEXTURESTAGESTATEDATA;
-
-typedef struct _D3DNTHAL_DRAWPRIMITIVES2DATA
-{
- ULONG_PTR dwhContext;
- DWORD dwFlags;
- DWORD dwVertexType;
- PDD_SURFACE_LOCAL lpDDCommands;
- DWORD dwCommandOffset;
- DWORD dwCommandLength;
- union
- {
- PDD_SURFACE_LOCAL lpDDVertex;
- LPVOID lpVertices;
- };
- DWORD dwVertexOffset;
- DWORD dwVertexLength;
- DWORD dwReqVertexBufSize;
- DWORD dwReqCommandBufSize;
- LPDWORD lpdwRStates;
- union
- {
- DWORD dwVertexSize;
- HRESULT ddrval;
- };
- DWORD dwErrorOffset;
-} D3DNTHAL_DRAWPRIMITIVES2DATA, FAR *LPD3DNTHAL_DRAWPRIMITIVES2DATA;
-
#ifdef __cplusplus
} /* extern "C" */
#endif
Modified: trunk/reactos/include/ddk/ddrawi.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/ddrawi.h?rev=3…
==============================================================================
--- trunk/reactos/include/ddk/ddrawi.h (original)
+++ trunk/reactos/include/ddk/ddrawi.h Sun Feb 17 16:34:59 2008
@@ -129,10 +129,20 @@
/* predeclare some structures */
typedef struct _DDHALINFO *LPDDHALINFO;
typedef struct _DDRAWI_DIRECTDRAW_INT *LPDDRAWI_DIRECTDRAW_INT;
+
+#ifndef DDRAWI_DIRECTDRAW_DEFINED
typedef struct _DDRAWI_DIRECTDRAW_LCL *LPDDRAWI_DIRECTDRAW_LCL;
typedef struct _DDRAWI_DIRECTDRAW_GBL *LPDDRAWI_DIRECTDRAW_GBL;
+#define DDRAWI_DIRECTDRAW_DEFINED
+#endif
+
typedef struct _DDRAWI_DDRAWSURFACE_INT *LPDDRAWI_DDRAWSURFACE_INT;
+
+#ifndef DDRAWI_DDRAWSURFACE_DEFINED
typedef struct _DDRAWI_DDRAWSURFACE_LCL *LPDDRAWI_DDRAWSURFACE_LCL;
+#define DDRAWI_DDRAWSURFACE_DEFINED
+#endif
+
typedef struct _DDRAWI_DDRAWSURFACE_GBL *LPDDRAWI_DDRAWSURFACE_GBL;
typedef struct _DDRAWI_DDRAWSURFACE_MORE *LPDDRAWI_DDRAWSURFACE_MORE;
typedef struct _DDRAWI_DDRAWSURFACE_GBL_MORE *LPDDRAWI_DDRAWSURFACE_GBL_MORE;
Modified: trunk/reactos/include/ddk/ddrawint.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/ddrawint.h?rev…
==============================================================================
--- trunk/reactos/include/ddk/ddrawint.h (original)
+++ trunk/reactos/include/ddk/ddrawint.h Sun Feb 17 16:34:59 2008
@@ -1451,15 +1451,6 @@
#define DDRAWI_VPORTGETCOLOR 0x0001
#define DDRAWI_VPORTSETCOLOR 0x0002
-#ifndef __DDRAWI_INCLUDED__
-#define VIDMEM_ISLINEAR 0x00000001
-#define VIDMEM_ISRECTANGULAR 0x00000002
-#define VIDMEM_ISHEAP 0x00000004
-#define VIDMEM_ISNONLOCAL 0x00000008
-#define VIDMEM_ISWC 0x00000010
-#define VIDMEM_ISDISABLED 0x00000020
-#endif
-
#ifdef __cplusplus
} /* extern "C" */
Modified: trunk/reactos/include/psdk/d3d.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/d3d.h?rev=324…
==============================================================================
--- trunk/reactos/include/psdk/d3d.h (original)
+++ trunk/reactos/include/psdk/d3d.h Sun Feb 17 16:34:59 2008
@@ -18,6 +18,12 @@
#ifndef __WINE_D3D_H
#define __WINE_D3D_H
+
+#ifndef DIRECT3D_VERSION
+#define DIRECT3D_VERSION 0x0700
+#endif
+
+#if (DIRECT3D_VERSION < 0x0800)
#include <stdlib.h>
@@ -1528,4 +1534,5 @@
#define IDirect3DVertexBuffer7_ProcessVerticesStrided(p,a,b,c,d,e,f,g)
(p)->ProcessVerticesStrided(a,b,c,d,e,f,g)
#endif
+#endif /* (DIRECT3D_VERSION < 0x0800) */
#endif /* __WINE_D3D_H */
Modified: trunk/reactos/include/psdk/d3d9types.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/d3d9types.h?r…
==============================================================================
--- trunk/reactos/include/psdk/d3d9types.h (original)
+++ trunk/reactos/include/psdk/d3d9types.h Sun Feb 17 16:34:59 2008
@@ -875,7 +875,7 @@
D3DMULTISAMPLE_15_SAMPLES = 15,
D3DMULTISAMPLE_16_SAMPLES = 16,
- D3DMULTISAMPLE_FORCE_DWORD = 0xffffffff
+ D3DMULTISAMPLE_FORCE_DWORD = 0x7fffffff
} D3DMULTISAMPLE_TYPE;
#if 0
Modified: trunk/reactos/include/psdk/d3dtypes.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/d3dtypes.h?re…
==============================================================================
--- trunk/reactos/include/psdk/d3dtypes.h (original)
+++ trunk/reactos/include/psdk/d3dtypes.h Sun Feb 17 16:34:59 2008
@@ -147,6 +147,7 @@
typedef DWORD D3DTEXTUREHANDLE, *LPD3DTEXTUREHANDLE;
typedef DWORD D3DMATRIXHANDLE, *LPD3DMATRIXHANDLE;
+#ifndef D3DCOLORVALUE_DEFINED
typedef struct _D3DCOLORVALUE {
union {
D3DVALUE r;
@@ -165,7 +166,9 @@
D3DVALUE dvA;
} DUMMYUNIONNAME4;
} D3DCOLORVALUE,*LPD3DCOLORVALUE;
-
+#endif
+
+#ifndef D3DRECT_DEFINED
typedef struct _D3DRECT {
union {
LONG x1;
@@ -183,7 +186,9 @@
LONG y2;
LONG lY2;
} DUMMYUNIONNAME4;
-} D3DRECT, *LPD3DRECT;
+} D3DRECT;
+#endif
+typedef struct _D3DRECT *LPD3DRECT;
typedef struct _D3DHVERTEX {
DWORD dwFlags;
@@ -324,6 +329,7 @@
#endif
} D3DVERTEX, *LPD3DVERTEX;
+#ifndef D3DMATRIX_DEFINED
typedef struct _D3DMATRIX {
D3DVALUE _11, _12, _13, _14;
D3DVALUE _21, _22, _23, _24;
@@ -339,6 +345,7 @@
{ return ((const D3DVALUE [4][4])&_11)[r][c]; }
#endif
} D3DMATRIX, *LPD3DMATRIX;
+#endif
#if defined(__cplusplus) && defined(D3D_OVERLOADS)
#include <d3dvec.inl>
@@ -534,6 +541,8 @@
} DUMMYUNIONNAME4;
} D3DMATERIAL7, *LPD3DMATERIAL7;
+#if (DIRECT3D_VERSION < 0x0800)
+
typedef enum {
D3DLIGHT_POINT = 1,
D3DLIGHT_SPOT = 2,
@@ -542,6 +551,8 @@
D3DLIGHT_GLSPOT = 5,
D3DLIGHT_FORCE_DWORD = 0x7fffffff
} D3DLIGHTTYPE;
+
+#endif
typedef struct _D3DLIGHT {
DWORD dwSize;
@@ -609,10 +620,17 @@
typedef DWORD D3DCOLORMODEL;
-
+#ifndef D3DCLEAR_TARGET
#define D3DCLEAR_TARGET 0x00000001
+#endif
+
+#ifndef D3DCLEAR_ZBUFFER
#define D3DCLEAR_ZBUFFER 0x00000002
+#endif
+
+#ifndef D3DCLEAR_STENCIL
#define D3DCLEAR_STENCIL 0x00000004
+#endif
typedef enum _D3DOPCODE {
D3DOP_POINT = 1,
@@ -651,6 +669,8 @@
D3DVALUE dvZ;
} D3DPICKRECORD, *LPD3DPICKRECORD;
+#if (DIRECT3D_VERSION < 0x0800)
+
typedef enum {
D3DSHADE_FLAT = 1,
D3DSHADE_GOURAUD = 2,
@@ -669,6 +689,8 @@
WORD wRepeatFactor;
WORD wLinePattern;
} D3DLINEPATTERN;
+
+#endif /* (DIRECT3D_VERSION < 0x0800) */
typedef enum {
D3DFILTER_NEAREST = 1,
@@ -679,6 +701,8 @@
D3DFILTER_LINEARMIPLINEAR = 6,
D3DFILTER_FORCE_DWORD = 0x7fffffff
} D3DTEXTUREFILTER;
+
+#if (DIRECT3D_VERSION < 0x0800)
typedef enum {
D3DBLEND_ZERO = 1,
@@ -697,6 +721,9 @@
D3DBLEND_FORCE_DWORD = 0x7fffffff
} D3DBLEND;
+#endif /* (DIRECT3D_VERSION < 0x0800) */
+
+
typedef enum {
D3DTBLEND_DECAL = 1,
D3DTBLEND_MODULATE = 2,
@@ -709,6 +736,9 @@
D3DTBLEND_FORCE_DWORD = 0x7fffffff
} D3DTEXTUREBLEND;
+
+#if (DIRECT3D_VERSION < 0x0800)
+
typedef enum _D3DTEXTUREADDRESS {
D3DTADDRESS_WRAP = 1,
D3DTADDRESS_MIRROR = 2,
@@ -763,6 +793,8 @@
D3DZB_FORCE_DWORD = 0x7fffffff
} D3DZBUFFERTYPE;
+#endif /* (DIRECT3D_VERSION < 0x0800) */
+
typedef enum _D3DANTIALIASMODE {
D3DANTIALIAS_NONE = 0,
D3DANTIALIAS_SORTDEPENDENT = 1,
@@ -776,6 +808,8 @@
D3DVT_TLVERTEX = 3,
D3DVT_FORCE_DWORD = 0x7fffffff
} D3DVERTEXTYPE;
+
+#if (DIRECT3D_VERSION < 0x0800)
typedef enum {
D3DPT_POINTLIST = 1,
@@ -787,9 +821,13 @@
D3DPT_FORCE_DWORD = 0x7fffffff
} D3DPRIMITIVETYPE;
+#endif /* (DIRECT3D_VERSION < 0x0800) */
+
#define D3DSTATE_OVERRIDE_BIAS 256
#define D3DSTATE_OVERRIDE(type) (D3DRENDERSTATETYPE)(((DWORD) (type) +
D3DSTATE_OVERRIDE_BIAS))
+
+#if (DIRECT3D_VERSION < 0x0800)
typedef enum _D3DTRANSFORMSTATETYPE {
D3DTRANSFORMSTATE_WORLD = 1,
@@ -809,6 +847,8 @@
D3DTRANSFORMSTATE_FORCE_DWORD = 0x7fffffff
} D3DTRANSFORMSTATETYPE;
+#endif /* (DIRECT3D_VERSION < 0x0800) */
+
typedef enum {
D3DLIGHTSTATE_MATERIAL = 1,
D3DLIGHTSTATE_AMBIENT = 2,
@@ -820,6 +860,8 @@
D3DLIGHTSTATE_COLORVERTEX = 8,
D3DLIGHTSTATE_FORCE_DWORD = 0x7fffffff
} D3DLIGHTSTATETYPE;
+
+#if (DIRECT3D_VERSION < 0x0800)
typedef enum {
D3DRENDERSTATE_TEXTUREHANDLE = 1,
@@ -966,6 +1008,8 @@
#define D3DWRAPCOORD_2 0x00000004L
#define D3DWRAPCOORD_3 0x00000008L
+#endif /* (DIRECT3D_VERSION < 0x0800) */
+
#define D3DRENDERSTATE_STIPPLEPATTERN(y) (D3DRENDERSTATE_STIPPLEPATTERN00 + (y))
typedef struct _D3DSTATE {
@@ -1006,6 +1050,8 @@
#define D3DPROCESSVERTICES_UPDATEEXTENTS 0x00000008L
#define D3DPROCESSVERTICES_NOCOLOR 0x00000010L
+
+#if (DIRECT3D_VERSION < 0x0800)
typedef enum _D3DTEXTURESTAGESTATETYPE
{
@@ -1085,6 +1131,8 @@
#define D3DTA_COMPLEMENT 0x00000010
#define D3DTA_ALPHAREPLICATE 0x00000020
+#endif /* (DIRECT3D_VERSION < 0x0800) */
+
typedef enum _D3DTEXTUREMAGFILTER
{
D3DTFG_POINT = 1,
@@ -1230,6 +1278,8 @@
#define D3DVOP_TRANSFORM (1 << 0)
#define D3DVOP_CLIP (1 << 2)
#define D3DVOP_EXTENTS (1 << 3)
+
+#if (DIRECT3D_VERSION < 0x0800)
#define D3DMAXNUMVERTICES ((1<<16) - 1)
@@ -1264,6 +1314,8 @@
#define D3DFVF_TEX8 0x800
#define D3DFVF_RESERVED2 0xf000
+
+#endif /* (DIRECT3D_VERSION < 0x0800) */
#define D3DFVF_VERTEX ( D3DFVF_XYZ | D3DFVF_NORMAL | D3DFVF_TEX1 )
#define D3DFVF_LVERTEX ( D3DFVF_XYZ | D3DFVF_RESERVED1 | D3DFVF_DIFFUSE | \
@@ -1316,6 +1368,9 @@
#define D3DVIS_MASK_NEAR (3 << 10)
#define D3DVIS_MASK_FAR (3 << 12)
+
+#if (DIRECT3D_VERSION < 0x0800)
+
#define D3DDEVINFOID_TEXTUREMANAGER 1
#define D3DDEVINFOID_D3DTEXTUREMANAGER 2
#define D3DDEVINFOID_TEXTURING 3
@@ -1356,4 +1411,6 @@
#define D3DFVF_TEXCOORDSIZE4(CoordIndex) (D3DFVF_TEXTUREFORMAT4 << (CoordIndex*2 +
16))
#define D3DFVF_TEXCOORDSIZE1(CoordIndex) (D3DFVF_TEXTUREFORMAT1 << (CoordIndex*2 +
16))
-#endif
+#endif /* (DIRECT3D_VERSION < 0x0800) */
+
+#endif
Modified: trunk/reactos/include/reactos/dll/directx/d3d8thk.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/dll/direct…
==============================================================================
--- trunk/reactos/include/reactos/dll/directx/d3d8thk.h (original)
+++ trunk/reactos/include/reactos/dll/directx/d3d8thk.h Sun Feb 17 16:34:59 2008
@@ -9,40 +9,26 @@
extern "C" {
#endif
-/* FIXME missing PD3DNTHAL_CONTEXTCREATEDATA
BOOL STDCALL OsThunkD3dContextCreate(
HANDLE hDirectDrawLocal,
HANDLE hSurfColor,
HANDLE hSurfZ,
- PD3DNTHAL_CONTEXTCREATEDATA pdcci
+ LPD3DNTHAL_CONTEXTDESTROYDATA pdcci
);
DWORD STDCALL OsThunkD3dContextDestroy(
- PD3DNTHAL_CONTEXTDESTROYDATA pContextDestroyData
-);
-
-DWORD STDCALL
- OsThunkD3dContextDestroyAll(PD3DNTHAL_CONTEXTDESTROYDATA pContextDestroyData);
-*/
-
-DWORD STDCALL OsThunkD3dContextDestroyAll(LPVOID);
-
-/* FIXME PD3DNTHAL_DRAWPRIMITIVES2DATA, PD3DNTHAL_VALIDATETEXTURESTAGESTATEDATA missing
-DWORD STDCALL OsThunkD3dDrawPrimitives2(
- HANDLE hCmdBuf,
- HANDLE hVBuf,
- PD3DNTHAL_DRAWPRIMITIVES2DATA pded,
- FLATPTR *pfpVidMemCmd,
- DWORD *pdwSizeCmd,
- FLATPTR *pfpVidMemVtx,
- DWORD *pdwSizeVtx
+ LPD3DNTHAL_CONTEXTDESTROYDATA pContextDestroyData
+);
+
+DWORD STDCALL OsThunkD3dContextDestroyAll(
+ LPD3DNTHAL_CONTEXTDESTROYDATA pContextDestroyData
);
DWORD STDCALL OsThunkD3dValidateTextureStageState(
- PD3DNTHAL_VALIDATETEXTURESTAGESTATEDATA pData
-);
-*/
+ LPD3DNTHAL_VALIDATETEXTURESTAGESTATEDATA pData
+);
+
DWORD STDCALL OsThunkDdAddAttachedSurface(
HANDLE hSurface,