Merge MPC-HC code(01b8dbf34d6a486fa1cd02d7a123249fec1e4160) [PART 2] (HdmvSub)
[xy_vsfilter.git] / include / dx / d3drm.h
blob95594b8a631c75ecf35cf9d57159deaaeeb696e7
1 /*==========================================================================;
3 * Copyright (c) Microsoft Corporation. All rights reserved.
5 * File: d3drm.h
6 * Content: Direct3DRM include file
8 ***************************************************************************/
10 #ifndef __D3DRM_H__
11 #define __D3DRM_H__
13 #include "ddraw.h"
15 #ifdef __cplusplus
16 struct IDirect3DRM;
17 #endif
19 typedef struct IDirect3DRM *LPDIRECT3DRM;
21 #include "d3drmobj.h"
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
28 DEFINE_GUID(IID_IDirect3DRM, 0x2bc49361, 0x8327, 0x11cf, 0xac, 0x4a, 0x0, 0x0, 0xc0, 0x38, 0x25, 0xa1);
29 DEFINE_GUID(IID_IDirect3DRM2, 0x4516ecc8, 0x8f20, 0x11d0, 0x9b, 0x6d, 0x00, 0x00, 0xc0, 0x78, 0x1b, 0xc3);
30 DEFINE_GUID(IID_IDirect3DRM3, 0x4516ec83, 0x8f20, 0x11d0, 0x9b, 0x6d, 0x00, 0x00, 0xc0, 0x78, 0x1b, 0xc3);
31 WIN_TYPES(IDirect3DRM, DIRECT3DRM);
32 WIN_TYPES(IDirect3DRM2, DIRECT3DRM2);
33 WIN_TYPES(IDirect3DRM3, DIRECT3DRM3);
36 * Direct3DRM Object Class (for CoCreateInstance())
38 DEFINE_GUID(CLSID_CDirect3DRM, 0x4516ec41, 0x8f20, 0x11d0, 0x9b, 0x6d, 0x00, 0x00, 0xc0, 0x78, 0x1b, 0xc3);
41 /* Create a Direct3DRM API */
42 STDAPI Direct3DRMCreate(LPDIRECT3DRM FAR *lplpDirect3DRM);
44 #undef INTERFACE
45 #define INTERFACE IDirect3DRM
47 DECLARE_INTERFACE_(IDirect3DRM, IUnknown)
49 IUNKNOWN_METHODS(PURE);
51 STDMETHOD(CreateObject)
52 (THIS_ REFCLSID rclsid, LPUNKNOWN pUnkOuter, REFIID riid, LPVOID FAR* ppv) PURE;
53 STDMETHOD(CreateFrame) (THIS_ LPDIRECT3DRMFRAME, LPDIRECT3DRMFRAME *) PURE;
54 STDMETHOD(CreateMesh) (THIS_ LPDIRECT3DRMMESH *) PURE;
55 STDMETHOD(CreateMeshBuilder)(THIS_ LPDIRECT3DRMMESHBUILDER *) PURE;
56 STDMETHOD(CreateFace) (THIS_ LPDIRECT3DRMFACE *) PURE;
57 STDMETHOD(CreateAnimation) (THIS_ LPDIRECT3DRMANIMATION *) PURE;
58 STDMETHOD(CreateAnimationSet)(THIS_ LPDIRECT3DRMANIMATIONSET *) PURE;
59 STDMETHOD(CreateTexture) (THIS_ LPD3DRMIMAGE, LPDIRECT3DRMTEXTURE *) PURE;
60 STDMETHOD(CreateLight) (THIS_ D3DRMLIGHTTYPE, D3DCOLOR, LPDIRECT3DRMLIGHT *) PURE;
61 STDMETHOD(CreateLightRGB)
62 (THIS_ D3DRMLIGHTTYPE, D3DVALUE, D3DVALUE, D3DVALUE, LPDIRECT3DRMLIGHT *) PURE;
63 STDMETHOD(CreateMaterial) (THIS_ D3DVALUE, LPDIRECT3DRMMATERIAL *) PURE;
64 STDMETHOD(CreateDevice) (THIS_ DWORD, DWORD, LPDIRECT3DRMDEVICE *) PURE;
66 /* Create a Windows Device using DirectDraw surfaces */
67 STDMETHOD(CreateDeviceFromSurface)
68 ( THIS_ LPGUID lpGUID, LPDIRECTDRAW lpDD,
69 LPDIRECTDRAWSURFACE lpDDSBack, LPDIRECT3DRMDEVICE *
70 ) PURE;
72 /* Create a Windows Device using D3D objects */
73 STDMETHOD(CreateDeviceFromD3D)
74 ( THIS_ LPDIRECT3D lpD3D, LPDIRECT3DDEVICE lpD3DDev,
75 LPDIRECT3DRMDEVICE *
76 ) PURE;
78 STDMETHOD(CreateDeviceFromClipper)
79 ( THIS_ LPDIRECTDRAWCLIPPER lpDDClipper, LPGUID lpGUID,
80 int width, int height, LPDIRECT3DRMDEVICE *) PURE;
82 STDMETHOD(CreateTextureFromSurface)(THIS_ LPDIRECTDRAWSURFACE lpDDS, LPDIRECT3DRMTEXTURE *) PURE;
84 STDMETHOD(CreateShadow)
85 ( THIS_ LPDIRECT3DRMVISUAL, LPDIRECT3DRMLIGHT,
86 D3DVALUE px, D3DVALUE py, D3DVALUE pz,
87 D3DVALUE nx, D3DVALUE ny, D3DVALUE nz,
88 LPDIRECT3DRMVISUAL *
89 ) PURE;
90 STDMETHOD(CreateViewport)
91 ( THIS_ LPDIRECT3DRMDEVICE, LPDIRECT3DRMFRAME, DWORD, DWORD,
92 DWORD, DWORD, LPDIRECT3DRMVIEWPORT *
93 ) PURE;
94 STDMETHOD(CreateWrap)
95 ( THIS_ D3DRMWRAPTYPE, LPDIRECT3DRMFRAME,
96 D3DVALUE ox, D3DVALUE oy, D3DVALUE oz,
97 D3DVALUE dx, D3DVALUE dy, D3DVALUE dz,
98 D3DVALUE ux, D3DVALUE uy, D3DVALUE uz,
99 D3DVALUE ou, D3DVALUE ov,
100 D3DVALUE su, D3DVALUE sv,
101 LPDIRECT3DRMWRAP *
102 ) PURE;
103 STDMETHOD(CreateUserVisual) (THIS_ D3DRMUSERVISUALCALLBACK, LPVOID lPArg, LPDIRECT3DRMUSERVISUAL *) PURE;
104 STDMETHOD(LoadTexture) (THIS_ const char *, LPDIRECT3DRMTEXTURE *) PURE;
105 STDMETHOD(LoadTextureFromResource) (THIS_ HRSRC rs, LPDIRECT3DRMTEXTURE *) PURE;
107 STDMETHOD(SetSearchPath) (THIS_ LPCSTR) PURE;
108 STDMETHOD(AddSearchPath) (THIS_ LPCSTR) PURE;
109 STDMETHOD(GetSearchPath) (THIS_ DWORD *size_return, LPSTR path_return) PURE;
110 STDMETHOD(SetDefaultTextureColors)(THIS_ DWORD) PURE;
111 STDMETHOD(SetDefaultTextureShades)(THIS_ DWORD) PURE;
113 STDMETHOD(GetDevices) (THIS_ LPDIRECT3DRMDEVICEARRAY *) PURE;
114 STDMETHOD(GetNamedObject) (THIS_ const char *, LPDIRECT3DRMOBJECT *) PURE;
116 STDMETHOD(EnumerateObjects) (THIS_ D3DRMOBJECTCALLBACK, LPVOID) PURE;
118 STDMETHOD(Load)
119 ( THIS_ LPVOID, LPVOID, LPIID *, DWORD, D3DRMLOADOPTIONS,
120 D3DRMLOADCALLBACK, LPVOID, D3DRMLOADTEXTURECALLBACK, LPVOID,
121 LPDIRECT3DRMFRAME
122 ) PURE;
123 STDMETHOD(Tick) (THIS_ D3DVALUE) PURE;
126 #undef INTERFACE
127 #define INTERFACE IDirect3DRM2
129 DECLARE_INTERFACE_(IDirect3DRM2, IUnknown)
131 IUNKNOWN_METHODS(PURE);
133 STDMETHOD(CreateObject)
134 (THIS_ REFCLSID rclsid, LPUNKNOWN pUnkOuter, REFIID riid, LPVOID FAR* ppv) PURE;
135 STDMETHOD(CreateFrame) (THIS_ LPDIRECT3DRMFRAME, LPDIRECT3DRMFRAME2 *) PURE;
136 STDMETHOD(CreateMesh) (THIS_ LPDIRECT3DRMMESH *) PURE;
137 STDMETHOD(CreateMeshBuilder)(THIS_ LPDIRECT3DRMMESHBUILDER2 *) PURE;
138 STDMETHOD(CreateFace) (THIS_ LPDIRECT3DRMFACE *) PURE;
139 STDMETHOD(CreateAnimation) (THIS_ LPDIRECT3DRMANIMATION *) PURE;
140 STDMETHOD(CreateAnimationSet)(THIS_ LPDIRECT3DRMANIMATIONSET *) PURE;
141 STDMETHOD(CreateTexture) (THIS_ LPD3DRMIMAGE, LPDIRECT3DRMTEXTURE2 *) PURE;
142 STDMETHOD(CreateLight) (THIS_ D3DRMLIGHTTYPE, D3DCOLOR, LPDIRECT3DRMLIGHT *) PURE;
143 STDMETHOD(CreateLightRGB)
144 (THIS_ D3DRMLIGHTTYPE, D3DVALUE, D3DVALUE, D3DVALUE, LPDIRECT3DRMLIGHT *) PURE;
145 STDMETHOD(CreateMaterial) (THIS_ D3DVALUE, LPDIRECT3DRMMATERIAL *) PURE;
146 STDMETHOD(CreateDevice) (THIS_ DWORD, DWORD, LPDIRECT3DRMDEVICE2 *) PURE;
148 /* Create a Windows Device using DirectDraw surfaces */
149 STDMETHOD(CreateDeviceFromSurface)
150 ( THIS_ LPGUID lpGUID, LPDIRECTDRAW lpDD,
151 LPDIRECTDRAWSURFACE lpDDSBack, LPDIRECT3DRMDEVICE2 *
152 ) PURE;
154 /* Create a Windows Device using D3D objects */
155 STDMETHOD(CreateDeviceFromD3D)
156 ( THIS_ LPDIRECT3D2 lpD3D, LPDIRECT3DDEVICE2 lpD3DDev,
157 LPDIRECT3DRMDEVICE2 *
158 ) PURE;
160 STDMETHOD(CreateDeviceFromClipper)
161 ( THIS_ LPDIRECTDRAWCLIPPER lpDDClipper, LPGUID lpGUID,
162 int width, int height, LPDIRECT3DRMDEVICE2 *) PURE;
164 STDMETHOD(CreateTextureFromSurface)(THIS_ LPDIRECTDRAWSURFACE lpDDS, LPDIRECT3DRMTEXTURE2 *) PURE;
166 STDMETHOD(CreateShadow)
167 ( THIS_ LPDIRECT3DRMVISUAL, LPDIRECT3DRMLIGHT,
168 D3DVALUE px, D3DVALUE py, D3DVALUE pz,
169 D3DVALUE nx, D3DVALUE ny, D3DVALUE nz,
170 LPDIRECT3DRMVISUAL *
171 ) PURE;
172 STDMETHOD(CreateViewport)
173 ( THIS_ LPDIRECT3DRMDEVICE, LPDIRECT3DRMFRAME, DWORD, DWORD,
174 DWORD, DWORD, LPDIRECT3DRMVIEWPORT *
175 ) PURE;
176 STDMETHOD(CreateWrap)
177 ( THIS_ D3DRMWRAPTYPE, LPDIRECT3DRMFRAME,
178 D3DVALUE ox, D3DVALUE oy, D3DVALUE oz,
179 D3DVALUE dx, D3DVALUE dy, D3DVALUE dz,
180 D3DVALUE ux, D3DVALUE uy, D3DVALUE uz,
181 D3DVALUE ou, D3DVALUE ov,
182 D3DVALUE su, D3DVALUE sv,
183 LPDIRECT3DRMWRAP *
184 ) PURE;
185 STDMETHOD(CreateUserVisual) (THIS_ D3DRMUSERVISUALCALLBACK, LPVOID lPArg, LPDIRECT3DRMUSERVISUAL *) PURE;
186 STDMETHOD(LoadTexture) (THIS_ const char *, LPDIRECT3DRMTEXTURE2 *) PURE;
187 STDMETHOD(LoadTextureFromResource) (THIS_ HMODULE hModule, LPCTSTR strName, LPCTSTR strType, LPDIRECT3DRMTEXTURE2 *) PURE;
189 STDMETHOD(SetSearchPath) (THIS_ LPCSTR) PURE;
190 STDMETHOD(AddSearchPath) (THIS_ LPCSTR) PURE;
191 STDMETHOD(GetSearchPath) (THIS_ DWORD *size_return, LPSTR path_return) PURE;
192 STDMETHOD(SetDefaultTextureColors)(THIS_ DWORD) PURE;
193 STDMETHOD(SetDefaultTextureShades)(THIS_ DWORD) PURE;
195 STDMETHOD(GetDevices) (THIS_ LPDIRECT3DRMDEVICEARRAY *) PURE;
196 STDMETHOD(GetNamedObject) (THIS_ const char *, LPDIRECT3DRMOBJECT *) PURE;
198 STDMETHOD(EnumerateObjects) (THIS_ D3DRMOBJECTCALLBACK, LPVOID) PURE;
200 STDMETHOD(Load)
201 ( THIS_ LPVOID, LPVOID, LPIID *, DWORD, D3DRMLOADOPTIONS,
202 D3DRMLOADCALLBACK, LPVOID, D3DRMLOADTEXTURECALLBACK, LPVOID,
203 LPDIRECT3DRMFRAME
204 ) PURE;
205 STDMETHOD(Tick) (THIS_ D3DVALUE) PURE;
207 STDMETHOD(CreateProgressiveMesh)(THIS_ LPDIRECT3DRMPROGRESSIVEMESH *) PURE;
210 #undef INTERFACE
211 #define INTERFACE IDirect3DRM3
213 DECLARE_INTERFACE_(IDirect3DRM3, IUnknown)
215 IUNKNOWN_METHODS(PURE);
217 STDMETHOD(CreateObject)
218 (THIS_ REFCLSID rclsid, LPUNKNOWN pUnkOuter, REFIID riid, LPVOID FAR* ppv) PURE;
219 STDMETHOD(CreateFrame) (THIS_ LPDIRECT3DRMFRAME3, LPDIRECT3DRMFRAME3 *) PURE;
220 STDMETHOD(CreateMesh) (THIS_ LPDIRECT3DRMMESH *) PURE;
221 STDMETHOD(CreateMeshBuilder)(THIS_ LPDIRECT3DRMMESHBUILDER3 *) PURE;
222 STDMETHOD(CreateFace) (THIS_ LPDIRECT3DRMFACE2 *) PURE;
223 STDMETHOD(CreateAnimation) (THIS_ LPDIRECT3DRMANIMATION2 *) PURE;
224 STDMETHOD(CreateAnimationSet)(THIS_ LPDIRECT3DRMANIMATIONSET2 *) PURE;
225 STDMETHOD(CreateTexture) (THIS_ LPD3DRMIMAGE, LPDIRECT3DRMTEXTURE3 *) PURE;
226 STDMETHOD(CreateLight) (THIS_ D3DRMLIGHTTYPE, D3DCOLOR, LPDIRECT3DRMLIGHT *) PURE;
227 STDMETHOD(CreateLightRGB)
228 (THIS_ D3DRMLIGHTTYPE, D3DVALUE, D3DVALUE, D3DVALUE, LPDIRECT3DRMLIGHT *) PURE;
229 STDMETHOD(CreateMaterial) (THIS_ D3DVALUE, LPDIRECT3DRMMATERIAL2 *) PURE;
230 STDMETHOD(CreateDevice) (THIS_ DWORD, DWORD, LPDIRECT3DRMDEVICE3 *) PURE;
232 /* Create a Windows Device using DirectDraw surfaces */
233 STDMETHOD(CreateDeviceFromSurface)
234 ( THIS_ LPGUID lpGUID, LPDIRECTDRAW lpDD,
235 LPDIRECTDRAWSURFACE lpDDSBack, DWORD dwFlags, LPDIRECT3DRMDEVICE3 *
236 ) PURE;
238 /* Create a Windows Device using D3D objects */
239 STDMETHOD(CreateDeviceFromD3D)
240 ( THIS_ LPDIRECT3D2 lpD3D, LPDIRECT3DDEVICE2 lpD3DDev,
241 LPDIRECT3DRMDEVICE3 *
242 ) PURE;
244 STDMETHOD(CreateDeviceFromClipper)
245 ( THIS_ LPDIRECTDRAWCLIPPER lpDDClipper, LPGUID lpGUID,
246 int width, int height, LPDIRECT3DRMDEVICE3 *) PURE;
248 STDMETHOD(CreateTextureFromSurface)(THIS_ LPDIRECTDRAWSURFACE lpDDS, LPDIRECT3DRMTEXTURE3 *) PURE;
250 STDMETHOD(CreateShadow)
251 ( THIS_ LPUNKNOWN, LPDIRECT3DRMLIGHT,
252 D3DVALUE px, D3DVALUE py, D3DVALUE pz,
253 D3DVALUE nx, D3DVALUE ny, D3DVALUE nz,
254 LPDIRECT3DRMSHADOW2 *
255 ) PURE;
256 STDMETHOD(CreateViewport)
257 ( THIS_ LPDIRECT3DRMDEVICE3, LPDIRECT3DRMFRAME3, DWORD, DWORD,
258 DWORD, DWORD, LPDIRECT3DRMVIEWPORT2 *
259 ) PURE;
260 STDMETHOD(CreateWrap)
261 ( THIS_ D3DRMWRAPTYPE, LPDIRECT3DRMFRAME3,
262 D3DVALUE ox, D3DVALUE oy, D3DVALUE oz,
263 D3DVALUE dx, D3DVALUE dy, D3DVALUE dz,
264 D3DVALUE ux, D3DVALUE uy, D3DVALUE uz,
265 D3DVALUE ou, D3DVALUE ov,
266 D3DVALUE su, D3DVALUE sv,
267 LPDIRECT3DRMWRAP *
268 ) PURE;
269 STDMETHOD(CreateUserVisual) (THIS_ D3DRMUSERVISUALCALLBACK, LPVOID lPArg, LPDIRECT3DRMUSERVISUAL *) PURE;
270 STDMETHOD(LoadTexture) (THIS_ const char *, LPDIRECT3DRMTEXTURE3 *) PURE;
271 STDMETHOD(LoadTextureFromResource) (THIS_ HMODULE hModule, LPCTSTR strName, LPCTSTR strType, LPDIRECT3DRMTEXTURE3 *) PURE;
273 STDMETHOD(SetSearchPath) (THIS_ LPCSTR) PURE;
274 STDMETHOD(AddSearchPath) (THIS_ LPCSTR) PURE;
275 STDMETHOD(GetSearchPath) (THIS_ DWORD *size_return, LPSTR path_return) PURE;
276 STDMETHOD(SetDefaultTextureColors)(THIS_ DWORD) PURE;
277 STDMETHOD(SetDefaultTextureShades)(THIS_ DWORD) PURE;
279 STDMETHOD(GetDevices) (THIS_ LPDIRECT3DRMDEVICEARRAY *) PURE;
280 STDMETHOD(GetNamedObject) (THIS_ const char *, LPDIRECT3DRMOBJECT *) PURE;
282 STDMETHOD(EnumerateObjects) (THIS_ D3DRMOBJECTCALLBACK, LPVOID) PURE;
284 STDMETHOD(Load)
285 ( THIS_ LPVOID, LPVOID, LPIID *, DWORD, D3DRMLOADOPTIONS,
286 D3DRMLOADCALLBACK, LPVOID, D3DRMLOADTEXTURE3CALLBACK, LPVOID,
287 LPDIRECT3DRMFRAME3
288 ) PURE;
289 STDMETHOD(Tick) (THIS_ D3DVALUE) PURE;
291 STDMETHOD(CreateProgressiveMesh)(THIS_ LPDIRECT3DRMPROGRESSIVEMESH *) PURE;
293 /* Used with IDirect3DRMObject2 */
294 STDMETHOD(RegisterClient) (THIS_ REFGUID rguid, LPDWORD lpdwID) PURE;
295 STDMETHOD(UnregisterClient) (THIS_ REFGUID rguid) PURE;
297 STDMETHOD(CreateClippedVisual) (THIS_ LPDIRECT3DRMVISUAL, LPDIRECT3DRMCLIPPEDVISUAL *) PURE;
298 STDMETHOD(SetOptions) (THIS_ DWORD);
299 STDMETHOD(GetOptions) (THIS_ LPDWORD);
302 #define D3DRM_OK DD_OK
303 #define D3DRMERR_BADOBJECT MAKE_DDHRESULT(781)
304 #define D3DRMERR_BADTYPE MAKE_DDHRESULT(782)
305 #define D3DRMERR_BADALLOC MAKE_DDHRESULT(783)
306 #define D3DRMERR_FACEUSED MAKE_DDHRESULT(784)
307 #define D3DRMERR_NOTFOUND MAKE_DDHRESULT(785)
308 #define D3DRMERR_NOTDONEYET MAKE_DDHRESULT(786)
309 #define D3DRMERR_FILENOTFOUND MAKE_DDHRESULT(787)
310 #define D3DRMERR_BADFILE MAKE_DDHRESULT(788)
311 #define D3DRMERR_BADDEVICE MAKE_DDHRESULT(789)
312 #define D3DRMERR_BADVALUE MAKE_DDHRESULT(790)
313 #define D3DRMERR_BADMAJORVERSION MAKE_DDHRESULT(791)
314 #define D3DRMERR_BADMINORVERSION MAKE_DDHRESULT(792)
315 #define D3DRMERR_UNABLETOEXECUTE MAKE_DDHRESULT(793)
316 #define D3DRMERR_LIBRARYNOTFOUND MAKE_DDHRESULT(794)
317 #define D3DRMERR_INVALIDLIBRARY MAKE_DDHRESULT(795)
318 #define D3DRMERR_PENDING MAKE_DDHRESULT(796)
319 #define D3DRMERR_NOTENOUGHDATA MAKE_DDHRESULT(797)
320 #define D3DRMERR_REQUESTTOOLARGE MAKE_DDHRESULT(798)
321 #define D3DRMERR_REQUESTTOOSMALL MAKE_DDHRESULT(799)
322 #define D3DRMERR_CONNECTIONLOST MAKE_DDHRESULT(800)
323 #define D3DRMERR_LOADABORTED MAKE_DDHRESULT(801)
324 #define D3DRMERR_NOINTERNET MAKE_DDHRESULT(802)
325 #define D3DRMERR_BADCACHEFILE MAKE_DDHRESULT(803)
326 #define D3DRMERR_BOXNOTSET MAKE_DDHRESULT(804)
327 #define D3DRMERR_BADPMDATA MAKE_DDHRESULT(805)
328 #define D3DRMERR_CLIENTNOTREGISTERED MAKE_DDHRESULT(806)
329 #define D3DRMERR_NOTCREATEDFROMDDS MAKE_DDHRESULT(807)
330 #define D3DRMERR_NOSUCHKEY MAKE_DDHRESULT(808)
331 #define D3DRMERR_INCOMPATABLEKEY MAKE_DDHRESULT(809)
332 #define D3DRMERR_ELEMENTINUSE MAKE_DDHRESULT(810)
333 #define D3DRMERR_TEXTUREFORMATNOTFOUND MAKE_DDHRESULT(811)
334 #define D3DRMERR_NOTAGGREGATED MAKE_DDHRESULT(812)
336 #ifdef __cplusplus
338 #endif
340 #endif /* _D3DRMAPI_H_ */