2 * Implementation of IDirect3DRMFrame Interface
4 * Copyright 2011, 2012 André Hentschel
5 * Copyright 2012 Christian Costa
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Lesser General Public
9 * License as published by the Free Software Foundation; either
10 * version 2.1 of the License, or (at your option) any later version.
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Lesser General Public License for more details.
17 * You should have received a copy of the GNU Lesser General Public
18 * License along with this library; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
23 #include "wine/debug.h"
30 #include "d3drm_private.h"
32 WINE_DEFAULT_DEBUG_CHANNEL(d3drm);
34 static D3DRMMATRIX4D identity = {
35 { 1.0f, 0.0f, 0.0f, 0.0f },
36 { 0.0f, 1.0f, 0.0f, 0.0f },
37 { 0.0f, 0.0f, 1.0f, 0.0f },
38 { 0.0f, 0.0f, 0.0f, 1.0f }
41 typedef struct IDirect3DRMFrameImpl IDirect3DRMFrameImpl;
43 struct IDirect3DRMFrameImpl {
44 IDirect3DRMFrame2 IDirect3DRMFrame2_iface;
45 IDirect3DRMFrame3 IDirect3DRMFrame3_iface;
47 IDirect3DRMFrameImpl* parent;
49 ULONG children_capacity;
50 IDirect3DRMFrame3** children;
52 ULONG visuals_capacity;
53 IDirect3DRMVisual** visuals;
55 ULONG lights_capacity;
56 IDirect3DRMLight** lights;
57 D3DRMMATRIX4D transform;
58 D3DCOLOR scenebackground;
62 IDirect3DRMFrameArray IDirect3DRMFrameArray_iface;
65 LPDIRECT3DRMFRAME* frames;
66 } IDirect3DRMFrameArrayImpl;
69 IDirect3DRMVisualArray IDirect3DRMVisualArray_iface;
72 LPDIRECT3DRMVISUAL* visuals;
73 } IDirect3DRMVisualArrayImpl;
76 IDirect3DRMLightArray IDirect3DRMLightArray_iface;
79 LPDIRECT3DRMLIGHT* lights;
80 } IDirect3DRMLightArrayImpl;
82 static inline IDirect3DRMFrameImpl *impl_from_IDirect3DRMFrame2(IDirect3DRMFrame2 *iface)
84 return CONTAINING_RECORD(iface, IDirect3DRMFrameImpl, IDirect3DRMFrame2_iface);
87 static inline IDirect3DRMFrameImpl *impl_from_IDirect3DRMFrame3(IDirect3DRMFrame3 *iface)
89 return CONTAINING_RECORD(iface, IDirect3DRMFrameImpl, IDirect3DRMFrame3_iface);
92 static inline IDirect3DRMFrameImpl *unsafe_impl_from_IDirect3DRMFrame3(IDirect3DRMFrame3 *iface);
94 static inline IDirect3DRMLightArrayImpl *impl_from_IDirect3DRMLightArray(IDirect3DRMLightArray *iface)
96 return CONTAINING_RECORD(iface, IDirect3DRMLightArrayImpl, IDirect3DRMLightArray_iface);
99 /*** IUnknown methods ***/
100 static HRESULT WINAPI IDirect3DRMFrameArrayImpl_QueryInterface(IDirect3DRMFrameArray* iface,
101 REFIID riid, void** object)
103 IDirect3DRMFrameArrayImpl *This = (IDirect3DRMFrameArrayImpl*)iface;
105 TRACE("(%p/%p)->(%s, %p)\n", iface, This, debugstr_guid(riid), object);
109 if (IsEqualGUID(riid, &IID_IUnknown) ||
110 IsEqualGUID(riid, &IID_IDirect3DRMFrameArray))
112 *object = &This->IDirect3DRMFrameArray_iface;
116 FIXME("interface %s not implemented\n", debugstr_guid(riid));
117 return E_NOINTERFACE;
120 IDirect3DRMFrameArray_AddRef(iface);
124 static ULONG WINAPI IDirect3DRMFrameArrayImpl_AddRef(IDirect3DRMFrameArray* iface)
126 IDirect3DRMFrameArrayImpl *This = (IDirect3DRMFrameArrayImpl*)iface;
127 ULONG ref = InterlockedIncrement(&This->ref);
129 TRACE("(%p)->(): new ref = %u\n", This, ref);
134 static ULONG WINAPI IDirect3DRMFrameArrayImpl_Release(IDirect3DRMFrameArray* iface)
136 IDirect3DRMFrameArrayImpl *This = (IDirect3DRMFrameArrayImpl*)iface;
137 ULONG ref = InterlockedDecrement(&This->ref);
140 TRACE("(%p)->(): new ref = %u\n", This, ref);
144 for (i = 0; i < This->size; i++)
145 IDirect3DRMFrame_Release(This->frames[i]);
146 HeapFree(GetProcessHeap(), 0, This->frames);
147 HeapFree(GetProcessHeap(), 0, This);
153 /*** IDirect3DRMArray methods ***/
154 static DWORD WINAPI IDirect3DRMFrameArrayImpl_GetSize(IDirect3DRMFrameArray* iface)
156 IDirect3DRMFrameArrayImpl *This = (IDirect3DRMFrameArrayImpl*)iface;
158 TRACE("(%p)->() = %d\n", This, This->size);
163 /*** IDirect3DRMFrameArray methods ***/
164 static HRESULT WINAPI IDirect3DRMFrameArrayImpl_GetElement(IDirect3DRMFrameArray* iface, DWORD index, LPDIRECT3DRMFRAME* frame)
166 IDirect3DRMFrameArrayImpl *This = (IDirect3DRMFrameArrayImpl*)iface;
168 TRACE("(%p)->(%u, %p)\n", This, index, frame);
171 return D3DRMERR_BADVALUE;
175 if (index >= This->size)
176 return D3DRMERR_BADVALUE;
178 IDirect3DRMFrame_AddRef(This->frames[index]);
179 *frame = This->frames[index];
184 static const struct IDirect3DRMFrameArrayVtbl Direct3DRMFrameArray_Vtbl =
186 /*** IUnknown methods ***/
187 IDirect3DRMFrameArrayImpl_QueryInterface,
188 IDirect3DRMFrameArrayImpl_AddRef,
189 IDirect3DRMFrameArrayImpl_Release,
190 /*** IDirect3DRMArray methods ***/
191 IDirect3DRMFrameArrayImpl_GetSize,
192 /*** IDirect3DRMFrameArray methods ***/
193 IDirect3DRMFrameArrayImpl_GetElement
196 static HRESULT Direct3DRMFrameArray_create(IDirect3DRMFrameArray** obj)
198 IDirect3DRMFrameArrayImpl* object;
200 TRACE("(%p)\n", obj);
204 object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(IDirect3DRMFrameArrayImpl));
207 ERR("Out of memory\n");
208 return E_OUTOFMEMORY;
211 object->IDirect3DRMFrameArray_iface.lpVtbl = &Direct3DRMFrameArray_Vtbl;
214 *obj = &object->IDirect3DRMFrameArray_iface;
219 /*** IUnknown methods ***/
220 static HRESULT WINAPI IDirect3DRMVisualArrayImpl_QueryInterface(IDirect3DRMVisualArray* iface,
221 REFIID riid, void** ret_iface)
223 TRACE("(%p)->(%s, %p)\n", iface, debugstr_guid(riid), ret_iface);
225 if (IsEqualGUID(riid, &IID_IUnknown) ||
226 IsEqualGUID(riid, &IID_IDirect3DRMFrameArray))
229 IDirect3DRMVisualArray_AddRef(iface);
235 WARN("Interface %s not implemented\n", debugstr_guid(riid));
237 return E_NOINTERFACE;
240 static ULONG WINAPI IDirect3DRMVisualArrayImpl_AddRef(IDirect3DRMVisualArray* iface)
242 IDirect3DRMVisualArrayImpl *This = (IDirect3DRMVisualArrayImpl*)iface;
243 ULONG ref = InterlockedIncrement(&This->ref);
245 TRACE("(%p)->(): new ref = %u\n", iface, ref);
250 static ULONG WINAPI IDirect3DRMVisualArrayImpl_Release(IDirect3DRMVisualArray* iface)
252 IDirect3DRMVisualArrayImpl *This = (IDirect3DRMVisualArrayImpl*)iface;
253 ULONG ref = InterlockedDecrement(&This->ref);
256 TRACE("(%p)->(): new ref = %u\n", iface, ref);
260 for (i = 0; i < This->size; i++)
261 IDirect3DRMVisual_Release(This->visuals[i]);
262 HeapFree(GetProcessHeap(), 0, This->visuals);
263 HeapFree(GetProcessHeap(), 0, This);
269 /*** IDirect3DRMArray methods ***/
270 static DWORD WINAPI IDirect3DRMVisualArrayImpl_GetSize(IDirect3DRMVisualArray* iface)
272 IDirect3DRMVisualArrayImpl *This = (IDirect3DRMVisualArrayImpl*)iface;
274 TRACE("(%p)->() = %d\n", iface, This->size);
279 /*** IDirect3DRMVisualArray methods ***/
280 static HRESULT WINAPI IDirect3DRMVisualArrayImpl_GetElement(IDirect3DRMVisualArray* iface, DWORD index, LPDIRECT3DRMVISUAL* visual)
282 IDirect3DRMVisualArrayImpl *This = (IDirect3DRMVisualArrayImpl*)iface;
284 TRACE("(%p)->(%u, %p)\n", iface, index, visual);
287 return D3DRMERR_BADVALUE;
291 if (index >= This->size)
292 return D3DRMERR_BADVALUE;
294 IDirect3DRMVisual_AddRef(This->visuals[index]);
295 *visual = This->visuals[index];
300 static const struct IDirect3DRMVisualArrayVtbl Direct3DRMVisualArray_Vtbl =
302 /*** IUnknown methods ***/
303 IDirect3DRMVisualArrayImpl_QueryInterface,
304 IDirect3DRMVisualArrayImpl_AddRef,
305 IDirect3DRMVisualArrayImpl_Release,
306 /*** IDirect3DRMArray methods ***/
307 IDirect3DRMVisualArrayImpl_GetSize,
308 /*** IDirect3DRMVisualArray methods ***/
309 IDirect3DRMVisualArrayImpl_GetElement
312 static HRESULT Direct3DRMVisualArray_create(IDirect3DRMVisualArray** ret_iface)
314 IDirect3DRMVisualArrayImpl* object;
316 TRACE("(%p)\n", ret_iface);
320 object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(IDirect3DRMVisualArrayImpl));
323 ERR("Out of memory\n");
324 return E_OUTOFMEMORY;
327 object->IDirect3DRMVisualArray_iface.lpVtbl = &Direct3DRMVisualArray_Vtbl;
330 *ret_iface = &object->IDirect3DRMVisualArray_iface;
335 /*** IUnknown methods ***/
336 static HRESULT WINAPI IDirect3DRMLightArrayImpl_QueryInterface(IDirect3DRMLightArray* iface,
337 REFIID riid, void** object)
339 IDirect3DRMLightArrayImpl *This = impl_from_IDirect3DRMLightArray(iface);
341 TRACE("(%p/%p)->(%s, %p)\n", iface, This, debugstr_guid(riid), object);
345 if (IsEqualGUID(riid, &IID_IUnknown) ||
346 IsEqualGUID(riid, &IID_IDirect3DRMLightArray))
348 *object = &This->IDirect3DRMLightArray_iface;
352 FIXME("interface %s not implemented\n", debugstr_guid(riid));
353 return E_NOINTERFACE;
356 IDirect3DRMLightArray_AddRef(iface);
360 static ULONG WINAPI IDirect3DRMLightArrayImpl_AddRef(IDirect3DRMLightArray* iface)
362 IDirect3DRMLightArrayImpl *This = impl_from_IDirect3DRMLightArray(iface);
363 ULONG ref = InterlockedIncrement(&This->ref);
365 TRACE("(%p)->(): new ref = %u\n", This, ref);
370 static ULONG WINAPI IDirect3DRMLightArrayImpl_Release(IDirect3DRMLightArray* iface)
372 IDirect3DRMLightArrayImpl *This = impl_from_IDirect3DRMLightArray(iface);
373 ULONG ref = InterlockedDecrement(&This->ref);
376 TRACE("(%p)->(): new ref = %u\n", This, ref);
380 for (i = 0; i < This->size; i++)
381 IDirect3DRMLight_Release(This->lights[i]);
382 HeapFree(GetProcessHeap(), 0, This->lights);
383 HeapFree(GetProcessHeap(), 0, This);
389 /*** IDirect3DRMArray methods ***/
390 static DWORD WINAPI IDirect3DRMLightArrayImpl_GetSize(IDirect3DRMLightArray* iface)
392 IDirect3DRMLightArrayImpl *This = impl_from_IDirect3DRMLightArray(iface);
394 TRACE("(%p)->() = %d\n", This, This->size);
399 /*** IDirect3DRMLightArray methods ***/
400 static HRESULT WINAPI IDirect3DRMLightArrayImpl_GetElement(IDirect3DRMLightArray* iface, DWORD index, LPDIRECT3DRMLIGHT* light)
402 IDirect3DRMLightArrayImpl *This = impl_from_IDirect3DRMLightArray(iface);
404 TRACE("(%p)->(%u, %p)\n", This, index, light);
407 return D3DRMERR_BADVALUE;
411 if (index >= This->size)
412 return D3DRMERR_BADVALUE;
414 IDirect3DRMLight_AddRef(This->lights[index]);
415 *light = This->lights[index];
420 static const struct IDirect3DRMLightArrayVtbl Direct3DRMLightArray_Vtbl =
422 /*** IUnknown methods ***/
423 IDirect3DRMLightArrayImpl_QueryInterface,
424 IDirect3DRMLightArrayImpl_AddRef,
425 IDirect3DRMLightArrayImpl_Release,
426 /*** IDirect3DRMArray methods ***/
427 IDirect3DRMLightArrayImpl_GetSize,
428 /*** IDirect3DRMLightArray methods ***/
429 IDirect3DRMLightArrayImpl_GetElement
432 static HRESULT Direct3DRMLightArray_create(IDirect3DRMLightArray** obj)
434 IDirect3DRMLightArrayImpl* object;
436 TRACE("(%p)\n", obj);
440 object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(IDirect3DRMLightArrayImpl));
443 ERR("Out of memory\n");
444 return E_OUTOFMEMORY;
447 object->IDirect3DRMLightArray_iface.lpVtbl = &Direct3DRMLightArray_Vtbl;
450 *obj = &object->IDirect3DRMLightArray_iface;
455 /*** IUnknown methods ***/
456 static HRESULT WINAPI IDirect3DRMFrame2Impl_QueryInterface(IDirect3DRMFrame2* iface,
457 REFIID riid, void** object)
459 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
461 TRACE("(%p/%p)->(%s, %p)\n", iface, This, debugstr_guid(riid), object);
465 if(IsEqualGUID(riid, &IID_IUnknown) ||
466 IsEqualGUID(riid, &IID_IDirect3DRMFrame) ||
467 IsEqualGUID(riid, &IID_IDirect3DRMFrame2))
469 *object = &This->IDirect3DRMFrame2_iface;
471 else if(IsEqualGUID(riid, &IID_IDirect3DRMFrame3))
473 *object = &This->IDirect3DRMFrame3_iface;
477 FIXME("interface %s not implemented\n", debugstr_guid(riid));
478 return E_NOINTERFACE;
481 IDirect3DRMFrame2_AddRef(iface);
485 static ULONG WINAPI IDirect3DRMFrame2Impl_AddRef(IDirect3DRMFrame2* iface)
487 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
488 ULONG ref = InterlockedIncrement(&This->ref);
490 TRACE("(%p)->(): new ref = %d\n", This, ref);
495 static ULONG WINAPI IDirect3DRMFrame2Impl_Release(IDirect3DRMFrame2* iface)
497 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
498 ULONG ref = InterlockedDecrement(&This->ref);
501 TRACE("(%p)->(): new ref = %d\n", This, ref);
505 for (i = 0; i < This->nb_children; i++)
506 IDirect3DRMFrame3_Release(This->children[i]);
507 HeapFree(GetProcessHeap(), 0, This->children);
508 for (i = 0; i < This->nb_visuals; i++)
509 IDirect3DRMVisual_Release(This->visuals[i]);
510 HeapFree(GetProcessHeap(), 0, This->visuals);
511 for (i = 0; i < This->nb_lights; i++)
512 IDirect3DRMLight_Release(This->lights[i]);
513 HeapFree(GetProcessHeap(), 0, This->lights);
514 HeapFree(GetProcessHeap(), 0, This);
520 /*** IDirect3DRMObject methods ***/
521 static HRESULT WINAPI IDirect3DRMFrame2Impl_Clone(IDirect3DRMFrame2* iface,
522 LPUNKNOWN unkwn, REFIID riid,
525 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
527 FIXME("(%p/%p)->(%p, %s, %p): stub\n", iface, This, unkwn, debugstr_guid(riid), object);
532 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddDestroyCallback(IDirect3DRMFrame2* iface,
533 D3DRMOBJECTCALLBACK cb,
536 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
538 FIXME("(%p/%p)->(%p, %p): stub\n", iface, This, cb, argument);
543 static HRESULT WINAPI IDirect3DRMFrame2Impl_DeleteDestroyCallback(IDirect3DRMFrame2* iface,
544 D3DRMOBJECTCALLBACK cb,
547 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
549 FIXME("(%p/%p)->(%p, %p): stub\n", iface, This, cb, argument);
554 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetAppData(IDirect3DRMFrame2* iface,
557 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
559 FIXME("(%p/%p)->(%u): stub\n", iface, This, data);
564 static DWORD WINAPI IDirect3DRMFrame2Impl_GetAppData(IDirect3DRMFrame2* iface)
566 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
568 FIXME("(%p/%p)->(): stub\n", iface, This);
573 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetName(IDirect3DRMFrame2* iface, LPCSTR name)
575 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
577 FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
582 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetName(IDirect3DRMFrame2* iface,
583 LPDWORD size, LPSTR name)
585 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
587 FIXME("(%p/%p)->(%p, %p): stub\n", iface, This, size, name);
592 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetClassName(IDirect3DRMFrame2* iface,
593 LPDWORD size, LPSTR name)
595 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
597 TRACE("(%p/%p)->(%p, %p)\n", iface, This, size, name);
599 return IDirect3DRMFrame3_GetClassName(&This->IDirect3DRMFrame3_iface, size, name);
602 /*** IDirect3DRMFrame methods ***/
603 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddChild(IDirect3DRMFrame2* iface,
604 LPDIRECT3DRMFRAME child)
606 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
607 IDirect3DRMFrame3 *frame;
610 TRACE("(%p/%p)->(%p)\n", iface, This, child);
613 return D3DRMERR_BADOBJECT;
614 hr = IDirect3DRMFrame_QueryInterface(child, &IID_IDirect3DRMFrame3, (void**)&frame);
616 return D3DRMERR_BADOBJECT;
617 IDirect3DRMFrame_Release(child);
619 return IDirect3DRMFrame3_AddChild(&This->IDirect3DRMFrame3_iface, frame);
622 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddLight(IDirect3DRMFrame2* iface,
623 LPDIRECT3DRMLIGHT light)
625 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
627 TRACE("(%p/%p)->(%p)\n", iface, This, light);
629 return IDirect3DRMFrame3_AddLight(&This->IDirect3DRMFrame3_iface, light);
632 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddMoveCallback(IDirect3DRMFrame2* iface,
633 D3DRMFRAMEMOVECALLBACK cb, VOID *arg)
635 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
637 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, cb, arg);
642 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddTransform(IDirect3DRMFrame2* iface,
643 D3DRMCOMBINETYPE type,
644 D3DRMMATRIX4D matrix)
646 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
648 TRACE("(%p/%p)->(%u,%p)\n", iface, This, type, matrix);
650 return IDirect3DRMFrame3_AddTransform(&This->IDirect3DRMFrame3_iface, type, matrix);
653 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddTranslation(IDirect3DRMFrame2* iface,
654 D3DRMCOMBINETYPE type,
655 D3DVALUE x, D3DVALUE y, D3DVALUE z)
657 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
659 FIXME("(%p/%p)->(%u,%f,%f,%f): stub\n", iface, This, type, x, y, z);
664 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddScale(IDirect3DRMFrame2* iface,
665 D3DRMCOMBINETYPE type,
666 D3DVALUE sx, D3DVALUE sy, D3DVALUE sz)
668 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
670 FIXME("(%p/%p)->(%u,%f,%f,%f): stub\n", iface, This, type, sx, sy, sz);
675 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddRotation(IDirect3DRMFrame2* iface,
676 D3DRMCOMBINETYPE type,
677 D3DVALUE x, D3DVALUE y, D3DVALUE z,
680 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
682 FIXME("(%p/%p)->(%u,%f,%f,%f,%f): stub\n", iface, This, type, x, y, z, theta);
687 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddVisual(IDirect3DRMFrame2* iface,
688 LPDIRECT3DRMVISUAL vis)
690 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
692 TRACE("(%p/%p)->(%p)\n", iface, This, vis);
694 return IDirect3DRMFrame3_AddVisual(&This->IDirect3DRMFrame3_iface, (LPUNKNOWN)vis);
697 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetChildren(IDirect3DRMFrame2* iface,
698 LPDIRECT3DRMFRAMEARRAY *children)
700 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
702 TRACE("(%p/%p)->(%p)\n", iface, This, children);
704 return IDirect3DRMFrame3_GetChildren(&This->IDirect3DRMFrame3_iface, children);
707 static D3DCOLOR WINAPI IDirect3DRMFrame2Impl_GetColor(IDirect3DRMFrame2* iface)
709 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
711 FIXME("(%p/%p)->(): stub\n", iface, This);
716 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetLights(IDirect3DRMFrame2* iface,
717 LPDIRECT3DRMLIGHTARRAY *lights)
719 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
721 TRACE("(%p/%p)->(%p)\n", iface, This, lights);
723 return IDirect3DRMFrame3_GetLights(&This->IDirect3DRMFrame3_iface, lights);
726 static D3DRMMATERIALMODE WINAPI IDirect3DRMFrame2Impl_GetMaterialMode(IDirect3DRMFrame2* iface)
728 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
730 FIXME("(%p/%p)->(): stub\n", iface, This);
732 return D3DRMMATERIAL_FROMPARENT;
735 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetParent(IDirect3DRMFrame2* iface,
736 LPDIRECT3DRMFRAME * frame)
738 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
740 TRACE("(%p/%p)->(%p)\n", iface, This, frame);
743 return D3DRMERR_BADVALUE;
747 *frame = (LPDIRECT3DRMFRAME)&This->parent->IDirect3DRMFrame2_iface;
748 IDirect3DRMFrame_AddRef(*frame);
758 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetPosition(IDirect3DRMFrame2 *iface,
759 IDirect3DRMFrame *reference, D3DVECTOR *return_position)
761 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
763 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, reference, return_position);
768 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetRotation(IDirect3DRMFrame2 *iface,
769 IDirect3DRMFrame *reference, D3DVECTOR *axis, D3DVALUE *return_theta)
771 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
773 FIXME("(%p/%p)->(%p,%p,%p): stub\n", iface, This, reference, axis, return_theta);
778 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetScene(IDirect3DRMFrame2* iface,
779 LPDIRECT3DRMFRAME * frame)
781 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
783 FIXME("(%p/%p)->(%p): stub\n", iface, This, frame);
788 static D3DRMSORTMODE WINAPI IDirect3DRMFrame2Impl_GetSortMode(IDirect3DRMFrame2* iface)
790 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
792 FIXME("(%p/%p)->(): stub\n", iface, This);
794 return D3DRMSORT_FROMPARENT;
797 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetTexture(IDirect3DRMFrame2* iface,
798 LPDIRECT3DRMTEXTURE * tex)
800 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
802 FIXME("(%p/%p)->(%p): stub\n", iface, This, tex);
807 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetTransform(IDirect3DRMFrame2* iface,
808 D3DRMMATRIX4D return_matrix)
810 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
812 TRACE("(%p/%p)->(%p)\n", iface, This, return_matrix);
814 memcpy(return_matrix, This->transform, sizeof(D3DRMMATRIX4D));
819 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetVelocity(IDirect3DRMFrame2 *iface,
820 IDirect3DRMFrame *reference, D3DVECTOR *return_velocity, BOOL with_rotation)
822 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
824 FIXME("(%p/%p)->(%p,%p,%d): stub\n", iface, This, reference, return_velocity, with_rotation);
829 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetOrientation(IDirect3DRMFrame2 *iface,
830 IDirect3DRMFrame *reference, D3DVECTOR *dir, D3DVECTOR *up)
832 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
834 FIXME("(%p/%p)->(%p,%p,%p): stub\n", iface, This, reference, dir, up);
839 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetVisuals(IDirect3DRMFrame2* iface,
840 LPDIRECT3DRMVISUALARRAY *visuals)
842 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
843 IDirect3DRMVisualArrayImpl* obj;
846 TRACE("(%p/%p)->(%p)\n", iface, This, visuals);
849 return D3DRMERR_BADVALUE;
851 hr = Direct3DRMVisualArray_create(visuals);
856 obj = (IDirect3DRMVisualArrayImpl*)*visuals;
858 obj->size = This->nb_visuals;
859 if (This->nb_visuals)
862 obj->visuals = HeapAlloc(GetProcessHeap(), 0, This->nb_visuals * sizeof(LPDIRECT3DRMVISUAL));
864 return E_OUTOFMEMORY;
865 for (i = 0; i < This->nb_visuals; i++)
867 obj->visuals[i] = This->visuals[i];
868 IDirect3DRMVisual_AddRef(This->visuals[i]);
875 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetTextureTopology(IDirect3DRMFrame2* iface,
876 BOOL *wrap_u, BOOL *wrap_v)
878 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
880 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, wrap_u, wrap_v);
885 static HRESULT WINAPI IDirect3DRMFrame2Impl_InverseTransform(IDirect3DRMFrame2* iface,
886 D3DVECTOR *d, D3DVECTOR *s)
888 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
890 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, d, s);
895 static HRESULT WINAPI IDirect3DRMFrame2Impl_Load(IDirect3DRMFrame2* iface, LPVOID filename,
896 LPVOID name, D3DRMLOADOPTIONS loadflags,
897 D3DRMLOADTEXTURECALLBACK cb, LPVOID lpArg)
899 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
901 FIXME("(%p/%p)->(%p,%p,%u,%p,%p): stub\n", iface, This, filename, name, loadflags, cb, lpArg);
906 static HRESULT WINAPI IDirect3DRMFrame2Impl_LookAt(IDirect3DRMFrame2* iface,
907 LPDIRECT3DRMFRAME target,
908 LPDIRECT3DRMFRAME reference,
909 D3DRMFRAMECONSTRAINT constraint)
911 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
913 FIXME("(%p/%p)->(%p,%p,%u): stub\n", iface, This, target, reference, constraint);
918 static HRESULT WINAPI IDirect3DRMFrame2Impl_Move(IDirect3DRMFrame2* iface, D3DVALUE delta)
920 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
922 FIXME("(%p/%p)->(%f): stub\n", iface, This, delta);
927 static HRESULT WINAPI IDirect3DRMFrame2Impl_DeleteChild(IDirect3DRMFrame2* iface,
928 LPDIRECT3DRMFRAME frame)
930 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
931 IDirect3DRMFrame3 *child;
934 TRACE("(%p/%p)->(%p)\n", iface, This, frame);
937 return D3DRMERR_BADOBJECT;
938 hr = IDirect3DRMFrame_QueryInterface(frame, &IID_IDirect3DRMFrame3, (void**)&child);
940 return D3DRMERR_BADOBJECT;
941 IDirect3DRMFrame_Release(frame);
943 return IDirect3DRMFrame3_DeleteChild(&This->IDirect3DRMFrame3_iface, child);
946 static HRESULT WINAPI IDirect3DRMFrame2Impl_DeleteLight(IDirect3DRMFrame2* iface,
947 LPDIRECT3DRMLIGHT light)
949 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
951 TRACE("(%p/%p)->(%p)\n", iface, This, light);
953 return IDirect3DRMFrame3_DeleteLight(&This->IDirect3DRMFrame3_iface, light);
956 static HRESULT WINAPI IDirect3DRMFrame2Impl_DeleteMoveCallback(IDirect3DRMFrame2* iface,
957 D3DRMFRAMEMOVECALLBACK cb, VOID *arg)
959 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
961 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, cb, arg);
966 static HRESULT WINAPI IDirect3DRMFrame2Impl_DeleteVisual(IDirect3DRMFrame2* iface,
967 LPDIRECT3DRMVISUAL vis)
969 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
971 TRACE("(%p/%p)->(%p)\n", iface, This, vis);
973 return IDirect3DRMFrame3_DeleteVisual(&This->IDirect3DRMFrame3_iface, (LPUNKNOWN)vis);
976 static D3DCOLOR WINAPI IDirect3DRMFrame2Impl_GetSceneBackground(IDirect3DRMFrame2* iface)
978 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
980 TRACE("(%p/%p)->()\n", iface, This);
982 return IDirect3DRMFrame3_GetSceneBackground(&This->IDirect3DRMFrame3_iface);
985 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetSceneBackgroundDepth(IDirect3DRMFrame2 *iface,
986 IDirectDrawSurface **surface)
988 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
990 FIXME("(%p/%p)->(%p): stub\n", iface, This, surface);
995 static D3DCOLOR WINAPI IDirect3DRMFrame2Impl_GetSceneFogColor(IDirect3DRMFrame2* iface)
997 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
999 FIXME("(%p/%p)->(): stub\n", iface, This);
1004 static BOOL WINAPI IDirect3DRMFrame2Impl_GetSceneFogEnable(IDirect3DRMFrame2* iface)
1006 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1008 FIXME("(%p/%p)->(): stub\n", iface, This);
1013 static D3DRMFOGMODE WINAPI IDirect3DRMFrame2Impl_GetSceneFogMode(IDirect3DRMFrame2* iface)
1015 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1017 FIXME("(%p/%p)->(): stub\n", iface, This);
1019 return D3DRMFOG_LINEAR;
1022 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetSceneFogParams(IDirect3DRMFrame2* iface,
1023 D3DVALUE *return_start,
1024 D3DVALUE *return_end,
1025 D3DVALUE *return_density)
1027 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1029 FIXME("(%p/%p)->(%p,%p,%p): stub\n", iface, This, return_start, return_end, return_density);
1034 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetSceneBackground(IDirect3DRMFrame2* iface,
1037 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1039 TRACE("(%p/%p)->(%u)\n", iface, This, color);
1041 return IDirect3DRMFrame3_SetSceneBackground(&This->IDirect3DRMFrame3_iface, color);
1044 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetSceneBackgroundRGB(IDirect3DRMFrame2* iface,
1045 D3DVALUE red, D3DVALUE green,
1048 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1050 TRACE("(%p/%p)->(%f,%f,%f)\n", iface, This, red, green, blue);
1052 return IDirect3DRMFrame3_SetSceneBackgroundRGB(&This->IDirect3DRMFrame3_iface, red, green, blue);
1055 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetSceneBackgroundDepth(IDirect3DRMFrame2 *iface,
1056 IDirectDrawSurface *surface)
1058 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1060 FIXME("(%p/%p)->(%p): stub\n", iface, This, surface);
1065 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetSceneBackgroundImage(IDirect3DRMFrame2* iface,
1066 LPDIRECT3DRMTEXTURE texture)
1068 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1070 FIXME("(%p/%p)->(%p): stub\n", iface, This, texture);
1075 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetSceneFogEnable(IDirect3DRMFrame2* iface, BOOL enable)
1077 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1079 FIXME("(%p/%p)->(%d): stub\n", iface, This, enable);
1084 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetSceneFogColor(IDirect3DRMFrame2* iface,
1087 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1089 FIXME("(%p/%p)->(%u): stub\n", iface, This, color);
1094 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetSceneFogMode(IDirect3DRMFrame2* iface,
1097 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1099 FIXME("(%p/%p)->(%u): stub\n", iface, This, mode);
1104 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetSceneFogParams(IDirect3DRMFrame2* iface,
1105 D3DVALUE start, D3DVALUE end,
1108 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1110 FIXME("(%p/%p)->(%f,%f,%f): stub\n", iface, This, start, end, density);
1115 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetColor(IDirect3DRMFrame2* iface, D3DCOLOR color)
1117 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1119 FIXME("(%p/%p)->(%u): stub\n", iface, This, color);
1124 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetColorRGB(IDirect3DRMFrame2* iface, D3DVALUE red,
1125 D3DVALUE green, D3DVALUE blue)
1127 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1129 FIXME("(%p/%p)->(%f,%f,%f): stub\n", iface, This, red, green, blue);
1134 static D3DRMZBUFFERMODE WINAPI IDirect3DRMFrame2Impl_GetZbufferMode(IDirect3DRMFrame2* iface)
1136 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1138 FIXME("(%p/%p)->(): stub\n", iface, This);
1140 return D3DRMZBUFFER_FROMPARENT;
1143 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetMaterialMode(IDirect3DRMFrame2* iface,
1144 D3DRMMATERIALMODE mode)
1146 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1148 FIXME("(%p/%p)->(%u): stub\n", iface, This, mode);
1153 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetOrientation(IDirect3DRMFrame2* iface,
1154 LPDIRECT3DRMFRAME reference,
1155 D3DVALUE dx, D3DVALUE dy, D3DVALUE dz,
1156 D3DVALUE ux, D3DVALUE uy, D3DVALUE uz )
1158 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1160 FIXME("(%p/%p)->(%p,%f,%f,%f,%f,%f,%f): stub\n", iface, This, reference,
1161 dx, dy, dz, ux, uy, uz);
1166 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetPosition(IDirect3DRMFrame2* iface,
1167 LPDIRECT3DRMFRAME reference,
1168 D3DVALUE x, D3DVALUE y, D3DVALUE z)
1170 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1172 FIXME("(%p/%p)->(%p,%f,%f,%f): stub\n", iface, This, reference, x, y, z);
1177 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetRotation(IDirect3DRMFrame2* iface,
1178 LPDIRECT3DRMFRAME reference,
1179 D3DVALUE x, D3DVALUE y, D3DVALUE z,
1182 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1184 FIXME("(%p/%p)->(%p,%f,%f,%f,%f): stub\n", iface, This, reference, x, y, z, theta);
1189 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetSortMode(IDirect3DRMFrame2* iface,
1192 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1194 FIXME("(%p/%p)->(%u): stub\n", iface, This, mode);
1199 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetTexture(IDirect3DRMFrame2* iface,
1200 LPDIRECT3DRMTEXTURE texture)
1202 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1204 FIXME("(%p/%p)->(%p): stub\n", iface, This, texture);
1209 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetTextureTopology(IDirect3DRMFrame2* iface,
1210 BOOL wrap_u, BOOL wrap_v)
1212 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1214 FIXME("(%p/%p)->(%d,%d): stub\n", iface, This, wrap_u, wrap_v);
1219 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetVelocity(IDirect3DRMFrame2* iface,
1220 LPDIRECT3DRMFRAME reference,
1221 D3DVALUE x, D3DVALUE y, D3DVALUE z,
1224 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1226 FIXME("(%p/%p)->(%p,%f,%f,%f,%d): stub\n", iface, This, reference, x, y, z, with_rotation);
1231 static HRESULT WINAPI IDirect3DRMFrame2Impl_SetZbufferMode(IDirect3DRMFrame2* iface,
1232 D3DRMZBUFFERMODE mode)
1234 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1236 FIXME("(%p/%p)->(%u): stub\n", iface, This, mode);
1241 static HRESULT WINAPI IDirect3DRMFrame2Impl_Transform(IDirect3DRMFrame2* iface, D3DVECTOR *d,
1244 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1246 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, d, s);
1251 /*** IDirect3DRMFrame2 methods ***/
1252 static HRESULT WINAPI IDirect3DRMFrame2Impl_AddMoveCallback2(IDirect3DRMFrame2* iface,
1253 D3DRMFRAMEMOVECALLBACK cb, VOID *arg,
1256 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1258 FIXME("(%p/%p)->(%p,%p,%u): stub\n", iface, This, cb, arg, flags);
1263 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetBox(IDirect3DRMFrame2 *iface, D3DRMBOX *box)
1265 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1267 FIXME("(%p/%p)->(%p): stub\n", iface, This, box);
1272 static BOOL WINAPI IDirect3DRMFrame2Impl_GetBoxEnable(IDirect3DRMFrame2* iface)
1274 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1276 FIXME("(%p/%p)->(): stub\n", iface, This);
1281 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetAxes(IDirect3DRMFrame2 *iface,
1282 D3DVECTOR *dir, D3DVECTOR *up)
1284 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1286 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, dir, up);
1291 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetMaterial(IDirect3DRMFrame2* iface,
1292 LPDIRECT3DRMMATERIAL *material)
1294 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1296 FIXME("(%p/%p)->(%p): stub\n", iface, This, material);
1301 static BOOL WINAPI IDirect3DRMFrame2Impl_GetInheritAxes(IDirect3DRMFrame2* iface)
1303 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1305 FIXME("(%p/%p)->(): stub\n", iface, This);
1310 static HRESULT WINAPI IDirect3DRMFrame2Impl_GetHierarchyBox(IDirect3DRMFrame2 *iface, D3DRMBOX *box)
1312 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
1314 FIXME("(%p/%p)->(%p): stub\n", iface, This, box);
1319 static const struct IDirect3DRMFrame2Vtbl Direct3DRMFrame2_Vtbl =
1321 /*** IUnknown methods ***/
1322 IDirect3DRMFrame2Impl_QueryInterface,
1323 IDirect3DRMFrame2Impl_AddRef,
1324 IDirect3DRMFrame2Impl_Release,
1325 /*** IDirect3DRMObject methods ***/
1326 IDirect3DRMFrame2Impl_Clone,
1327 IDirect3DRMFrame2Impl_AddDestroyCallback,
1328 IDirect3DRMFrame2Impl_DeleteDestroyCallback,
1329 IDirect3DRMFrame2Impl_SetAppData,
1330 IDirect3DRMFrame2Impl_GetAppData,
1331 IDirect3DRMFrame2Impl_SetName,
1332 IDirect3DRMFrame2Impl_GetName,
1333 IDirect3DRMFrame2Impl_GetClassName,
1334 /*** IDirect3DRMFrame methods ***/
1335 IDirect3DRMFrame2Impl_AddChild,
1336 IDirect3DRMFrame2Impl_AddLight,
1337 IDirect3DRMFrame2Impl_AddMoveCallback,
1338 IDirect3DRMFrame2Impl_AddTransform,
1339 IDirect3DRMFrame2Impl_AddTranslation,
1340 IDirect3DRMFrame2Impl_AddScale,
1341 IDirect3DRMFrame2Impl_AddRotation,
1342 IDirect3DRMFrame2Impl_AddVisual,
1343 IDirect3DRMFrame2Impl_GetChildren,
1344 IDirect3DRMFrame2Impl_GetColor,
1345 IDirect3DRMFrame2Impl_GetLights,
1346 IDirect3DRMFrame2Impl_GetMaterialMode,
1347 IDirect3DRMFrame2Impl_GetParent,
1348 IDirect3DRMFrame2Impl_GetPosition,
1349 IDirect3DRMFrame2Impl_GetRotation,
1350 IDirect3DRMFrame2Impl_GetScene,
1351 IDirect3DRMFrame2Impl_GetSortMode,
1352 IDirect3DRMFrame2Impl_GetTexture,
1353 IDirect3DRMFrame2Impl_GetTransform,
1354 IDirect3DRMFrame2Impl_GetVelocity,
1355 IDirect3DRMFrame2Impl_GetOrientation,
1356 IDirect3DRMFrame2Impl_GetVisuals,
1357 IDirect3DRMFrame2Impl_GetTextureTopology,
1358 IDirect3DRMFrame2Impl_InverseTransform,
1359 IDirect3DRMFrame2Impl_Load,
1360 IDirect3DRMFrame2Impl_LookAt,
1361 IDirect3DRMFrame2Impl_Move,
1362 IDirect3DRMFrame2Impl_DeleteChild,
1363 IDirect3DRMFrame2Impl_DeleteLight,
1364 IDirect3DRMFrame2Impl_DeleteMoveCallback,
1365 IDirect3DRMFrame2Impl_DeleteVisual,
1366 IDirect3DRMFrame2Impl_GetSceneBackground,
1367 IDirect3DRMFrame2Impl_GetSceneBackgroundDepth,
1368 IDirect3DRMFrame2Impl_GetSceneFogColor,
1369 IDirect3DRMFrame2Impl_GetSceneFogEnable,
1370 IDirect3DRMFrame2Impl_GetSceneFogMode,
1371 IDirect3DRMFrame2Impl_GetSceneFogParams,
1372 IDirect3DRMFrame2Impl_SetSceneBackground,
1373 IDirect3DRMFrame2Impl_SetSceneBackgroundRGB,
1374 IDirect3DRMFrame2Impl_SetSceneBackgroundDepth,
1375 IDirect3DRMFrame2Impl_SetSceneBackgroundImage,
1376 IDirect3DRMFrame2Impl_SetSceneFogEnable,
1377 IDirect3DRMFrame2Impl_SetSceneFogColor,
1378 IDirect3DRMFrame2Impl_SetSceneFogMode,
1379 IDirect3DRMFrame2Impl_SetSceneFogParams,
1380 IDirect3DRMFrame2Impl_SetColor,
1381 IDirect3DRMFrame2Impl_SetColorRGB,
1382 IDirect3DRMFrame2Impl_GetZbufferMode,
1383 IDirect3DRMFrame2Impl_SetMaterialMode,
1384 IDirect3DRMFrame2Impl_SetOrientation,
1385 IDirect3DRMFrame2Impl_SetPosition,
1386 IDirect3DRMFrame2Impl_SetRotation,
1387 IDirect3DRMFrame2Impl_SetSortMode,
1388 IDirect3DRMFrame2Impl_SetTexture,
1389 IDirect3DRMFrame2Impl_SetTextureTopology,
1390 IDirect3DRMFrame2Impl_SetVelocity,
1391 IDirect3DRMFrame2Impl_SetZbufferMode,
1392 IDirect3DRMFrame2Impl_Transform,
1393 /*** IDirect3DRMFrame2 methods ***/
1394 IDirect3DRMFrame2Impl_AddMoveCallback2,
1395 IDirect3DRMFrame2Impl_GetBox,
1396 IDirect3DRMFrame2Impl_GetBoxEnable,
1397 IDirect3DRMFrame2Impl_GetAxes,
1398 IDirect3DRMFrame2Impl_GetMaterial,
1399 IDirect3DRMFrame2Impl_GetInheritAxes,
1400 IDirect3DRMFrame2Impl_GetHierarchyBox
1403 /*** IUnknown methods ***/
1404 static HRESULT WINAPI IDirect3DRMFrame3Impl_QueryInterface(IDirect3DRMFrame3* iface,
1405 REFIID riid, void** object)
1407 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1408 return IDirect3DRMFrame_QueryInterface(&This->IDirect3DRMFrame2_iface, riid, object);
1411 static ULONG WINAPI IDirect3DRMFrame3Impl_AddRef(IDirect3DRMFrame3* iface)
1413 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1414 return IDirect3DRMFrame2_AddRef(&This->IDirect3DRMFrame2_iface);
1417 static ULONG WINAPI IDirect3DRMFrame3Impl_Release(IDirect3DRMFrame3* iface)
1419 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1420 return IDirect3DRMFrame2_Release(&This->IDirect3DRMFrame2_iface);
1423 /*** IDirect3DRMObject methods ***/
1424 static HRESULT WINAPI IDirect3DRMFrame3Impl_Clone(IDirect3DRMFrame3* iface,
1425 LPUNKNOWN unkwn, REFIID riid,
1428 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1430 FIXME("(%p/%p)->(%p, %s, %p): stub\n", iface, This, unkwn, debugstr_guid(riid), object);
1435 static HRESULT WINAPI IDirect3DRMFrame3Impl_AddDestroyCallback(IDirect3DRMFrame3* iface,
1436 D3DRMOBJECTCALLBACK cb,
1439 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1441 FIXME("(%p/%p)->(%p, %p): stub\n", iface, This, cb, argument);
1446 static HRESULT WINAPI IDirect3DRMFrame3Impl_DeleteDestroyCallback(IDirect3DRMFrame3* iface,
1447 D3DRMOBJECTCALLBACK cb,
1450 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1452 FIXME("(%p/%p)->(%p, %p): stub\n", iface, This, cb, argument);
1457 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetAppData(IDirect3DRMFrame3* iface,
1460 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1462 FIXME("(%p/%p)->(%u): stub\n", iface, This, data);
1467 static DWORD WINAPI IDirect3DRMFrame3Impl_GetAppData(IDirect3DRMFrame3* iface)
1469 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1471 FIXME("(%p/%p)->(): stub\n", iface, This);
1476 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetName(IDirect3DRMFrame3* iface, LPCSTR name)
1478 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1480 FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
1485 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetName(IDirect3DRMFrame3* iface,
1486 LPDWORD size, LPSTR name)
1488 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1490 FIXME("(%p/%p)->(%p, %p): stub\n", iface, This, size, name);
1495 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetClassName(IDirect3DRMFrame3* iface,
1496 LPDWORD size, LPSTR name)
1498 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1500 TRACE("(%p/%p)->(%p, %p)\n", iface, This, size, name);
1502 if (!size || *size < strlen("Frame") || !name)
1503 return E_INVALIDARG;
1505 strcpy(name, "Frame");
1506 *size = sizeof("Frame");
1511 /*** IDirect3DRMFrame methods ***/
1512 static HRESULT WINAPI IDirect3DRMFrame3Impl_AddChild(IDirect3DRMFrame3* iface,
1513 LPDIRECT3DRMFRAME3 child)
1515 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1516 IDirect3DRMFrameImpl *child_obj = unsafe_impl_from_IDirect3DRMFrame3(child);
1518 TRACE("(%p/%p)->(%p)\n", iface, This, child);
1521 return D3DRMERR_BADOBJECT;
1523 if (child_obj->parent)
1525 IDirect3DRMFrame3* parent = &child_obj->parent->IDirect3DRMFrame3_iface;
1527 if (parent == iface)
1529 /* Passed frame is already a child so return success */
1534 /* Remove parent and continue */
1535 IDirect3DRMFrame3_DeleteChild(parent, child);
1539 if ((This->nb_children + 1) > This->children_capacity)
1542 IDirect3DRMFrame3** children;
1544 if (!This->children_capacity)
1547 children = HeapAlloc(GetProcessHeap(), 0, new_capacity * sizeof(IDirect3DRMFrame3*));
1551 new_capacity = This->children_capacity * 2;
1552 children = HeapReAlloc(GetProcessHeap(), 0, This->children, new_capacity * sizeof(IDirect3DRMFrame3*));
1556 return E_OUTOFMEMORY;
1558 This->children_capacity = new_capacity;
1559 This->children = children;
1562 This->children[This->nb_children++] = child;
1563 IDirect3DRMFrame3_AddRef(child);
1564 child_obj->parent = This;
1569 static HRESULT WINAPI IDirect3DRMFrame3Impl_AddLight(IDirect3DRMFrame3* iface,
1570 LPDIRECT3DRMLIGHT light)
1572 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1574 IDirect3DRMLight** lights;
1576 TRACE("(%p/%p)->(%p)\n", iface, This, light);
1579 return D3DRMERR_BADOBJECT;
1581 /* Check if already existing and return gracefully without increasing ref count */
1582 for (i = 0; i < This->nb_lights; i++)
1583 if (This->lights[i] == light)
1586 if ((This->nb_lights + 1) > This->lights_capacity)
1590 if (!This->lights_capacity)
1593 lights = HeapAlloc(GetProcessHeap(), 0, new_capacity * sizeof(IDirect3DRMLight*));
1597 new_capacity = This->lights_capacity * 2;
1598 lights = HeapReAlloc(GetProcessHeap(), 0, This->lights, new_capacity * sizeof(IDirect3DRMLight*));
1602 return E_OUTOFMEMORY;
1604 This->lights_capacity = new_capacity;
1605 This->lights = lights;
1608 This->lights[This->nb_lights++] = light;
1609 IDirect3DRMLight_AddRef(light);
1614 static HRESULT WINAPI IDirect3DRMFrame3Impl_AddMoveCallback(IDirect3DRMFrame3* iface,
1615 D3DRMFRAME3MOVECALLBACK cb, VOID *arg,
1618 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1620 FIXME("(%p/%p)->(%p,%p,%u): stub\n", iface, This, cb, arg, flags);
1625 static HRESULT WINAPI IDirect3DRMFrame3Impl_AddTransform(IDirect3DRMFrame3* iface,
1626 D3DRMCOMBINETYPE type,
1627 D3DRMMATRIX4D matrix)
1629 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1631 TRACE("(%p/%p)->(%u,%p)\n", iface, This, type, matrix);
1635 case D3DRMCOMBINE_REPLACE:
1636 memcpy(This->transform, matrix, sizeof(D3DRMMATRIX4D));
1639 case D3DRMCOMBINE_BEFORE:
1640 FIXME("D3DRMCOMBINE_BEFORE not supported yed\n");
1643 case D3DRMCOMBINE_AFTER:
1644 FIXME("D3DRMCOMBINE_AFTER not supported yed\n");
1648 WARN("Unknown Combine Type %u\n", type);
1649 return D3DRMERR_BADVALUE;
1655 static HRESULT WINAPI IDirect3DRMFrame3Impl_AddTranslation(IDirect3DRMFrame3* iface,
1656 D3DRMCOMBINETYPE type,
1657 D3DVALUE x, D3DVALUE y, D3DVALUE z)
1659 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1661 FIXME("(%p/%p)->(%u,%f,%f,%f): stub\n", iface, This, type, x, y, z);
1666 static HRESULT WINAPI IDirect3DRMFrame3Impl_AddScale(IDirect3DRMFrame3* iface,
1667 D3DRMCOMBINETYPE type,
1668 D3DVALUE sx, D3DVALUE sy, D3DVALUE sz)
1670 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1672 FIXME("(%p/%p)->(%u,%f,%f,%f): stub\n", iface, This, type, sx, sy, sz);
1677 static HRESULT WINAPI IDirect3DRMFrame3Impl_AddRotation(IDirect3DRMFrame3* iface,
1678 D3DRMCOMBINETYPE type,
1679 D3DVALUE x, D3DVALUE y, D3DVALUE z,
1682 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1684 FIXME("(%p/%p)->(%u,%f,%f,%f,%f): stub\n", iface, This, type, x, y, z, theta);
1689 static HRESULT WINAPI IDirect3DRMFrame3Impl_AddVisual(IDirect3DRMFrame3* iface, LPUNKNOWN vis)
1691 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1693 IDirect3DRMVisual** visuals;
1695 TRACE("(%p/%p)->(%p)\n", iface, This, vis);
1698 return D3DRMERR_BADOBJECT;
1700 /* Check if already existing and return gracefully without increasing ref count */
1701 for (i = 0; i < This->nb_visuals; i++)
1702 if (This->visuals[i] == (IDirect3DRMVisual*)vis)
1705 if ((This->nb_visuals + 1) > This->visuals_capacity)
1709 if (!This->visuals_capacity)
1712 visuals = HeapAlloc(GetProcessHeap(), 0, new_capacity * sizeof(IDirect3DRMVisual*));
1716 new_capacity = This->visuals_capacity * 2;
1717 visuals = HeapReAlloc(GetProcessHeap(), 0, This->visuals, new_capacity * sizeof(IDirect3DRMVisual*));
1721 return E_OUTOFMEMORY;
1723 This->visuals_capacity = new_capacity;
1724 This->visuals = visuals;
1727 This->visuals[This->nb_visuals++] = (IDirect3DRMVisual*)vis;
1728 IDirect3DRMVisual_AddRef(vis);
1733 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetChildren(IDirect3DRMFrame3* iface,
1734 LPDIRECT3DRMFRAMEARRAY *children)
1736 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1737 IDirect3DRMFrameArrayImpl* obj;
1740 TRACE("(%p/%p)->(%p)\n", iface, This, children);
1743 return D3DRMERR_BADVALUE;
1745 hr = Direct3DRMFrameArray_create(children);
1750 obj = (IDirect3DRMFrameArrayImpl*)*children;
1752 obj->size = This->nb_children;
1753 if (This->nb_children)
1756 obj->frames = HeapAlloc(GetProcessHeap(), 0, This->nb_children * sizeof(LPDIRECT3DRMFRAME));
1758 return E_OUTOFMEMORY;
1759 for (i = 0; i < This->nb_children; i++)
1760 IDirect3DRMFrame3_QueryInterface(This->children[i], &IID_IDirect3DRMFrame, (void**)&obj->frames[i]);
1766 static D3DCOLOR WINAPI IDirect3DRMFrame3Impl_GetColor(IDirect3DRMFrame3* iface)
1768 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1770 FIXME("(%p/%p)->(): stub\n", iface, This);
1775 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetLights(IDirect3DRMFrame3* iface,
1776 LPDIRECT3DRMLIGHTARRAY *lights)
1778 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1779 IDirect3DRMLightArrayImpl* obj;
1782 TRACE("(%p/%p)->(%p)\n", iface, This, lights);
1785 return D3DRMERR_BADVALUE;
1787 hr = Direct3DRMLightArray_create(lights);
1792 obj = (IDirect3DRMLightArrayImpl*)*lights;
1794 obj->size = This->nb_lights;
1795 if (This->nb_lights)
1798 obj->lights = HeapAlloc(GetProcessHeap(), 0, This->nb_lights * sizeof(LPDIRECT3DRMLIGHT));
1800 return E_OUTOFMEMORY;
1801 for (i = 0; i < This->nb_lights; i++)
1802 IDirect3DRMLight_QueryInterface(This->lights[i], &IID_IDirect3DRMLight, (void**)&obj->lights[i]);
1808 static D3DRMMATERIALMODE WINAPI IDirect3DRMFrame3Impl_GetMaterialMode(IDirect3DRMFrame3* iface)
1810 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1812 FIXME("(%p/%p)->(): stub\n", iface, This);
1814 return D3DRMMATERIAL_FROMPARENT;
1817 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetParent(IDirect3DRMFrame3* iface,
1818 LPDIRECT3DRMFRAME3 * frame)
1820 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1822 TRACE("(%p/%p)->(%p)\n", iface, This, frame);
1825 return D3DRMERR_BADVALUE;
1829 *frame = &This->parent->IDirect3DRMFrame3_iface;
1830 IDirect3DRMFrame_AddRef(*frame);
1840 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetPosition(IDirect3DRMFrame3 *iface,
1841 IDirect3DRMFrame3 *reference, D3DVECTOR *return_position)
1843 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1845 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, reference, return_position);
1850 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetRotation(IDirect3DRMFrame3 *iface,
1851 IDirect3DRMFrame3 *reference, D3DVECTOR *axis, D3DVALUE *return_theta)
1853 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1855 FIXME("(%p/%p)->(%p,%p,%p): stub\n", iface, This, reference, axis, return_theta);
1860 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetScene(IDirect3DRMFrame3* iface,
1861 LPDIRECT3DRMFRAME3 * frame)
1863 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1865 FIXME("(%p/%p)->(%p): stub\n", iface, This, frame);
1870 static D3DRMSORTMODE WINAPI IDirect3DRMFrame3Impl_GetSortMode(IDirect3DRMFrame3* iface)
1872 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1874 FIXME("(%p/%p)->(): stub\n", iface, This);
1876 return D3DRMSORT_FROMPARENT;
1879 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetTexture(IDirect3DRMFrame3* iface,
1880 LPDIRECT3DRMTEXTURE3 * tex)
1882 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1884 FIXME("(%p/%p)->(%p): stub\n", iface, This, tex);
1889 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetTransform(IDirect3DRMFrame3* iface,
1890 LPDIRECT3DRMFRAME3 reference,
1891 D3DRMMATRIX4D return_matrix)
1893 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1895 TRACE("(%p/%p)->(%p,%p)\n", iface, This, reference, return_matrix);
1898 FIXME("Specifying a frame as the root of the scene different from the current root frame is not supported yet\n");
1900 memcpy(return_matrix, This->transform, sizeof(D3DRMMATRIX4D));
1905 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetVelocity(IDirect3DRMFrame3 *iface,
1906 IDirect3DRMFrame3 *reference, D3DVECTOR *return_velocity, BOOL with_rotation)
1908 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1910 FIXME("(%p/%p)->(%p,%p,%d): stub\n", iface, This, reference, return_velocity, with_rotation);
1915 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetOrientation(IDirect3DRMFrame3 *iface,
1916 IDirect3DRMFrame3 *reference, D3DVECTOR *dir, D3DVECTOR *up)
1918 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1920 FIXME("(%p/%p)->(%p,%p,%p): stub\n", iface, This, reference, dir, up);
1925 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetVisuals(IDirect3DRMFrame3* iface, LPDWORD num,
1928 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1930 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, num, visuals);
1935 static HRESULT WINAPI IDirect3DRMFrame3Impl_InverseTransform(IDirect3DRMFrame3* iface,
1936 D3DVECTOR *d, D3DVECTOR *s)
1938 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1940 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, d, s);
1945 static HRESULT WINAPI IDirect3DRMFrame3Impl_Load(IDirect3DRMFrame3* iface, LPVOID filename,
1946 LPVOID name, D3DRMLOADOPTIONS loadflags,
1947 D3DRMLOADTEXTURE3CALLBACK cb, LPVOID lpArg)
1949 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1951 FIXME("(%p/%p)->(%p,%p,%u,%p,%p): stub\n", iface, This, filename, name, loadflags, cb, lpArg);
1956 static HRESULT WINAPI IDirect3DRMFrame3Impl_LookAt(IDirect3DRMFrame3* iface,
1957 LPDIRECT3DRMFRAME3 target,
1958 LPDIRECT3DRMFRAME3 reference,
1959 D3DRMFRAMECONSTRAINT constraint)
1961 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1963 FIXME("(%p/%p)->(%p,%p,%u): stub\n", iface, This, target, reference, constraint);
1968 static HRESULT WINAPI IDirect3DRMFrame3Impl_Move(IDirect3DRMFrame3* iface, D3DVALUE delta)
1970 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1972 FIXME("(%p/%p)->(%f): stub\n", iface, This, delta);
1977 static HRESULT WINAPI IDirect3DRMFrame3Impl_DeleteChild(IDirect3DRMFrame3* iface,
1978 LPDIRECT3DRMFRAME3 frame)
1980 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
1981 IDirect3DRMFrameImpl *frame_obj = unsafe_impl_from_IDirect3DRMFrame3(frame);
1984 TRACE("(%p/%p)->(%p)\n", iface, This, frame);
1987 return D3DRMERR_BADOBJECT;
1989 /* Check if child exists */
1990 for (i = 0; i < This->nb_children; i++)
1991 if (This->children[i] == frame)
1994 if (i == This->nb_children)
1995 return D3DRMERR_BADVALUE;
1997 memmove(This->children + i, This->children + i + 1, sizeof(IDirect3DRMFrame3*) * (This->nb_children - 1 - i));
1998 IDirect3DRMFrame3_Release(frame);
1999 frame_obj->parent = NULL;
2000 This->nb_children--;
2005 static HRESULT WINAPI IDirect3DRMFrame3Impl_DeleteLight(IDirect3DRMFrame3* iface,
2006 LPDIRECT3DRMLIGHT light)
2008 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2011 TRACE("(%p/%p)->(%p)\n", iface, This, light);
2014 return D3DRMERR_BADOBJECT;
2016 /* Check if visual exists */
2017 for (i = 0; i < This->nb_lights; i++)
2018 if (This->lights[i] == light)
2021 if (i == This->nb_lights)
2022 return D3DRMERR_BADVALUE;
2024 memmove(This->lights + i, This->lights + i + 1, sizeof(IDirect3DRMLight*) * (This->nb_lights - 1 - i));
2025 IDirect3DRMLight_Release(light);
2031 static HRESULT WINAPI IDirect3DRMFrame3Impl_DeleteMoveCallback(IDirect3DRMFrame3* iface,
2032 D3DRMFRAME3MOVECALLBACK cb,
2035 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2037 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, cb, arg);
2042 static HRESULT WINAPI IDirect3DRMFrame3Impl_DeleteVisual(IDirect3DRMFrame3* iface, LPUNKNOWN vis)
2044 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2047 TRACE("(%p/%p)->(%p)\n", iface, This, vis);
2050 return D3DRMERR_BADOBJECT;
2052 /* Check if visual exists */
2053 for (i = 0; i < This->nb_visuals; i++)
2054 if (This->visuals[i] == (IDirect3DRMVisual*)vis)
2057 if (i == This->nb_visuals)
2058 return D3DRMERR_BADVALUE;
2060 memmove(This->visuals + i, This->visuals + i + 1, sizeof(IDirect3DRMVisual*) * (This->nb_visuals - 1 - i));
2061 IDirect3DRMVisual_Release(vis);
2067 static D3DCOLOR WINAPI IDirect3DRMFrame3Impl_GetSceneBackground(IDirect3DRMFrame3* iface)
2069 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2071 TRACE("(%p/%p)->()\n", iface, This);
2073 return This->scenebackground;
2076 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetSceneBackgroundDepth(IDirect3DRMFrame3 *iface,
2077 IDirectDrawSurface **surface)
2079 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2081 FIXME("(%p/%p)->(%p): stub\n", iface, This, surface);
2086 static D3DCOLOR WINAPI IDirect3DRMFrame3Impl_GetSceneFogColor(IDirect3DRMFrame3* iface)
2088 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2090 FIXME("(%p/%p)->(): stub\n", iface, This);
2095 static BOOL WINAPI IDirect3DRMFrame3Impl_GetSceneFogEnable(IDirect3DRMFrame3* iface)
2097 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2099 FIXME("(%p/%p)->(): stub\n", iface, This);
2104 static D3DRMFOGMODE WINAPI IDirect3DRMFrame3Impl_GetSceneFogMode(IDirect3DRMFrame3* iface)
2106 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2108 FIXME("(%p/%p)->(): stub\n", iface, This);
2110 return D3DRMFOG_LINEAR;
2113 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetSceneFogParams(IDirect3DRMFrame3* iface,
2114 D3DVALUE *return_start,
2115 D3DVALUE *return_end,
2116 D3DVALUE *return_density)
2118 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2120 FIXME("(%p/%p)->(%p,%p,%p): stub\n", iface, This, return_start, return_end, return_density);
2125 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSceneBackground(IDirect3DRMFrame3* iface,
2128 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2130 TRACE("(%p/%p)->(%u)\n", iface, This, color);
2132 This->scenebackground = color;
2137 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSceneBackgroundRGB(IDirect3DRMFrame3* iface,
2138 D3DVALUE red, D3DVALUE green,
2141 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2143 TRACE("(%p/%p)->(%f,%f,%f)\n", iface, This, red, green, blue);
2145 This->scenebackground = D3DCOLOR_ARGB(0xff, (BYTE)(red * 255.0f),
2146 (BYTE)(green * 255.0f),
2147 (BYTE)(blue * 255.0f));
2152 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSceneBackgroundDepth(IDirect3DRMFrame3 *iface,
2153 IDirectDrawSurface *surface)
2155 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2157 FIXME("(%p/%p)->(%p): stub\n", iface, This, surface);
2162 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSceneBackgroundImage(IDirect3DRMFrame3* iface,
2163 LPDIRECT3DRMTEXTURE3 texture)
2165 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2167 FIXME("(%p/%p)->(%p): stub\n", iface, This, texture);
2172 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSceneFogEnable(IDirect3DRMFrame3* iface, BOOL enable)
2174 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2176 FIXME("(%p/%p)->(%d): stub\n", iface, This, enable);
2181 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSceneFogColor(IDirect3DRMFrame3* iface,
2184 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2186 FIXME("(%p/%p)->(%u): stub\n", iface, This, color);
2191 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSceneFogMode(IDirect3DRMFrame3* iface,
2194 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2196 FIXME("(%p/%p)->(%u): stub\n", iface, This, mode);
2201 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSceneFogParams(IDirect3DRMFrame3* iface,
2202 D3DVALUE start, D3DVALUE end,
2205 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2207 FIXME("(%p/%p)->(%f,%f,%f): stub\n", iface, This, start, end, density);
2212 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetColor(IDirect3DRMFrame3* iface, D3DCOLOR color)
2214 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2216 FIXME("(%p/%p)->(%u): stub\n", iface, This, color);
2221 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetColorRGB(IDirect3DRMFrame3* iface, D3DVALUE red,
2222 D3DVALUE green, D3DVALUE blue)
2224 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2226 FIXME("(%p/%p)->(%f,%f,%f): stub\n", iface, This, red, green, blue);
2231 static D3DRMZBUFFERMODE WINAPI IDirect3DRMFrame3Impl_GetZbufferMode(IDirect3DRMFrame3* iface)
2233 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2235 FIXME("(%p/%p)->(): stub\n", iface, This);
2237 return D3DRMZBUFFER_FROMPARENT;
2240 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetMaterialMode(IDirect3DRMFrame3* iface,
2241 D3DRMMATERIALMODE mode)
2243 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2245 FIXME("(%p/%p)->(%u): stub\n", iface, This, mode);
2250 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetOrientation(IDirect3DRMFrame3* iface,
2251 LPDIRECT3DRMFRAME3 reference,
2252 D3DVALUE dx, D3DVALUE dy, D3DVALUE dz,
2253 D3DVALUE ux, D3DVALUE uy, D3DVALUE uz )
2255 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2257 FIXME("(%p/%p)->(%p,%f,%f,%f,%f,%f,%f): stub\n", iface, This, reference,
2258 dx, dy, dz, ux, uy, uz);
2263 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetPosition(IDirect3DRMFrame3* iface,
2264 LPDIRECT3DRMFRAME3 reference,
2265 D3DVALUE x, D3DVALUE y, D3DVALUE z)
2267 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2269 FIXME("(%p/%p)->(%p,%f,%f,%f): stub\n", iface, This, reference, x, y, z);
2274 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetRotation(IDirect3DRMFrame3* iface,
2275 LPDIRECT3DRMFRAME3 reference,
2276 D3DVALUE x, D3DVALUE y, D3DVALUE z,
2279 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2281 FIXME("(%p/%p)->(%p,%f,%f,%f,%f): stub\n", iface, This, reference, x, y, z, theta);
2286 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSortMode(IDirect3DRMFrame3* iface,
2289 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2291 FIXME("(%p/%p)->(%u): stub\n", iface, This, mode);
2296 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetTexture(IDirect3DRMFrame3* iface,
2297 LPDIRECT3DRMTEXTURE3 texture)
2299 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2301 FIXME("(%p/%p)->(%p): stub\n", iface, This, texture);
2306 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetVelocity(IDirect3DRMFrame3* iface,
2307 LPDIRECT3DRMFRAME3 reference,
2308 D3DVALUE x, D3DVALUE y, D3DVALUE z,
2311 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2313 FIXME("(%p/%p)->(%p,%f,%f,%f,%d): stub\n", iface, This, reference, x, y, z, with_rotation);
2318 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetZbufferMode(IDirect3DRMFrame3* iface,
2319 D3DRMZBUFFERMODE mode)
2321 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2323 FIXME("(%p/%p)->(%u): stub\n", iface, This, mode);
2328 static HRESULT WINAPI IDirect3DRMFrame3Impl_Transform(IDirect3DRMFrame3* iface, D3DVECTOR *d,
2331 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2333 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, d, s);
2338 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetBox(IDirect3DRMFrame3 *iface, D3DRMBOX *box)
2340 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2342 FIXME("(%p/%p)->(%p): stub\n", iface, This, box);
2347 static BOOL WINAPI IDirect3DRMFrame3Impl_GetBoxEnable(IDirect3DRMFrame3* iface)
2349 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2351 FIXME("(%p/%p)->(): stub\n", iface, This);
2356 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetAxes(IDirect3DRMFrame3 *iface, D3DVECTOR *dir, D3DVECTOR *up)
2358 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2360 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, dir, up);
2365 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetMaterial(IDirect3DRMFrame3* iface,
2366 LPDIRECT3DRMMATERIAL2 *material)
2368 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2370 FIXME("(%p/%p)->(%p): stub\n", iface, This, material);
2375 static BOOL WINAPI IDirect3DRMFrame3Impl_GetInheritAxes(IDirect3DRMFrame3* iface)
2377 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2379 FIXME("(%p/%p)->(): stub\n", iface, This);
2384 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetHierarchyBox(IDirect3DRMFrame3* iface, D3DRMBOX *box)
2386 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2388 FIXME("(%p/%p)->(%p): stub\n", iface, This, box);
2393 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetBox(IDirect3DRMFrame3 *iface, D3DRMBOX *box)
2395 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2397 FIXME("(%p/%p)->(%p): stub\n", iface, This, box);
2402 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetBoxEnable(IDirect3DRMFrame3* iface, BOOL enable)
2404 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2406 FIXME("(%p/%p)->(%u): stub\n", iface, This, enable);
2411 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetAxes(IDirect3DRMFrame3* iface,
2412 D3DVALUE dx, D3DVALUE dy, D3DVALUE dz,
2413 D3DVALUE ux, D3DVALUE uy, D3DVALUE uz)
2415 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2417 FIXME("(%p/%p)->(%f,%f,%f,%f,%f,%f): stub\n", iface, This, dx, dy, dz, ux, uy, uz);
2422 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetInheritAxes(IDirect3DRMFrame3* iface,
2423 BOOL inherit_from_parent)
2425 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2427 FIXME("(%p/%p)->(%u): stub\n", iface, This, inherit_from_parent);
2432 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetMaterial(IDirect3DRMFrame3* iface,
2433 LPDIRECT3DRMMATERIAL2 material)
2435 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2437 FIXME("(%p/%p)->(%p): stub\n", iface, This, material);
2442 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetQuaternion(IDirect3DRMFrame3* iface,
2443 LPDIRECT3DRMFRAME3 reference,
2446 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2448 FIXME("(%p/%p)->(%p,%p): stub\n", iface, This, reference, q);
2453 static HRESULT WINAPI IDirect3DRMFrame3Impl_RayPick(IDirect3DRMFrame3 *iface, IDirect3DRMFrame3 *reference,
2454 D3DRMRAY *ray, DWORD flags, IDirect3DRMPicked2Array **return_visuals)
2456 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2458 FIXME("(%p/%p)->(%p,%p,%u,%p): stub\n", iface, This, reference, ray, flags, return_visuals);
2463 static HRESULT WINAPI IDirect3DRMFrame3Impl_Save(IDirect3DRMFrame3* iface, LPCSTR filename,
2464 D3DRMXOFFORMAT d3dFormat,
2465 D3DRMSAVEOPTIONS d3dSaveFlags)
2467 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2469 FIXME("(%p/%p)->(%p,%u,%u): stub\n", iface, This, filename, d3dFormat, d3dSaveFlags);
2474 static HRESULT WINAPI IDirect3DRMFrame3Impl_TransformVectors(IDirect3DRMFrame3 *iface,
2475 IDirect3DRMFrame3 *reference, DWORD num, D3DVECTOR *dst, D3DVECTOR *src)
2477 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2479 FIXME("(%p/%p)->(%p,%u,%p,%p): stub\n", iface, This, reference, num, dst, src);
2484 static HRESULT WINAPI IDirect3DRMFrame3Impl_InverseTransformVectors(IDirect3DRMFrame3 *iface,
2485 IDirect3DRMFrame3 *reference, DWORD num, D3DVECTOR *dst, D3DVECTOR *src)
2487 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2489 FIXME("(%p/%p)->(%p,%u,%p,%p): stub\n", iface, This, reference, num, dst, src);
2494 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetTraversalOptions(IDirect3DRMFrame3* iface,
2497 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2499 FIXME("(%p/%p)->(%u): stub\n", iface, This, flags);
2504 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetTraversalOptions(IDirect3DRMFrame3* iface,
2507 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2509 FIXME("(%p/%p)->(%p): stub\n", iface, This, flags);
2514 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetSceneFogMethod(IDirect3DRMFrame3* iface,
2517 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2519 FIXME("(%p/%p)->(%u): stub\n", iface, This, flags);
2524 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetSceneFogMethod(IDirect3DRMFrame3* iface,
2527 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2529 FIXME("(%p/%p)->(%p): stub\n", iface, This, flags);
2534 static HRESULT WINAPI IDirect3DRMFrame3Impl_SetMaterialOverride(IDirect3DRMFrame3 *iface,
2535 D3DRMMATERIALOVERRIDE *override)
2537 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2539 FIXME("(%p/%p)->(%p): stub\n", iface, This, override);
2544 static HRESULT WINAPI IDirect3DRMFrame3Impl_GetMaterialOverride(IDirect3DRMFrame3 *iface,
2545 D3DRMMATERIALOVERRIDE *override)
2547 IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
2549 FIXME("(%p/%p)->(%p): stub\n", iface, This, override);
2554 static const struct IDirect3DRMFrame3Vtbl Direct3DRMFrame3_Vtbl =
2556 /*** IUnknown methods ***/
2557 IDirect3DRMFrame3Impl_QueryInterface,
2558 IDirect3DRMFrame3Impl_AddRef,
2559 IDirect3DRMFrame3Impl_Release,
2560 /*** IDirect3DRMObject methods ***/
2561 IDirect3DRMFrame3Impl_Clone,
2562 IDirect3DRMFrame3Impl_AddDestroyCallback,
2563 IDirect3DRMFrame3Impl_DeleteDestroyCallback,
2564 IDirect3DRMFrame3Impl_SetAppData,
2565 IDirect3DRMFrame3Impl_GetAppData,
2566 IDirect3DRMFrame3Impl_SetName,
2567 IDirect3DRMFrame3Impl_GetName,
2568 IDirect3DRMFrame3Impl_GetClassName,
2569 /*** IDirect3DRMFrame3 methods ***/
2570 IDirect3DRMFrame3Impl_AddChild,
2571 IDirect3DRMFrame3Impl_AddLight,
2572 IDirect3DRMFrame3Impl_AddMoveCallback,
2573 IDirect3DRMFrame3Impl_AddTransform,
2574 IDirect3DRMFrame3Impl_AddTranslation,
2575 IDirect3DRMFrame3Impl_AddScale,
2576 IDirect3DRMFrame3Impl_AddRotation,
2577 IDirect3DRMFrame3Impl_AddVisual,
2578 IDirect3DRMFrame3Impl_GetChildren,
2579 IDirect3DRMFrame3Impl_GetColor,
2580 IDirect3DRMFrame3Impl_GetLights,
2581 IDirect3DRMFrame3Impl_GetMaterialMode,
2582 IDirect3DRMFrame3Impl_GetParent,
2583 IDirect3DRMFrame3Impl_GetPosition,
2584 IDirect3DRMFrame3Impl_GetRotation,
2585 IDirect3DRMFrame3Impl_GetScene,
2586 IDirect3DRMFrame3Impl_GetSortMode,
2587 IDirect3DRMFrame3Impl_GetTexture,
2588 IDirect3DRMFrame3Impl_GetTransform,
2589 IDirect3DRMFrame3Impl_GetVelocity,
2590 IDirect3DRMFrame3Impl_GetOrientation,
2591 IDirect3DRMFrame3Impl_GetVisuals,
2592 IDirect3DRMFrame3Impl_InverseTransform,
2593 IDirect3DRMFrame3Impl_Load,
2594 IDirect3DRMFrame3Impl_LookAt,
2595 IDirect3DRMFrame3Impl_Move,
2596 IDirect3DRMFrame3Impl_DeleteChild,
2597 IDirect3DRMFrame3Impl_DeleteLight,
2598 IDirect3DRMFrame3Impl_DeleteMoveCallback,
2599 IDirect3DRMFrame3Impl_DeleteVisual,
2600 IDirect3DRMFrame3Impl_GetSceneBackground,
2601 IDirect3DRMFrame3Impl_GetSceneBackgroundDepth,
2602 IDirect3DRMFrame3Impl_GetSceneFogColor,
2603 IDirect3DRMFrame3Impl_GetSceneFogEnable,
2604 IDirect3DRMFrame3Impl_GetSceneFogMode,
2605 IDirect3DRMFrame3Impl_GetSceneFogParams,
2606 IDirect3DRMFrame3Impl_SetSceneBackground,
2607 IDirect3DRMFrame3Impl_SetSceneBackgroundRGB,
2608 IDirect3DRMFrame3Impl_SetSceneBackgroundDepth,
2609 IDirect3DRMFrame3Impl_SetSceneBackgroundImage,
2610 IDirect3DRMFrame3Impl_SetSceneFogEnable,
2611 IDirect3DRMFrame3Impl_SetSceneFogColor,
2612 IDirect3DRMFrame3Impl_SetSceneFogMode,
2613 IDirect3DRMFrame3Impl_SetSceneFogParams,
2614 IDirect3DRMFrame3Impl_SetColor,
2615 IDirect3DRMFrame3Impl_SetColorRGB,
2616 IDirect3DRMFrame3Impl_GetZbufferMode,
2617 IDirect3DRMFrame3Impl_SetMaterialMode,
2618 IDirect3DRMFrame3Impl_SetOrientation,
2619 IDirect3DRMFrame3Impl_SetPosition,
2620 IDirect3DRMFrame3Impl_SetRotation,
2621 IDirect3DRMFrame3Impl_SetSortMode,
2622 IDirect3DRMFrame3Impl_SetTexture,
2623 IDirect3DRMFrame3Impl_SetVelocity,
2624 IDirect3DRMFrame3Impl_SetZbufferMode,
2625 IDirect3DRMFrame3Impl_Transform,
2626 IDirect3DRMFrame3Impl_GetBox,
2627 IDirect3DRMFrame3Impl_GetBoxEnable,
2628 IDirect3DRMFrame3Impl_GetAxes,
2629 IDirect3DRMFrame3Impl_GetMaterial,
2630 IDirect3DRMFrame3Impl_GetInheritAxes,
2631 IDirect3DRMFrame3Impl_GetHierarchyBox,
2632 IDirect3DRMFrame3Impl_SetBox,
2633 IDirect3DRMFrame3Impl_SetBoxEnable,
2634 IDirect3DRMFrame3Impl_SetAxes,
2635 IDirect3DRMFrame3Impl_SetInheritAxes,
2636 IDirect3DRMFrame3Impl_SetMaterial,
2637 IDirect3DRMFrame3Impl_SetQuaternion,
2638 IDirect3DRMFrame3Impl_RayPick,
2639 IDirect3DRMFrame3Impl_Save,
2640 IDirect3DRMFrame3Impl_TransformVectors,
2641 IDirect3DRMFrame3Impl_InverseTransformVectors,
2642 IDirect3DRMFrame3Impl_SetTraversalOptions,
2643 IDirect3DRMFrame3Impl_GetTraversalOptions,
2644 IDirect3DRMFrame3Impl_SetSceneFogMethod,
2645 IDirect3DRMFrame3Impl_GetSceneFogMethod,
2646 IDirect3DRMFrame3Impl_SetMaterialOverride,
2647 IDirect3DRMFrame3Impl_GetMaterialOverride
2650 static inline IDirect3DRMFrameImpl *unsafe_impl_from_IDirect3DRMFrame3(IDirect3DRMFrame3 *iface)
2654 assert(iface->lpVtbl == &Direct3DRMFrame3_Vtbl);
2656 return impl_from_IDirect3DRMFrame3(iface);
2659 HRESULT Direct3DRMFrame_create(REFIID riid, IUnknown* parent, IUnknown** ret_iface)
2661 IDirect3DRMFrameImpl* object;
2664 TRACE("(%s, %p, %p)\n", wine_dbgstr_guid(riid), parent, ret_iface);
2666 object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(IDirect3DRMFrameImpl));
2669 ERR("Out of memory\n");
2670 return E_OUTOFMEMORY;
2673 object->IDirect3DRMFrame2_iface.lpVtbl = &Direct3DRMFrame2_Vtbl;
2674 object->IDirect3DRMFrame3_iface.lpVtbl = &Direct3DRMFrame3_Vtbl;
2676 object->scenebackground = D3DCOLOR_ARGB(0xff, 0, 0, 0);
2678 memcpy(object->transform, identity, sizeof(D3DRMMATRIX4D));
2682 IDirect3DRMFrame3 *p;
2684 hr = IDirect3DRMFrame_QueryInterface(parent, &IID_IDirect3DRMFrame3, (void**)&p);
2687 HeapFree(GetProcessHeap(), 0, object);
2690 IDirect3DRMFrame_Release(parent);
2691 IDirect3DRMFrame3_AddChild(p, &object->IDirect3DRMFrame3_iface);
2694 hr = IDirect3DRMFrame3_QueryInterface(&object->IDirect3DRMFrame3_iface, riid, (void**)ret_iface);
2695 IDirect3DRMFrame3_Release(&object->IDirect3DRMFrame3_iface);