ReactOS  0.4.14-dev-599-g2d4d3f5
dmemmgr.h
Go to the documentation of this file.
1 /*
2  * COPYRIGHT: This file is in the public domain.
3  * PROJECT: ReactOS kernel
4  * FILE: include/psdk/dmemmgr.h
5  * PURPOSE: Directx headers
6  * PROGRAMMER: Magnus Olsen (greatlrd)
7  *
8  */
9 
10 #ifndef __DMEMMGR_INCLUDED__
11 #define __DMEMMGR_INCLUDED__
12 
13 /* Helper macro to enable gcc's extension. */
14 #ifndef __GNU_EXTENSION
15 #ifdef __GNUC__
16 #define __GNU_EXTENSION __extension__
17 #else
18 #define __GNU_EXTENSION
19 #endif
20 #endif
21 
22 #ifdef __cplusplus
23 extern "C" {
24 #endif
25 
26 #ifndef __NTDDKCOMP__
27 
28 #ifndef FLATPTR_DEFINED
30 #define FLATPTR_DEFINED
31 #endif
32 
33 typedef struct _VIDMEM *LPVIDMEM;
34 
35 #else
36 
37 #ifndef FLATPTR_DEFINED
38 typedef ULONG_PTR FLATPTR;
39 #define FLATPTR_DEFINED
40 #endif
41 
42 typedef struct _VIDEOMEMORY *LPVIDMEM;
43 #endif
44 
45 #define SURFACEALIGN_DISCARDABLE 0x00000001
46 #define VMEMHEAP_LINEAR 0x00000001
47 #define VMEMHEAP_RECTANGULAR 0x00000002
48 #define VMEMHEAP_ALIGNMENT 0x00000004
49 
50 typedef struct _VMEML
51 {
52  struct _VMEML *next;
56 } VMEML, *LPVMEML, *LPLPVMEML;
57 
58 typedef struct _VMEMR
59 {
60  struct _VMEMR *next;
61  struct _VMEMR *prev;
62 
63  struct _VMEMR *pUp;
64  struct _VMEMR *pDown;
65  struct _VMEMR *pLeft;
66  struct _VMEMR *pRight;
76 } VMEMR, *LPVMEMR, *LPLPVMEMR;
77 
78 typedef struct _SURFACEALIGNMENT
79 {
80  __GNU_EXTENSION union
81  {
82  struct
83  {
88  } Linear;
89  struct
90  {
93  DWORD dwFlags;
95  } Rectangular;
96  };
98 
99 typedef struct _HEAPALIGNMENT
100 {
112 
113 typedef struct _VMEMHEAP
114 {
127 #ifndef IS_16
129 #endif
134 } VMEMHEAP, *LPVMEMHEAP;
135 
137 {
144 
145 #ifndef DD_GETHEAPALIGNMENTDATA_DECLARED
147 #define DD_GETHEAPALIGNMENTDATA_DECLARED
148 #endif
149 
150 extern void WINAPI VidMemFree( LPVMEMHEAP pvmh, FLATPTR ptr);
152 
153 extern FLATPTR WINAPI
155  LPVIDMEM lpVidMem,
156  DWORD dwWidth,
157  DWORD dwHeight,
158  LPSURFACEALIGNMENT lpAlignment ,
159  LPLONG lpNewPitch );
160 
161 
162 
163 
164 
165 
166 #ifdef __cplusplus
167 }
168 #endif
169 
170 #endif
struct _VMEMHEAP * LPVMEMHEAP
FLATPTR fpGARTLin
Definition: dmemmgr.h:120
Definition: dmemmgr.h:50
GLint GLint GLsizei width
Definition: gl.h:1546
DWORD dwTotalSize
Definition: dmemmgr.h:119
DWORD flags
Definition: dmemmgr.h:73
struct _VMEMR * pDown
Definition: dmemmgr.h:64
struct _VMEMR * LPVMEMR
BYTE * pAgpCommitMask
Definition: dmemmgr.h:132
FLATPTR WINAPI VidMemAlloc(LPVMEMHEAP pvmh, DWORD width, DWORD height)
struct _VMEMR * prev
Definition: dmemmgr.h:61
struct _VMEMR VMEMR
FLATPTR ptr
Definition: dmemmgr.h:53
DWORD dwFlags
Definition: dmemmgr.h:115
struct _VMEMHEAP VMEMHEAP
DDSCAPS ddsCaps
Definition: dmemmgr.h:102
struct _VMEMR * pUp
Definition: dmemmgr.h:63
struct _VMEML * LPVMEML
struct _SURFACEALIGNMENT::@2804::@2806 Linear
DWORD dwStartAlignment
Definition: dmemmgr.h:84
Definition: dmemmgr.h:58
struct _VIDMEM * LPVIDMEM
Definition: dmemmgr.h:33
DWORD cy
Definition: dmemmgr.h:72
#define __GNU_EXTENSION
Definition: dmemmgr.h:18
DWORD dwReserved2
Definition: dmemmgr.h:87
DWORD dwCommitedSize
Definition: dmemmgr.h:122
SURFACEALIGNMENT Overlay
Definition: dmemmgr.h:105
FLATPTR pBits
Definition: dmemmgr.h:74
uint32_t ULONG_PTR
Definition: typedefs.h:63
struct _VMEML * LPLPVMEML
SURFACEALIGNMENT Texture
Definition: dmemmgr.h:106
struct _VMEML VMEML
DWORD x
Definition: dmemmgr.h:69
unsigned int BOOL
Definition: ntddk_ex.h:94
DDSCAPSEX ddsCapsExAlt
Definition: dmemmgr.h:126
HEAPALIGNMENT Alignment
Definition: dmemmgr.h:124
DWORD dwAgpCommitMaskSize
Definition: dmemmgr.h:133
static PVOID ptr
Definition: dispmode.c:27
DWORD size
Definition: dmemmgr.h:54
SURFACEALIGNMENT ExecuteBuffer
Definition: dmemmgr.h:104
static const WCHAR dwHeight[]
Definition: provider.c:63
DWORD dwXAlignment
Definition: dmemmgr.h:91
SURFACEALIGNMENT ZBuffer
Definition: dmemmgr.h:107
struct _VMEML * next
Definition: dmemmgr.h:52
DWORD stride
Definition: dmemmgr.h:116
BOOL bDiscardable
Definition: dmemmgr.h:75
struct _HEAPALIGNMENT * LPHEAPALIGNMENT
DWORD size
Definition: dmemmgr.h:68
ULONG_PTR FLATPTR
Definition: ddrawint.h:76
DD_GETHEAPALIGNMENTDATA * PDD_GETHEAPALIGNMENTDATA
Definition: dmemmgr.h:146
LONG HRESULT
Definition: typedefs.h:77
struct _SURFACEALIGNMENT * LPSURFACEALIGNMENT
#define WINAPI
Definition: msvc.h:6
unsigned long DWORD
Definition: ntddk_ex.h:95
HANDLE hdevAGP
Definition: dmemmgr.h:130
DWORD dwReserved
Definition: dmemmgr.h:103
FLATPTR fpGARTDev
Definition: dmemmgr.h:121
struct _VMEMR * pRight
Definition: dmemmgr.h:66
struct _DD_GETHEAPALIGNMENTDATA DD_GETHEAPALIGNMENTDATA
unsigned char BYTE
Definition: mem.h:68
DWORD dwYAlignment
Definition: dmemmgr.h:92
BOOL bDiscardable
Definition: dmemmgr.h:55
SURFACEALIGNMENT Offscreen
Definition: dmemmgr.h:109
FLATPTR WINAPI HeapVidMemAllocAligned(LPVIDMEM lpVidMem, DWORD dwWidth, DWORD dwHeight, LPSURFACEALIGNMENT lpAlignment, LPLONG lpNewPitch)
Definition: eng.c:20
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
LPVOID allocList
Definition: dmemmgr.h:118
DDSCAPSEX ddsCapsEx
Definition: dmemmgr.h:125
LPVOID freeList
Definition: dmemmgr.h:117
int32_t * LPLONG
Definition: typedefs.h:56
DWORD dwCoalesceCount
Definition: dmemmgr.h:123
ULONG_PTR FLATPTR
Definition: dmemmgr.h:29
struct _VMEMR * next
Definition: dmemmgr.h:60
struct _HEAPALIGNMENT HEAPALIGNMENT
DWORD dwSize
Definition: dmemmgr.h:101
struct _VMEMR * LPLPVMEMR
struct _SURFACEALIGNMENT SURFACEALIGNMENT
SURFACEALIGNMENT AlphaBuffer
Definition: dmemmgr.h:108
void WINAPI VidMemFree(LPVMEMHEAP pvmh, FLATPTR ptr)
Definition: eng.c:43
DWORD cx
Definition: dmemmgr.h:71
LPVOID pvPhysRsrv
Definition: dmemmgr.h:131
HEAPALIGNMENT Alignment
Definition: dmemmgr.h:142
struct _VMEMR * pLeft
Definition: dmemmgr.h:65
struct _SURFACEALIGNMENT::@2804::@2807 Rectangular
LARGE_INTEGER liPhysAGPBase
Definition: dmemmgr.h:128
FLATPTR ptr
Definition: dmemmgr.h:67
static const WCHAR dwWidth[]
Definition: provider.c:62
DWORD dwPitchAlignment
Definition: dmemmgr.h:85
SURFACEALIGNMENT FlipTarget
Definition: dmemmgr.h:110
DWORD y
Definition: dmemmgr.h:70