ReactOS 0.4.16-dev-329-g9223134
viewport.c File Reference
#include "d3drm_private.h"
Include dependency graph for viewport.c:

Go to the source code of this file.

Functions

 WINE_DEFAULT_DEBUG_CHANNEL (d3drm)
 
static struct d3drm_viewportimpl_from_IDirect3DRMViewport (IDirect3DRMViewport *iface)
 
static struct d3drm_viewportimpl_from_IDirect3DRMViewport2 (IDirect3DRMViewport2 *iface)
 
static void d3drm_normalize_d3d_color (D3DCOLORVALUE *color_value, D3DCOLOR color)
 
static HRESULT d3drm_update_background_material (struct d3drm_viewport *viewport)
 
static void d3drm_viewport_destroy (struct d3drm_viewport *viewport)
 
static HRESULT WINAPI d3drm_viewport2_QueryInterface (IDirect3DRMViewport2 *iface, REFIID riid, void **out)
 
static HRESULT WINAPI d3drm_viewport1_QueryInterface (IDirect3DRMViewport *iface, REFIID riid, void **out)
 
static ULONG WINAPI d3drm_viewport2_AddRef (IDirect3DRMViewport2 *iface)
 
static ULONG WINAPI d3drm_viewport1_AddRef (IDirect3DRMViewport *iface)
 
static ULONG WINAPI d3drm_viewport2_Release (IDirect3DRMViewport2 *iface)
 
static ULONG WINAPI d3drm_viewport1_Release (IDirect3DRMViewport *iface)
 
static HRESULT WINAPI d3drm_viewport2_Clone (IDirect3DRMViewport2 *iface, IUnknown *outer, REFIID iid, void **out)
 
static HRESULT WINAPI d3drm_viewport1_Clone (IDirect3DRMViewport *iface, IUnknown *outer, REFIID iid, void **out)
 
static HRESULT WINAPI d3drm_viewport2_AddDestroyCallback (IDirect3DRMViewport2 *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
 
static HRESULT WINAPI d3drm_viewport1_AddDestroyCallback (IDirect3DRMViewport *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
 
static HRESULT WINAPI d3drm_viewport2_DeleteDestroyCallback (IDirect3DRMViewport2 *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
 
static HRESULT WINAPI d3drm_viewport1_DeleteDestroyCallback (IDirect3DRMViewport *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
 
static HRESULT WINAPI d3drm_viewport2_SetAppData (IDirect3DRMViewport2 *iface, DWORD data)
 
static HRESULT WINAPI d3drm_viewport1_SetAppData (IDirect3DRMViewport *iface, DWORD data)
 
static DWORD WINAPI d3drm_viewport2_GetAppData (IDirect3DRMViewport2 *iface)
 
static DWORD WINAPI d3drm_viewport1_GetAppData (IDirect3DRMViewport *iface)
 
static HRESULT WINAPI d3drm_viewport2_SetName (IDirect3DRMViewport2 *iface, const char *name)
 
static HRESULT WINAPI d3drm_viewport1_SetName (IDirect3DRMViewport *iface, const char *name)
 
static HRESULT WINAPI d3drm_viewport2_GetName (IDirect3DRMViewport2 *iface, DWORD *size, char *name)
 
static HRESULT WINAPI d3drm_viewport1_GetName (IDirect3DRMViewport *iface, DWORD *size, char *name)
 
static HRESULT WINAPI d3drm_viewport2_GetClassName (IDirect3DRMViewport2 *iface, DWORD *size, char *name)
 
static HRESULT WINAPI d3drm_viewport1_GetClassName (IDirect3DRMViewport *iface, DWORD *size, char *name)
 
static HRESULT WINAPI d3drm_viewport2_Init (IDirect3DRMViewport2 *iface, IDirect3DRMDevice3 *device, IDirect3DRMFrame3 *camera, DWORD x, DWORD y, DWORD width, DWORD height)
 
static HRESULT WINAPI d3drm_viewport1_Init (IDirect3DRMViewport *iface, IDirect3DRMDevice *device, IDirect3DRMFrame *camera, DWORD x, DWORD y, DWORD width, DWORD height)
 
static HRESULT WINAPI d3drm_viewport2_Clear (IDirect3DRMViewport2 *iface, DWORD flags)
 
static HRESULT WINAPI d3drm_viewport1_Clear (IDirect3DRMViewport *iface)
 
static HRESULT WINAPI d3drm_viewport2_Render (IDirect3DRMViewport2 *iface, IDirect3DRMFrame3 *frame)
 
static HRESULT WINAPI d3drm_viewport1_Render (IDirect3DRMViewport *iface, IDirect3DRMFrame *frame)
 
static HRESULT WINAPI d3drm_viewport2_SetFront (IDirect3DRMViewport2 *iface, D3DVALUE front)
 
static HRESULT WINAPI d3drm_viewport1_SetFront (IDirect3DRMViewport *iface, D3DVALUE front)
 
static HRESULT WINAPI d3drm_viewport2_SetBack (IDirect3DRMViewport2 *iface, D3DVALUE back)
 
static HRESULT WINAPI d3drm_viewport1_SetBack (IDirect3DRMViewport *iface, D3DVALUE back)
 
static HRESULT WINAPI d3drm_viewport2_SetField (IDirect3DRMViewport2 *iface, D3DVALUE field)
 
static HRESULT WINAPI d3drm_viewport1_SetField (IDirect3DRMViewport *iface, D3DVALUE field)
 
static HRESULT WINAPI d3drm_viewport2_SetUniformScaling (IDirect3DRMViewport2 *iface, BOOL b)
 
static HRESULT WINAPI d3drm_viewport1_SetUniformScaling (IDirect3DRMViewport *iface, BOOL b)
 
static HRESULT WINAPI d3drm_viewport2_SetCamera (IDirect3DRMViewport2 *iface, IDirect3DRMFrame3 *camera)
 
static HRESULT WINAPI d3drm_viewport1_SetCamera (IDirect3DRMViewport *iface, IDirect3DRMFrame *camera)
 
static HRESULT WINAPI d3drm_viewport2_SetProjection (IDirect3DRMViewport2 *iface, D3DRMPROJECTIONTYPE type)
 
static HRESULT WINAPI d3drm_viewport1_SetProjection (IDirect3DRMViewport *iface, D3DRMPROJECTIONTYPE type)
 
static HRESULT WINAPI d3drm_viewport2_Transform (IDirect3DRMViewport2 *iface, D3DRMVECTOR4D *d, D3DVECTOR *s)
 
static HRESULT WINAPI d3drm_viewport1_Transform (IDirect3DRMViewport *iface, D3DRMVECTOR4D *d, D3DVECTOR *s)
 
static HRESULT WINAPI d3drm_viewport2_InverseTransform (IDirect3DRMViewport2 *iface, D3DVECTOR *d, D3DRMVECTOR4D *s)
 
static HRESULT WINAPI d3drm_viewport1_InverseTransform (IDirect3DRMViewport *iface, D3DVECTOR *d, D3DRMVECTOR4D *s)
 
static HRESULT WINAPI d3drm_viewport2_Configure (IDirect3DRMViewport2 *iface, LONG x, LONG y, DWORD width, DWORD height)
 
static HRESULT WINAPI d3drm_viewport1_Configure (IDirect3DRMViewport *iface, LONG x, LONG y, DWORD width, DWORD height)
 
static HRESULT WINAPI d3drm_viewport2_ForceUpdate (IDirect3DRMViewport2 *iface, DWORD x1, DWORD y1, DWORD x2, DWORD y2)
 
static HRESULT WINAPI d3drm_viewport1_ForceUpdate (IDirect3DRMViewport *iface, DWORD x1, DWORD y1, DWORD x2, DWORD y2)
 
static HRESULT WINAPI d3drm_viewport2_SetPlane (IDirect3DRMViewport2 *iface, D3DVALUE left, D3DVALUE right, D3DVALUE bottom, D3DVALUE top)
 
static HRESULT WINAPI d3drm_viewport1_SetPlane (IDirect3DRMViewport *iface, D3DVALUE left, D3DVALUE right, D3DVALUE bottom, D3DVALUE top)
 
static HRESULT WINAPI d3drm_viewport2_GetCamera (IDirect3DRMViewport2 *iface, IDirect3DRMFrame3 **camera)
 
static HRESULT WINAPI d3drm_viewport1_GetCamera (IDirect3DRMViewport *iface, IDirect3DRMFrame **camera)
 
static HRESULT WINAPI d3drm_viewport2_GetDevice (IDirect3DRMViewport2 *iface, IDirect3DRMDevice3 **device)
 
static HRESULT WINAPI d3drm_viewport1_GetDevice (IDirect3DRMViewport *iface, IDirect3DRMDevice **device)
 
static HRESULT WINAPI d3drm_viewport2_GetPlane (IDirect3DRMViewport2 *iface, D3DVALUE *left, D3DVALUE *right, D3DVALUE *bottom, D3DVALUE *top)
 
static HRESULT WINAPI d3drm_viewport1_GetPlane (IDirect3DRMViewport *iface, D3DVALUE *left, D3DVALUE *right, D3DVALUE *bottom, D3DVALUE *top)
 
static HRESULT WINAPI d3drm_viewport2_Pick (IDirect3DRMViewport2 *iface, LONG x, LONG y, IDirect3DRMPickedArray **visuals)
 
static HRESULT WINAPI d3drm_viewport1_Pick (IDirect3DRMViewport *iface, LONG x, LONG y, IDirect3DRMPickedArray **visuals)
 
static BOOL WINAPI d3drm_viewport2_GetUniformScaling (IDirect3DRMViewport2 *iface)
 
static BOOL WINAPI d3drm_viewport1_GetUniformScaling (IDirect3DRMViewport *iface)
 
static LONG WINAPI d3drm_viewport2_GetX (IDirect3DRMViewport2 *iface)
 
static LONG WINAPI d3drm_viewport1_GetX (IDirect3DRMViewport *iface)
 
static LONG WINAPI d3drm_viewport2_GetY (IDirect3DRMViewport2 *iface)
 
static LONG WINAPI d3drm_viewport1_GetY (IDirect3DRMViewport *iface)
 
static DWORD WINAPI d3drm_viewport2_GetWidth (IDirect3DRMViewport2 *iface)
 
static DWORD WINAPI d3drm_viewport1_GetWidth (IDirect3DRMViewport *iface)
 
static DWORD WINAPI d3drm_viewport2_GetHeight (IDirect3DRMViewport2 *iface)
 
static DWORD WINAPI d3drm_viewport1_GetHeight (IDirect3DRMViewport *iface)
 
static D3DVALUE WINAPI d3drm_viewport2_GetField (IDirect3DRMViewport2 *iface)
 
static D3DVALUE WINAPI d3drm_viewport1_GetField (IDirect3DRMViewport *iface)
 
static D3DVALUE WINAPI d3drm_viewport2_GetBack (IDirect3DRMViewport2 *iface)
 
static D3DVALUE WINAPI d3drm_viewport1_GetBack (IDirect3DRMViewport *iface)
 
static D3DVALUE WINAPI d3drm_viewport2_GetFront (IDirect3DRMViewport2 *iface)
 
static D3DVALUE WINAPI d3drm_viewport1_GetFront (IDirect3DRMViewport *iface)
 
static D3DRMPROJECTIONTYPE WINAPI d3drm_viewport2_GetProjection (IDirect3DRMViewport2 *iface)
 
static D3DRMPROJECTIONTYPE WINAPI d3drm_viewport1_GetProjection (IDirect3DRMViewport *iface)
 
static HRESULT WINAPI d3drm_viewport2_GetDirect3DViewport (IDirect3DRMViewport2 *iface, IDirect3DViewport **viewport)
 
static HRESULT WINAPI d3drm_viewport1_GetDirect3DViewport (IDirect3DRMViewport *iface, IDirect3DViewport **viewport)
 
static HRESULT WINAPI d3drm_viewport2_TransformVectors (IDirect3DRMViewport2 *iface, DWORD vector_count, D3DRMVECTOR4D *dst, D3DVECTOR *src)
 
static HRESULT WINAPI d3drm_viewport2_InverseTransformVectors (IDirect3DRMViewport2 *iface, DWORD vector_count, D3DVECTOR *dst, D3DRMVECTOR4D *src)
 
HRESULT d3drm_viewport_create (struct d3drm_viewport **viewport, IDirect3DRM *d3drm)
 

Variables

static const struct IDirect3DRMViewport2Vtbl d3drm_viewport2_vtbl
 
static const struct IDirect3DRMViewportVtbl d3drm_viewport1_vtbl
 

Function Documentation

◆ d3drm_normalize_d3d_color()

static void d3drm_normalize_d3d_color ( D3DCOLORVALUE color_value,
D3DCOLOR  color 
)
inlinestatic

Definition at line 35 of file viewport.c.

36{
37 color_value->u1.r = RGBA_GETRED(color) / 255.0f;
38 color_value->u2.g = RGBA_GETGREEN(color) / 255.0f;
39 color_value->u3.b = RGBA_GETBLUE(color) / 255.0f;
40 color_value->u4.a = RGBA_GETALPHA(color) / 255.0f;
41}
#define RGBA_GETRED(rgb)
Definition: d3dtypes.h:58
#define RGBA_GETGREEN(rgb)
Definition: d3dtypes.h:59
#define RGBA_GETALPHA(rgb)
Definition: d3dtypes.h:57
#define RGBA_GETBLUE(rgb)
Definition: d3dtypes.h:60
GLuint color
Definition: glext.h:6243

Referenced by d3drm_update_background_material().

◆ d3drm_update_background_material()

static HRESULT d3drm_update_background_material ( struct d3drm_viewport viewport)
static

Definition at line 43 of file viewport.c.

44{
45 IDirect3DRMFrame *root_frame;
48 HRESULT hr;
49
50 if (FAILED(hr = IDirect3DRMFrame_GetScene(viewport->camera, &root_frame)))
51 return hr;
53 IDirect3DRMFrame_Release(root_frame);
54
55 memset(&mat, 0, sizeof(mat));
56 mat.dwSize = sizeof(mat);
58
59 return IDirect3DMaterial_SetMaterial(viewport->material, &mat);
60}
#define IDirect3DMaterial_SetMaterial(p, a)
Definition: d3d.h:467
static void d3drm_normalize_d3d_color(D3DCOLORVALUE *color_value, D3DCOLOR color)
Definition: viewport.c:35
#define IDirect3DRMFrame_Release(p)
Definition: d3drmobj.h:1168
#define IDirect3DRMFrame_GetSceneBackground(p)
Definition: d3drmobj.h:1210
#define IDirect3DRMFrame_GetScene(p, a)
Definition: d3drmobj.h:1194
#define FAILED(hr)
Definition: intsafe.h:51
static const MAT2 mat
Definition: font.c:66
#define memset(x, y, z)
Definition: compat.h:39
HRESULT hr
Definition: shlfolder.c:183
IDirect3DRMFrame * camera
IDirect3DMaterial * material

Referenced by d3drm_viewport2_Clear().

◆ d3drm_viewport1_AddDestroyCallback()

static HRESULT WINAPI d3drm_viewport1_AddDestroyCallback ( IDirect3DRMViewport *  iface,
D3DRMOBJECTCALLBACK  cb,
void ctx 
)
static

Definition at line 182 of file viewport.c.

184{
185 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
186
187 TRACE("iface %p, cb %p, ctx %p\n", iface, cb, ctx);
188
190}
static HRESULT WINAPI d3drm_viewport2_AddDestroyCallback(IDirect3DRMViewport2 *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
Definition: viewport.c:172
static struct d3drm_viewport * impl_from_IDirect3DRMViewport(IDirect3DRMViewport *iface)
Definition: viewport.c:25
static HMODULE MODULEINFO DWORD cb
Definition: module.c:33
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRMViewport2 IDirect3DRMViewport2_iface

◆ d3drm_viewport1_AddRef()

static ULONG WINAPI d3drm_viewport1_AddRef ( IDirect3DRMViewport *  iface)
static

Definition at line 125 of file viewport.c.

126{
127 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
128
129 TRACE("iface %p.\n", iface);
130
132}
static ULONG WINAPI d3drm_viewport2_AddRef(IDirect3DRMViewport2 *iface)
Definition: viewport.c:115

◆ d3drm_viewport1_Clear()

static HRESULT WINAPI d3drm_viewport1_Clear ( IDirect3DRMViewport *  iface)
static

Definition at line 464 of file viewport.c.

465{
466 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
467
468 TRACE("iface %p.\n", iface);
469
471}
static HRESULT WINAPI d3drm_viewport2_Clear(IDirect3DRMViewport2 *iface, DWORD flags)
Definition: viewport.c:426
#define D3DRMCLEAR_ALL
Definition: d3drmdef.h:313

◆ d3drm_viewport1_Clone()

static HRESULT WINAPI d3drm_viewport1_Clone ( IDirect3DRMViewport *  iface,
IUnknown outer,
REFIID  iid,
void **  out 
)
static

Definition at line 164 of file viewport.c.

166{
167 FIXME("iface %p, outer %p, iid %s, out %p stub!\n", iface, outer, debugstr_guid(iid), out);
168
169 return E_NOTIMPL;
170}
#define FIXME(fmt,...)
Definition: precomp.h:53
#define E_NOTIMPL
Definition: ddrawi.h:99
#define debugstr_guid
Definition: kernel32.h:35
static FILE * out
Definition: regtests2xml.c:44

◆ d3drm_viewport1_Configure()

static HRESULT WINAPI d3drm_viewport1_Configure ( IDirect3DRMViewport *  iface,
LONG  x,
LONG  y,
DWORD  width,
DWORD  height 
)
static

Definition at line 666 of file viewport.c.

668{
669 FIXME("iface %p, x %d, y %d, width %u, height %u stub!\n", iface, x, y, width, height);
670
671 return E_NOTIMPL;
672}
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
GLint GLint GLsizei width
Definition: gl.h:1546

◆ d3drm_viewport1_DeleteDestroyCallback()

static HRESULT WINAPI d3drm_viewport1_DeleteDestroyCallback ( IDirect3DRMViewport *  iface,
D3DRMOBJECTCALLBACK  cb,
void ctx 
)
static

Definition at line 202 of file viewport.c.

204{
205 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
206
207 TRACE("iface %p, cb %p, ctx %p\n", iface, cb, ctx);
208
210}
static HRESULT WINAPI d3drm_viewport2_DeleteDestroyCallback(IDirect3DRMViewport2 *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
Definition: viewport.c:192

◆ d3drm_viewport1_ForceUpdate()

static HRESULT WINAPI d3drm_viewport1_ForceUpdate ( IDirect3DRMViewport *  iface,
DWORD  x1,
DWORD  y1,
DWORD  x2,
DWORD  y2 
)
static

Definition at line 682 of file viewport.c.

684{
685 FIXME("iface %p, x1 %u, y1 %u, x2 %u, y2 %u stub!\n", iface, x1, y1, x2, y2);
686
687 return E_NOTIMPL;
688}
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG _In_ LONG _In_ LONG x2
Definition: winddi.h:3710
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG _In_ LONG y1
Definition: winddi.h:3709
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG x1
Definition: winddi.h:3708
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG _In_ LONG _In_ LONG _In_ LONG y2
Definition: winddi.h:3711

◆ d3drm_viewport1_GetAppData()

static DWORD WINAPI d3drm_viewport1_GetAppData ( IDirect3DRMViewport *  iface)
static

Definition at line 240 of file viewport.c.

241{
242 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
243
244 TRACE("iface %p.\n", iface);
245
247}
static DWORD WINAPI d3drm_viewport2_GetAppData(IDirect3DRMViewport2 *iface)
Definition: viewport.c:231

◆ d3drm_viewport1_GetBack()

static D3DVALUE WINAPI d3drm_viewport1_GetBack ( IDirect3DRMViewport *  iface)
static

Definition at line 942 of file viewport.c.

943{
944 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
945
946 TRACE("iface %p.\n", iface);
947
949}
static D3DVALUE WINAPI d3drm_viewport2_GetBack(IDirect3DRMViewport2 *iface)
Definition: viewport.c:930

◆ d3drm_viewport1_GetCamera()

static HRESULT WINAPI d3drm_viewport1_GetCamera ( IDirect3DRMViewport *  iface,
IDirect3DRMFrame **  camera 
)
static

Definition at line 735 of file viewport.c.

736{
737 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
738 struct d3drm_frame *camera_impl;
739 IDirect3DRMFrame3 *camera3;
740 HRESULT hr;
741
742 TRACE("iface %p, camera %p.\n", iface, camera);
743
744 if (!camera)
745 return D3DRMERR_BADVALUE;
746
748 return hr;
749
750 camera_impl = unsafe_impl_from_IDirect3DRMFrame3(camera3);
751 *camera = &camera_impl->IDirect3DRMFrame_iface;
752
753 return D3DRM_OK;
754}
static HRESULT WINAPI d3drm_viewport2_GetCamera(IDirect3DRMViewport2 *iface, IDirect3DRMFrame3 **camera)
Definition: viewport.c:720
#define D3DRM_OK
Definition: d3drm.h:486
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
struct d3drm_frame * unsafe_impl_from_IDirect3DRMFrame3(IDirect3DRMFrame3 *iface) DECLSPEC_HIDDEN
Definition: frame.c:3111
IDirect3DRMFrame IDirect3DRMFrame_iface
Definition: d3drm_private.h:72

◆ d3drm_viewport1_GetClassName()

static HRESULT WINAPI d3drm_viewport1_GetClassName ( IDirect3DRMViewport *  iface,
DWORD size,
char name 
)
static

Definition at line 294 of file viewport.c.

295{
296 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
297
298 TRACE("iface %p, size %p, name %p.\n", iface, size, name);
299
301}
static HRESULT WINAPI d3drm_viewport2_GetClassName(IDirect3DRMViewport2 *iface, DWORD *size, char *name)
Definition: viewport.c:285
GLsizeiptr size
Definition: glext.h:5919
Definition: name.c:39

◆ d3drm_viewport1_GetDevice()

static HRESULT WINAPI d3drm_viewport1_GetDevice ( IDirect3DRMViewport *  iface,
IDirect3DRMDevice **  device 
)
static

Definition at line 774 of file viewport.c.

775{
776 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
777
778 TRACE("iface %p, device %p.\n\n", iface, device);
779
780 if (!device)
781 return D3DRMERR_BADVALUE;
782
783 if (!viewport->device)
784 return D3DRMERR_BADOBJECT;
785
786 *device = &viewport->device->IDirect3DRMDevice_iface;
788
789 return D3DRM_OK;
790}
#define D3DRMERR_BADOBJECT
Definition: d3drm.h:487
#define IDirect3DRMDevice_AddRef(p)
Definition: d3drmobj.h:408
struct d3drm_device * device
Definition: devices.h:37

◆ d3drm_viewport1_GetDirect3DViewport()

static HRESULT WINAPI d3drm_viewport1_GetDirect3DViewport ( IDirect3DRMViewport *  iface,
IDirect3DViewport **  viewport 
)
static

Definition at line 1009 of file viewport.c.

1011{
1012 struct d3drm_viewport *viewport_object = impl_from_IDirect3DRMViewport(iface);
1013
1014 TRACE("iface %p, viewport %p.\n", iface, viewport);
1015
1016 return d3drm_viewport2_GetDirect3DViewport(&viewport_object->IDirect3DRMViewport2_iface, viewport);
1017}
static HRESULT WINAPI d3drm_viewport2_GetDirect3DViewport(IDirect3DRMViewport2 *iface, IDirect3DViewport **viewport)
Definition: viewport.c:990

◆ d3drm_viewport1_GetField()

static D3DVALUE WINAPI d3drm_viewport1_GetField ( IDirect3DRMViewport *  iface)
static

Definition at line 921 of file viewport.c.

922{
923 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
924
925 TRACE("iface %p.\n", iface);
926
928}
static D3DVALUE WINAPI d3drm_viewport2_GetField(IDirect3DRMViewport2 *iface)
Definition: viewport.c:908

◆ d3drm_viewport1_GetFront()

static D3DVALUE WINAPI d3drm_viewport1_GetFront ( IDirect3DRMViewport *  iface)
static

Definition at line 963 of file viewport.c.

964{
965 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
966
967 TRACE("iface %p.\n", iface);
968
970}
static D3DVALUE WINAPI d3drm_viewport2_GetFront(IDirect3DRMViewport2 *iface)
Definition: viewport.c:951

◆ d3drm_viewport1_GetHeight()

static DWORD WINAPI d3drm_viewport1_GetHeight ( IDirect3DRMViewport *  iface)
static

Definition at line 901 of file viewport.c.

902{
903 FIXME("iface %p stub!\n", iface);
904
905 return E_NOTIMPL;
906}

◆ d3drm_viewport1_GetName()

static HRESULT WINAPI d3drm_viewport1_GetName ( IDirect3DRMViewport *  iface,
DWORD size,
char name 
)
static

Definition at line 276 of file viewport.c.

277{
278 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
279
280 TRACE("iface %p, size %p, name %p.\n", iface, size, name);
281
283}
static HRESULT WINAPI d3drm_viewport2_GetName(IDirect3DRMViewport2 *iface, DWORD *size, char *name)
Definition: viewport.c:267

◆ d3drm_viewport1_GetPlane()

static HRESULT WINAPI d3drm_viewport1_GetPlane ( IDirect3DRMViewport *  iface,
D3DVALUE left,
D3DVALUE right,
D3DVALUE bottom,
D3DVALUE top 
)
static

Definition at line 811 of file viewport.c.

813{
814 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
815
816 TRACE("iface %p, left %p, right %p, bottom %p, top %p.\n",
817 iface, left, right, bottom, top);
818
820}
static HRESULT WINAPI d3drm_viewport2_GetPlane(IDirect3DRMViewport2 *iface, D3DVALUE *left, D3DVALUE *right, D3DVALUE *bottom, D3DVALUE *top)
Definition: viewport.c:792
GLdouble GLdouble GLdouble GLdouble top
Definition: glext.h:10859
GLdouble GLdouble right
Definition: glext.h:10859
GLint left
Definition: glext.h:7726
GLint GLint bottom
Definition: glext.h:7726

◆ d3drm_viewport1_GetProjection()

static D3DRMPROJECTIONTYPE WINAPI d3drm_viewport1_GetProjection ( IDirect3DRMViewport *  iface)
static

Definition at line 981 of file viewport.c.

982{
983 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
984
985 TRACE("iface %p.\n", iface);
986
988}
static D3DRMPROJECTIONTYPE WINAPI d3drm_viewport2_GetProjection(IDirect3DRMViewport2 *iface)
Definition: viewport.c:972

◆ d3drm_viewport1_GetUniformScaling()

static BOOL WINAPI d3drm_viewport1_GetUniformScaling ( IDirect3DRMViewport *  iface)
static

Definition at line 845 of file viewport.c.

846{
847 FIXME("iface %p stub!\n", iface);
848
849 return FALSE;
850}
#define FALSE
Definition: types.h:117

◆ d3drm_viewport1_GetWidth()

static DWORD WINAPI d3drm_viewport1_GetWidth ( IDirect3DRMViewport *  iface)
static

Definition at line 887 of file viewport.c.

888{
889 FIXME("iface %p stub!\n", iface);
890
891 return E_NOTIMPL;
892}

◆ d3drm_viewport1_GetX()

static LONG WINAPI d3drm_viewport1_GetX ( IDirect3DRMViewport *  iface)
static

Definition at line 859 of file viewport.c.

860{
861 FIXME("iface %p stub!\n", iface);
862
863 return E_NOTIMPL;
864}

◆ d3drm_viewport1_GetY()

static LONG WINAPI d3drm_viewport1_GetY ( IDirect3DRMViewport *  iface)
static

Definition at line 873 of file viewport.c.

874{
875 FIXME("iface %p stub!\n", iface);
876
877 return E_NOTIMPL;
878}

◆ d3drm_viewport1_Init()

static HRESULT WINAPI d3drm_viewport1_Init ( IDirect3DRMViewport *  iface,
IDirect3DRMDevice *  device,
IDirect3DRMFrame *  camera,
DWORD  x,
DWORD  y,
DWORD  width,
DWORD  height 
)
static

Definition at line 402 of file viewport.c.

404{
405 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
406 struct d3drm_frame *frame = unsafe_impl_from_IDirect3DRMFrame(camera);
407 IDirect3DRMDevice3 *device3;
408 HRESULT hr;
409
410 TRACE("iface %p, device %p, camera %p, x %u, y %u, width %u, height %u.\n",
411 iface, device, camera, x, y, width, height);
412
413 if (!device || !frame)
414 return D3DRMERR_BADOBJECT;
415
416 if (FAILED(hr = IDirect3DRMDevice_QueryInterface(device, &IID_IDirect3DRMDevice3, (void **)&device3)))
417 return hr;
418
420 x, y, width, height);
422
423 return hr;
424}
static HRESULT WINAPI d3drm_viewport2_Init(IDirect3DRMViewport2 *iface, IDirect3DRMDevice3 *device, IDirect3DRMFrame3 *camera, DWORD x, DWORD y, DWORD width, DWORD height)
Definition: viewport.c:303
struct d3drm_frame * unsafe_impl_from_IDirect3DRMFrame(IDirect3DRMFrame *iface) DECLSPEC_HIDDEN
Definition: frame.c:3120
#define IDirect3DRMDevice3_Release(p)
Definition: d3drmobj.h:693
#define IDirect3DRMDevice_QueryInterface(p, a, b)
Definition: d3drmobj.h:407
IDirect3DRMFrame3 IDirect3DRMFrame3_iface
Definition: d3drm_private.h:74

◆ d3drm_viewport1_InverseTransform()

static HRESULT WINAPI d3drm_viewport1_InverseTransform ( IDirect3DRMViewport *  iface,
D3DVECTOR d,
D3DRMVECTOR4D s 
)
static

Definition at line 651 of file viewport.c.

652{
653 FIXME("iface %p, d %p, s %p stub!\n", iface, d, s);
654
655 return E_NOTIMPL;
656}
GLdouble s
Definition: gl.h:2039
#define d
Definition: ke_i.h:81

◆ d3drm_viewport1_Pick()

static HRESULT WINAPI d3drm_viewport1_Pick ( IDirect3DRMViewport *  iface,
LONG  x,
LONG  y,
IDirect3DRMPickedArray **  visuals 
)
static

Definition at line 830 of file viewport.c.

832{
833 FIXME("iface %p, x %d, y %d, visuals %p stub!\n", iface, x, y, visuals);
834
835 return E_NOTIMPL;
836}

◆ d3drm_viewport1_QueryInterface()

static HRESULT WINAPI d3drm_viewport1_QueryInterface ( IDirect3DRMViewport *  iface,
REFIID  riid,
void **  out 
)
static

Definition at line 106 of file viewport.c.

107{
108 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
109
110 TRACE("iface %p, riid %s, out %p.\n", iface, debugstr_guid(riid), out);
111
113}
static HRESULT WINAPI d3drm_viewport2_QueryInterface(IDirect3DRMViewport2 *iface, REFIID riid, void **out)
Definition: viewport.c:79
REFIID riid
Definition: atlbase.h:39

◆ d3drm_viewport1_Release()

static ULONG WINAPI d3drm_viewport1_Release ( IDirect3DRMViewport *  iface)
static

Definition at line 147 of file viewport.c.

148{
149 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
150
151 TRACE("iface %p.\n", iface);
152
154}
static ULONG WINAPI d3drm_viewport2_Release(IDirect3DRMViewport2 *iface)
Definition: viewport.c:134

◆ d3drm_viewport1_Render()

static HRESULT WINAPI d3drm_viewport1_Render ( IDirect3DRMViewport *  iface,
IDirect3DRMFrame *  frame 
)
static

Definition at line 480 of file viewport.c.

481{
482 FIXME("iface %p, frame %p stub!\n", iface, frame);
483
484 return D3DRM_OK;
485}

◆ d3drm_viewport1_SetAppData()

static HRESULT WINAPI d3drm_viewport1_SetAppData ( IDirect3DRMViewport *  iface,
DWORD  data 
)
static

Definition at line 222 of file viewport.c.

223{
224 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
225
226 TRACE("iface %p, data %#x\n", iface, data);
227
229}
static HRESULT WINAPI d3drm_viewport2_SetAppData(IDirect3DRMViewport2 *iface, DWORD data)
Definition: viewport.c:212
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950

◆ d3drm_viewport1_SetBack()

static HRESULT WINAPI d3drm_viewport1_SetBack ( IDirect3DRMViewport *  iface,
D3DVALUE  back 
)
static

Definition at line 530 of file viewport.c.

531{
532 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
533
534 TRACE("iface %p, back %.8e.\n", iface, back);
535
537}
static HRESULT WINAPI d3drm_viewport2_SetBack(IDirect3DRMViewport2 *iface, D3DVALUE back)
Definition: viewport.c:513

◆ d3drm_viewport1_SetCamera()

static HRESULT WINAPI d3drm_viewport1_SetCamera ( IDirect3DRMViewport *  iface,
IDirect3DRMFrame *  camera 
)
static

Definition at line 599 of file viewport.c.

600{
601 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
602 struct d3drm_frame *frame = unsafe_impl_from_IDirect3DRMFrame(camera);
603
604 TRACE("iface %p, camera %p.\n", iface, camera);
605
607 frame ? &frame->IDirect3DRMFrame3_iface : NULL);
608}
static HRESULT WINAPI d3drm_viewport2_SetCamera(IDirect3DRMViewport2 *iface, IDirect3DRMFrame3 *camera)
Definition: viewport.c:582
#define NULL
Definition: types.h:112

◆ d3drm_viewport1_SetField()

static HRESULT WINAPI d3drm_viewport1_SetField ( IDirect3DRMViewport *  iface,
D3DVALUE  field 
)
static

Definition at line 559 of file viewport.c.

560{
561 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
562
563 TRACE("iface %p, field %.8e.\n", iface, field);
564
566}
static HRESULT WINAPI d3drm_viewport2_SetField(IDirect3DRMViewport2 *iface, D3DVALUE field)
Definition: viewport.c:539
Definition: parser.c:44

◆ d3drm_viewport1_SetFront()

static HRESULT WINAPI d3drm_viewport1_SetFront ( IDirect3DRMViewport *  iface,
D3DVALUE  front 
)
static

Definition at line 504 of file viewport.c.

505{
506 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
507
508 TRACE("iface %p, front %.8e.\n", iface, front);
509
511}
static HRESULT WINAPI d3drm_viewport2_SetFront(IDirect3DRMViewport2 *iface, D3DVALUE front)
Definition: viewport.c:487
static struct address_cache * front
Definition: rpcb_clnt.c:83

◆ d3drm_viewport1_SetName()

static HRESULT WINAPI d3drm_viewport1_SetName ( IDirect3DRMViewport *  iface,
const char name 
)
static

Definition at line 258 of file viewport.c.

259{
260 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
261
262 TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
263
265}
static HRESULT WINAPI d3drm_viewport2_SetName(IDirect3DRMViewport2 *iface, const char *name)
Definition: viewport.c:249
#define debugstr_a
Definition: kernel32.h:31

◆ d3drm_viewport1_SetPlane()

static HRESULT WINAPI d3drm_viewport1_SetPlane ( IDirect3DRMViewport *  iface,
D3DVALUE  left,
D3DVALUE  right,
D3DVALUE  bottom,
D3DVALUE  top 
)
static

Definition at line 709 of file viewport.c.

711{
712 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
713
714 TRACE("iface %p, left %.8e, right %.8e, bottom %.8e, top %.8e.\n",
715 iface, left, right, bottom, top);
716
718}
static HRESULT WINAPI d3drm_viewport2_SetPlane(IDirect3DRMViewport2 *iface, D3DVALUE left, D3DVALUE right, D3DVALUE bottom, D3DVALUE top)
Definition: viewport.c:690

◆ d3drm_viewport1_SetProjection()

static HRESULT WINAPI d3drm_viewport1_SetProjection ( IDirect3DRMViewport *  iface,
D3DRMPROJECTIONTYPE  type 
)
static

Definition at line 621 of file viewport.c.

622{
623 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport(iface);
624
625 TRACE("iface %p, type %#x.\n", iface, type);
626
628}
static HRESULT WINAPI d3drm_viewport2_SetProjection(IDirect3DRMViewport2 *iface, D3DRMPROJECTIONTYPE type)
Definition: viewport.c:610
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545

◆ d3drm_viewport1_SetUniformScaling()

static HRESULT WINAPI d3drm_viewport1_SetUniformScaling ( IDirect3DRMViewport *  iface,
BOOL  b 
)
static

Definition at line 575 of file viewport.c.

576{
577 FIXME("iface %p, b %#x stub!\n", iface, b);
578
579 return E_NOTIMPL;
580}
GLboolean GLboolean GLboolean b
Definition: glext.h:6204

◆ d3drm_viewport1_Transform()

static HRESULT WINAPI d3drm_viewport1_Transform ( IDirect3DRMViewport *  iface,
D3DRMVECTOR4D d,
D3DVECTOR s 
)
static

Definition at line 637 of file viewport.c.

638{
639 FIXME("iface %p, d %p, s %p stub!\n", iface, d, s);
640
641 return E_NOTIMPL;
642}

◆ d3drm_viewport2_AddDestroyCallback()

static HRESULT WINAPI d3drm_viewport2_AddDestroyCallback ( IDirect3DRMViewport2 *  iface,
D3DRMOBJECTCALLBACK  cb,
void ctx 
)
static

Definition at line 172 of file viewport.c.

174{
175 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
176
177 TRACE("iface %p, cb %p, ctx %p\n", iface, cb, ctx);
178
179 return d3drm_object_add_destroy_callback(&viewport->obj, cb, ctx);
180}
static struct d3drm_viewport * impl_from_IDirect3DRMViewport2(IDirect3DRMViewport2 *iface)
Definition: viewport.c:30
HRESULT d3drm_object_add_destroy_callback(struct d3drm_object *object, D3DRMOBJECTCALLBACK cb, void *ctx)
Definition: d3drm_main.c:55
struct d3drm_object obj

Referenced by d3drm_viewport1_AddDestroyCallback().

◆ d3drm_viewport2_AddRef()

static ULONG WINAPI d3drm_viewport2_AddRef ( IDirect3DRMViewport2 *  iface)
static

Definition at line 115 of file viewport.c.

116{
117 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
118 ULONG refcount = InterlockedIncrement(&viewport->obj.ref);
119
120 TRACE("%p increasing refcount to %u.\n", iface, refcount);
121
122 return refcount;
123}
#define InterlockedIncrement
Definition: armddk.h:53
uint32_t ULONG
Definition: typedefs.h:59

Referenced by d3drm_viewport1_AddRef().

◆ d3drm_viewport2_Clear()

static HRESULT WINAPI d3drm_viewport2_Clear ( IDirect3DRMViewport2 *  iface,
DWORD  flags 
)
static

Definition at line 426 of file viewport.c.

427{
428 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
429 DDSCAPS caps = { DDSCAPS_ZBUFFER };
430 HRESULT hr;
431 D3DRECT clear_rect;
432 IDirectDrawSurface *ds;
433 DWORD clear_flags = 0;
434
435 TRACE("iface %p, flags %#x.\n", iface, flags);
436
437 clear_rect.u1.x1 = clear_rect.u2.y1 = 0;
438 clear_rect.u3.x2 = viewport->device->width;
439 clear_rect.u4.y2 = viewport->device->height;
440
442 {
443 clear_flags |= D3DCLEAR_TARGET;
445 }
447 {
448 hr = IDirectDrawSurface_GetAttachedSurface(viewport->device->render_target, &caps, &ds);
449 if (SUCCEEDED(hr))
450 {
451 clear_flags |= D3DCLEAR_ZBUFFER;
452 IDirectDrawSurface_Release(ds);
453 }
454 }
456 FIXME("Flag D3DRMCLEAR_DIRTYRECT not implemented yet.\n");
457
458 if (FAILED(hr = IDirect3DViewport_Clear(viewport->d3d_viewport, 1, &clear_rect, clear_flags)))
459 return hr;
460
461 return D3DRM_OK;
462}
#define D3DCLEAR_ZBUFFER
Definition: d3d8types.h:31
#define D3DCLEAR_TARGET
Definition: d3d8types.h:30
#define IDirect3DViewport_Clear(p, a, b, c)
Definition: d3d.h:687
static HRESULT d3drm_update_background_material(struct d3drm_viewport *viewport)
Definition: viewport.c:43
#define D3DRMCLEAR_TARGET
Definition: d3drmdef.h:310
#define D3DRMCLEAR_DIRTYRECTS
Definition: d3drmdef.h:312
#define D3DRMCLEAR_ZBUFFER
Definition: d3drmdef.h:311
unsigned long DWORD
Definition: ntddk_ex.h:95
GLbitfield flags
Definition: glext.h:7161
#define ds
Definition: i386-dis.c:443
#define SUCCEEDED(hr)
Definition: intsafe.h:50
#define DDSCAPS_ZBUFFER
Definition: ddraw.h:267
LONG y2
Definition: d3d8types.h:1156
LONG x1
Definition: d3d8types.h:1153
LONG y1
Definition: d3d8types.h:1154
LONG x2
Definition: d3d8types.h:1155
IDirect3DViewport * d3d_viewport

Referenced by d3drm_viewport1_Clear().

◆ d3drm_viewport2_Clone()

static HRESULT WINAPI d3drm_viewport2_Clone ( IDirect3DRMViewport2 *  iface,
IUnknown outer,
REFIID  iid,
void **  out 
)
static

Definition at line 156 of file viewport.c.

158{
159 FIXME("iface %p, outer %p, iid %s, out %p stub!\n", iface, outer, debugstr_guid(iid), out);
160
161 return E_NOTIMPL;
162}

◆ d3drm_viewport2_Configure()

static HRESULT WINAPI d3drm_viewport2_Configure ( IDirect3DRMViewport2 *  iface,
LONG  x,
LONG  y,
DWORD  width,
DWORD  height 
)
static

Definition at line 658 of file viewport.c.

660{
661 FIXME("iface %p, x %d, y %d, width %u, height %u stub!\n", iface, x, y, width, height);
662
663 return E_NOTIMPL;
664}

◆ d3drm_viewport2_DeleteDestroyCallback()

static HRESULT WINAPI d3drm_viewport2_DeleteDestroyCallback ( IDirect3DRMViewport2 *  iface,
D3DRMOBJECTCALLBACK  cb,
void ctx 
)
static

Definition at line 192 of file viewport.c.

194{
195 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
196
197 TRACE("iface %p, cb %p, ctx %p\n", iface, cb, ctx);
198
199 return d3drm_object_delete_destroy_callback(&viewport->obj, cb, ctx);
200}
HRESULT d3drm_object_delete_destroy_callback(struct d3drm_object *object, D3DRMOBJECTCALLBACK cb, void *ctx)
Definition: d3drm_main.c:72

Referenced by d3drm_viewport1_DeleteDestroyCallback().

◆ d3drm_viewport2_ForceUpdate()

static HRESULT WINAPI d3drm_viewport2_ForceUpdate ( IDirect3DRMViewport2 *  iface,
DWORD  x1,
DWORD  y1,
DWORD  x2,
DWORD  y2 
)
static

Definition at line 674 of file viewport.c.

676{
677 FIXME("iface %p, x1 %u, y1 %u, x2 %u, y2 %u stub!\n", iface, x1, y1, x2, y2);
678
679 return E_NOTIMPL;
680}

◆ d3drm_viewport2_GetAppData()

static DWORD WINAPI d3drm_viewport2_GetAppData ( IDirect3DRMViewport2 *  iface)
static

Definition at line 231 of file viewport.c.

232{
233 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
234
235 TRACE("iface %p\n", iface);
236
237 return viewport->obj.appdata;
238}

Referenced by d3drm_viewport1_GetAppData().

◆ d3drm_viewport2_GetBack()

static D3DVALUE WINAPI d3drm_viewport2_GetBack ( IDirect3DRMViewport2 *  iface)
static

Definition at line 930 of file viewport.c.

931{
932 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
933
934 TRACE("iface %p.\n", iface);
935
936 if (!viewport->d3d_viewport)
937 return -1.0f;
938
939 return viewport->clip.back;
940}
struct d3drm_box clip

Referenced by d3drm_viewport1_GetBack().

◆ d3drm_viewport2_GetCamera()

static HRESULT WINAPI d3drm_viewport2_GetCamera ( IDirect3DRMViewport2 *  iface,
IDirect3DRMFrame3 **  camera 
)
static

Definition at line 720 of file viewport.c.

721{
722 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
723
724 TRACE("iface %p, camera %p.\n", iface, camera);
725
726 if (!camera)
727 return D3DRMERR_BADVALUE;
728
729 if (!viewport->camera)
730 return D3DRMERR_BADOBJECT;
731
732 return IDirect3DRMFrame_QueryInterface(viewport->camera, &IID_IDirect3DRMFrame3, (void **)camera);
733}
#define IDirect3DRMFrame_QueryInterface(p, a, b)
Definition: d3drmobj.h:1166

Referenced by d3drm_viewport1_GetCamera().

◆ d3drm_viewport2_GetClassName()

static HRESULT WINAPI d3drm_viewport2_GetClassName ( IDirect3DRMViewport2 *  iface,
DWORD size,
char name 
)
static

Definition at line 285 of file viewport.c.

286{
287 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
288
289 TRACE("iface %p, size %p, name %p.\n", iface, size, name);
290
291 return d3drm_object_get_class_name(&viewport->obj, size, name);
292}
HRESULT d3drm_object_get_class_name(struct d3drm_object *object, DWORD *size, char *name)
Definition: d3drm_main.c:92

Referenced by d3drm_viewport1_GetClassName().

◆ d3drm_viewport2_GetDevice()

static HRESULT WINAPI d3drm_viewport2_GetDevice ( IDirect3DRMViewport2 *  iface,
IDirect3DRMDevice3 **  device 
)
static

Definition at line 756 of file viewport.c.

757{
758 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
759
760 TRACE("iface %p, device %p.\n", iface, device);
761
762 if (!device)
763 return D3DRMERR_BADVALUE;
764
765 if (!viewport->device)
766 return D3DRMERR_BADOBJECT;
767
768 *device = &viewport->device->IDirect3DRMDevice3_iface;
770
771 return D3DRM_OK;
772}
#define IDirect3DRMDevice3_AddRef(p)
Definition: d3drmobj.h:692

◆ d3drm_viewport2_GetDirect3DViewport()

static HRESULT WINAPI d3drm_viewport2_GetDirect3DViewport ( IDirect3DRMViewport2 *  iface,
IDirect3DViewport **  viewport 
)
static

Definition at line 990 of file viewport.c.

992{
993 struct d3drm_viewport *viewport_object = impl_from_IDirect3DRMViewport2(iface);
994
995 TRACE("iface %p, viewport %p.\n", iface, viewport);
996
997 if (!viewport)
998 return D3DRMERR_BADVALUE;
999
1000 if (!viewport_object->d3d_viewport)
1001 return D3DRMERR_BADOBJECT;
1002
1003 *viewport = viewport_object->d3d_viewport;
1004 IDirect3DViewport_AddRef(*viewport);
1005
1006 return D3DRM_OK;
1007}
#define IDirect3DViewport_AddRef(p)
Definition: d3d.h:675

Referenced by d3drm_viewport1_GetDirect3DViewport().

◆ d3drm_viewport2_GetField()

static D3DVALUE WINAPI d3drm_viewport2_GetField ( IDirect3DRMViewport2 *  iface)
static

Definition at line 908 of file viewport.c.

909{
910 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
911
912 TRACE("iface %p.\n", iface);
913
914 if (!viewport->d3d_viewport)
915 return -1.0f;
916
917 return (viewport->clip.right - viewport->clip.left
918 + viewport->clip.top - viewport->clip.bottom) / 4.0f;
919}

Referenced by d3drm_viewport1_GetField().

◆ d3drm_viewport2_GetFront()

static D3DVALUE WINAPI d3drm_viewport2_GetFront ( IDirect3DRMViewport2 *  iface)
static

Definition at line 951 of file viewport.c.

952{
953 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
954
955 TRACE("iface %p.\n", iface);
956
957 if (!viewport->d3d_viewport)
958 return -1.0f;
959
960 return viewport->clip.front;
961}

Referenced by d3drm_viewport1_GetFront().

◆ d3drm_viewport2_GetHeight()

static DWORD WINAPI d3drm_viewport2_GetHeight ( IDirect3DRMViewport2 *  iface)
static

Definition at line 894 of file viewport.c.

895{
896 FIXME("iface %p stub!\n", iface);
897
898 return E_NOTIMPL;
899}

◆ d3drm_viewport2_GetName()

static HRESULT WINAPI d3drm_viewport2_GetName ( IDirect3DRMViewport2 *  iface,
DWORD size,
char name 
)
static

Definition at line 267 of file viewport.c.

268{
269 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
270
271 TRACE("iface %p, size %p, name %p.\n", iface, size, name);
272
273 return d3drm_object_get_name(&viewport->obj, size, name);
274}
HRESULT d3drm_object_get_name(struct d3drm_object *object, DWORD *size, char *name)
Definition: d3drm_main.c:111

Referenced by d3drm_viewport1_GetName().

◆ d3drm_viewport2_GetPlane()

static HRESULT WINAPI d3drm_viewport2_GetPlane ( IDirect3DRMViewport2 *  iface,
D3DVALUE left,
D3DVALUE right,
D3DVALUE bottom,
D3DVALUE top 
)
static

Definition at line 792 of file viewport.c.

794{
795 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
796
797 TRACE("iface %p, left %p, right %p, bottom %p, top %p.\n",
798 iface, left, right, bottom, top);
799
800 if (!viewport->d3d_viewport)
801 return D3DRMERR_BADOBJECT;
802
803 *left = viewport->clip.left;
804 *right = viewport->clip.right;
805 *bottom = viewport->clip.bottom;
806 *top = viewport->clip.top;
807
808 return D3DRM_OK;
809}

Referenced by d3drm_viewport1_GetPlane().

◆ d3drm_viewport2_GetProjection()

static D3DRMPROJECTIONTYPE WINAPI d3drm_viewport2_GetProjection ( IDirect3DRMViewport2 *  iface)
static

Definition at line 972 of file viewport.c.

973{
974 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
975
976 TRACE("iface %p.\n", iface);
977
978 return viewport->projection;
979}
D3DRMPROJECTIONTYPE projection

Referenced by d3drm_viewport1_GetProjection().

◆ d3drm_viewport2_GetUniformScaling()

static BOOL WINAPI d3drm_viewport2_GetUniformScaling ( IDirect3DRMViewport2 *  iface)
static

Definition at line 838 of file viewport.c.

839{
840 FIXME("iface %p stub!\n", iface);
841
842 return FALSE;
843}

◆ d3drm_viewport2_GetWidth()

static DWORD WINAPI d3drm_viewport2_GetWidth ( IDirect3DRMViewport2 *  iface)
static

Definition at line 880 of file viewport.c.

881{
882 FIXME("iface %p stub!\n", iface);
883
884 return E_NOTIMPL;
885}

◆ d3drm_viewport2_GetX()

static LONG WINAPI d3drm_viewport2_GetX ( IDirect3DRMViewport2 *  iface)
static

Definition at line 852 of file viewport.c.

853{
854 FIXME("iface %p stub!\n", iface);
855
856 return E_NOTIMPL;
857}

◆ d3drm_viewport2_GetY()

static LONG WINAPI d3drm_viewport2_GetY ( IDirect3DRMViewport2 *  iface)
static

Definition at line 866 of file viewport.c.

867{
868 FIXME("iface %p stub!\n", iface);
869
870 return E_NOTIMPL;
871}

◆ d3drm_viewport2_Init()

static HRESULT WINAPI d3drm_viewport2_Init ( IDirect3DRMViewport2 *  iface,
IDirect3DRMDevice3 *  device,
IDirect3DRMFrame3 *  camera,
DWORD  x,
DWORD  y,
DWORD  width,
DWORD  height 
)
static

Definition at line 303 of file viewport.c.

305{
306 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
308 D3DVIEWPORT vp;
310 IDirect3D *d3d1 = NULL;
311 IDirect3DDevice *d3d_device = NULL;
312 IDirect3DMaterial *material = NULL;
315
316 TRACE("iface %p, device %p, camera %p, x %u, y %u, width %u, height %u.\n",
317 iface, device, camera, x, y, width, height);
318
319 if (!device_obj || !camera
320 || width > device_obj->width
321 || height > device_obj->height)
322 {
323 return D3DRMERR_BADOBJECT;
324 }
325
326 if (viewport->d3d_viewport)
327 return D3DRMERR_BADOBJECT;
328
329 IDirect3DRM_AddRef(viewport->d3drm);
330
332 goto cleanup;
333
335 goto cleanup;
336
337 if (FAILED(hr = IDirect3D_CreateViewport(d3d1, &viewport->d3d_viewport, NULL)))
338 goto cleanup;
339
341 goto cleanup;
342
343 vp.dwSize = sizeof(vp);
344 vp.dwWidth = width;
345 vp.dwHeight = height;
346 vp.dwX = x;
347 vp.dwY = y;
348 scale = width > height ? (float)width / 2.0f : (float)height / 2.0f;
349 vp.dvScaleX = scale;
350 vp.dvScaleY = scale;
351 vp.dvMaxX = vp.dwWidth / (2.0f * vp.dvScaleX);
352 vp.dvMaxY = vp.dwHeight / (2.0f * vp.dvScaleY);
353 vp.dvMinZ = 0.0f;
354 vp.dvMaxZ = 1.0f;
355
357 goto cleanup;
358
359 if (FAILED(hr = IDirect3DRMFrame3_QueryInterface(camera, &IID_IDirect3DRMFrame, (void **)&viewport->camera)))
360 goto cleanup;
361
362 if (FAILED(hr = IDirect3D_CreateMaterial(d3d1, &material, NULL)))
363 goto cleanup;
364
365 if (FAILED(hr = IDirect3DMaterial_GetHandle(material, d3d_device, &hmat)))
366 goto cleanup;
367
369 viewport->material = material;
370 viewport->device = device_obj;
371
372 viewport->clip.left = -0.5f;
373 viewport->clip.top = 0.5f;
374 viewport->clip.right = 0.5f;
375 viewport->clip.bottom = -0.5f;
376 viewport->clip.front = 1.0f;
377 viewport->clip.back = 100.0f;
378
379cleanup:
380
381 if (FAILED(hr))
382 {
383 if (viewport->d3d_viewport)
384 {
386 viewport->d3d_viewport = NULL;
387 }
388 if (viewport->camera)
390 if (material)
392 IDirect3DRM_Release(viewport->d3drm);
393 }
394 if (d3d_device)
396 if (d3d1)
397 IDirect3D_Release(d3d1);
398
399 return hr;
400}
#define IDirect3DViewport_SetViewport(p, a)
Definition: d3d.h:680
#define IDirect3D_CreateViewport(p, a, b)
Definition: d3d.h:239
#define IDirect3D_Release(p)
Definition: d3d.h:233
#define IDirect3DMaterial_Release(p)
Definition: d3d.h:464
#define IDirect3DViewport_Release(p)
Definition: d3d.h:676
#define IDirect3DMaterial_GetHandle(p, a, b)
Definition: d3d.h:469
#define IDirect3DViewport_SetBackground(p, a)
Definition: d3d.h:683
#define IDirect3D_CreateMaterial(p, a, b)
Definition: d3d.h:238
#define IDirect3DDevice_AddViewport(p, a)
Definition: d3d.h:974
#define IDirect3DDevice_GetDirect3D(p, a)
Definition: d3d.h:986
#define IDirect3DDevice_Release(p)
Definition: d3d.h:966
#define IDirect3DRM_Release(p)
Definition: d3drm.h:111
#define IDirect3DRM_AddRef(p)
Definition: d3drm.h:110
struct d3drm_device * unsafe_impl_from_IDirect3DRMDevice3(IDirect3DRMDevice3 *iface) DECLSPEC_HIDDEN
Definition: device.c:1625
#define IDirect3DRMFrame3_QueryInterface(p, a, b)
Definition: d3drmobj.h:1706
#define IDirect3DRMDevice3_GetDirect3DDevice(p, a)
Definition: d3drmobj.h:726
float D3DVALUE
Definition: d3dtypes.h:89
DWORD D3DMATERIALHANDLE
Definition: d3dtypes.h:154
static void cleanup(void)
Definition: main.c:1335
GLenum GLenum GLenum GLenum GLenum scale
Definition: glext.h:9032
static float(__cdecl *square_half_float)(float x
DWORD dwHeight
Definition: d3dtypes.h:367
D3DVALUE dvMaxX
Definition: d3dtypes.h:370
D3DVALUE dvMaxZ
Definition: d3dtypes.h:373
D3DVALUE dvScaleY
Definition: d3dtypes.h:369
DWORD dwSize
Definition: d3dtypes.h:363
DWORD dwWidth
Definition: d3dtypes.h:366
DWORD dwX
Definition: d3dtypes.h:364
D3DVALUE dvMaxY
Definition: d3dtypes.h:371
DWORD dwY
Definition: d3dtypes.h:365
D3DVALUE dvScaleX
Definition: d3dtypes.h:368
D3DVALUE dvMinZ
Definition: d3dtypes.h:372
IDirect3DRM * d3drm

Referenced by d3drm_viewport1_Init().

◆ d3drm_viewport2_InverseTransform()

static HRESULT WINAPI d3drm_viewport2_InverseTransform ( IDirect3DRMViewport2 *  iface,
D3DVECTOR d,
D3DRMVECTOR4D s 
)
static

Definition at line 644 of file viewport.c.

645{
646 FIXME("iface %p, d %p, s %p stub!\n", iface, d, s);
647
648 return E_NOTIMPL;
649}

◆ d3drm_viewport2_InverseTransformVectors()

static HRESULT WINAPI d3drm_viewport2_InverseTransformVectors ( IDirect3DRMViewport2 *  iface,
DWORD  vector_count,
D3DVECTOR dst,
D3DRMVECTOR4D src 
)
static

Definition at line 1027 of file viewport.c.

1029{
1030 FIXME("iface %p, vector_count %u, dst %p, src %p stub!\n", iface, vector_count, dst, src);
1031
1032 return E_NOTIMPL;
1033}
GLenum src
Definition: glext.h:6340
GLenum GLenum dst
Definition: glext.h:6340

◆ d3drm_viewport2_Pick()

static HRESULT WINAPI d3drm_viewport2_Pick ( IDirect3DRMViewport2 *  iface,
LONG  x,
LONG  y,
IDirect3DRMPickedArray **  visuals 
)
static

Definition at line 822 of file viewport.c.

824{
825 FIXME("iface %p, x %d, y %d, visuals %p stub!\n", iface, x, y, visuals);
826
827 return E_NOTIMPL;
828}

◆ d3drm_viewport2_QueryInterface()

static HRESULT WINAPI d3drm_viewport2_QueryInterface ( IDirect3DRMViewport2 *  iface,
REFIID  riid,
void **  out 
)
static

Definition at line 79 of file viewport.c.

80{
81 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
82
83 TRACE("iface %p, riid %s, out %p.\n", iface, debugstr_guid(riid), out);
84
85 if (IsEqualGUID(riid, &IID_IDirect3DRMViewport)
86 || IsEqualGUID(riid, &IID_IDirect3DRMObject)
88 {
89 *out = &viewport->IDirect3DRMViewport_iface;
90 }
91 else if (IsEqualGUID(riid, &IID_IDirect3DRMViewport2))
92 {
93 *out = &viewport->IDirect3DRMViewport2_iface;
94 }
95 else
96 {
97 *out = NULL;
98 WARN("%s not implemented, returning CLASS_E_CLASSNOTAVAILABLE.\n", debugstr_guid(riid));
100 }
101
102 IUnknown_AddRef((IUnknown *)*out);
103 return S_OK;
104}
#define WARN(fmt,...)
Definition: precomp.h:61
const GUID IID_IUnknown
#define S_OK
Definition: intsafe.h:52
#define IsEqualGUID(rguid1, rguid2)
Definition: guiddef.h:147
IDirect3DRMViewport IDirect3DRMViewport_iface
#define CLASS_E_CLASSNOTAVAILABLE
Definition: winerror.h:2663

Referenced by d3drm_viewport1_QueryInterface().

◆ d3drm_viewport2_Release()

static ULONG WINAPI d3drm_viewport2_Release ( IDirect3DRMViewport2 *  iface)
static

Definition at line 134 of file viewport.c.

135{
136 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
137 ULONG refcount = InterlockedDecrement(&viewport->obj.ref);
138
139 TRACE("%p decreasing refcount to %u.\n", iface, refcount);
140
141 if (!refcount)
142 d3drm_viewport_destroy(viewport);
143
144 return refcount;
145}
#define InterlockedDecrement
Definition: armddk.h:52
static void d3drm_viewport_destroy(struct d3drm_viewport *viewport)
Definition: viewport.c:62

Referenced by d3drm_viewport1_Release().

◆ d3drm_viewport2_Render()

static HRESULT WINAPI d3drm_viewport2_Render ( IDirect3DRMViewport2 *  iface,
IDirect3DRMFrame3 *  frame 
)
static

Definition at line 473 of file viewport.c.

474{
475 FIXME("iface %p, frame %p stub!\n", iface, frame);
476
477 return D3DRM_OK;
478}

◆ d3drm_viewport2_SetAppData()

static HRESULT WINAPI d3drm_viewport2_SetAppData ( IDirect3DRMViewport2 *  iface,
DWORD  data 
)
static

Definition at line 212 of file viewport.c.

213{
214 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
215
216 TRACE("iface %p, data %#x\n", iface, data);
217
218 viewport->obj.appdata = data;
219 return S_OK;
220}

Referenced by d3drm_viewport1_SetAppData().

◆ d3drm_viewport2_SetBack()

static HRESULT WINAPI d3drm_viewport2_SetBack ( IDirect3DRMViewport2 *  iface,
D3DVALUE  back 
)
static

Definition at line 513 of file viewport.c.

514{
515 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
516
517 TRACE("iface %p, back %.8e.\n", iface, back);
518
519 if (!viewport->d3d_viewport)
520 return D3DRMERR_BADOBJECT;
521
522 if (back <= viewport->clip.front)
523 return D3DRMERR_BADVALUE;
524
525 viewport->clip.back = back;
526
527 return D3DRM_OK;
528}

Referenced by d3drm_viewport1_SetBack().

◆ d3drm_viewport2_SetCamera()

static HRESULT WINAPI d3drm_viewport2_SetCamera ( IDirect3DRMViewport2 *  iface,
IDirect3DRMFrame3 *  camera 
)
static

Definition at line 582 of file viewport.c.

583{
584 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
585 struct d3drm_frame *frame = unsafe_impl_from_IDirect3DRMFrame3(camera);
586
587 TRACE("iface %p, camera %p.\n", iface, camera);
588
589 if (!camera || !viewport->camera)
590 return D3DRMERR_BADOBJECT;
591
594 viewport->camera = &frame->IDirect3DRMFrame_iface;
595
596 return D3DRM_OK;
597}
#define IDirect3DRMFrame_AddRef(p)
Definition: d3drmobj.h:1167

Referenced by d3drm_viewport1_SetCamera().

◆ d3drm_viewport2_SetField()

static HRESULT WINAPI d3drm_viewport2_SetField ( IDirect3DRMViewport2 *  iface,
D3DVALUE  field 
)
static

Definition at line 539 of file viewport.c.

540{
541 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
542
543 TRACE("iface %p, field %.8e.\n", iface, field);
544
545 if (!viewport->d3d_viewport)
546 return D3DRMERR_BADOBJECT;
547
548 if (field <= 0.0f)
549 return D3DRMERR_BADVALUE;
550
551 viewport->clip.left = -field;
552 viewport->clip.right = field;
553 viewport->clip.bottom = -field;
554 viewport->clip.top = field;
555
556 return D3DRM_OK;
557}

Referenced by d3drm_viewport1_SetField().

◆ d3drm_viewport2_SetFront()

static HRESULT WINAPI d3drm_viewport2_SetFront ( IDirect3DRMViewport2 *  iface,
D3DVALUE  front 
)
static

Definition at line 487 of file viewport.c.

488{
489 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
490
491 TRACE("iface %p, front %.8e.\n", iface, front);
492
493 if (!viewport->d3d_viewport)
494 return D3DRMERR_BADOBJECT;
495
496 if (front <= 0.0f)
497 return D3DRMERR_BADVALUE;
498
499 viewport->clip.front = front;
500
501 return D3DRM_OK;
502}

Referenced by d3drm_viewport1_SetFront().

◆ d3drm_viewport2_SetName()

static HRESULT WINAPI d3drm_viewport2_SetName ( IDirect3DRMViewport2 *  iface,
const char name 
)
static

Definition at line 249 of file viewport.c.

250{
251 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
252
253 TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
254
255 return d3drm_object_set_name(&viewport->obj, name);
256}
HRESULT d3drm_object_set_name(struct d3drm_object *object, const char *name)
Definition: d3drm_main.c:135

Referenced by d3drm_viewport1_SetName().

◆ d3drm_viewport2_SetPlane()

static HRESULT WINAPI d3drm_viewport2_SetPlane ( IDirect3DRMViewport2 *  iface,
D3DVALUE  left,
D3DVALUE  right,
D3DVALUE  bottom,
D3DVALUE  top 
)
static

Definition at line 690 of file viewport.c.

692{
693 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
694
695 TRACE("iface %p, left %.8e, right %.8e, bottom %.8e, top %.8e.\n",
696 iface, left, right, bottom, top);
697
698 if (!viewport->d3d_viewport)
699 return D3DRMERR_BADOBJECT;
700
701 viewport->clip.left = left;
702 viewport->clip.right = right;
703 viewport->clip.bottom = bottom;
704 viewport->clip.top = top;
705
706 return D3DRM_OK;
707}

Referenced by d3drm_viewport1_SetPlane().

◆ d3drm_viewport2_SetProjection()

static HRESULT WINAPI d3drm_viewport2_SetProjection ( IDirect3DRMViewport2 *  iface,
D3DRMPROJECTIONTYPE  type 
)
static

Definition at line 610 of file viewport.c.

611{
612 struct d3drm_viewport *viewport = impl_from_IDirect3DRMViewport2(iface);
613
614 TRACE("iface %p, type %#x.\n", iface, type);
615
616 viewport->projection = type;
617
618 return D3DRM_OK;
619}

Referenced by d3drm_viewport1_SetProjection().

◆ d3drm_viewport2_SetUniformScaling()

static HRESULT WINAPI d3drm_viewport2_SetUniformScaling ( IDirect3DRMViewport2 *  iface,
BOOL  b 
)
static

Definition at line 568 of file viewport.c.

569{
570 FIXME("iface %p, b %#x stub!\n", iface, b);
571
572 return E_NOTIMPL;
573}

◆ d3drm_viewport2_Transform()

static HRESULT WINAPI d3drm_viewport2_Transform ( IDirect3DRMViewport2 *  iface,
D3DRMVECTOR4D d,
D3DVECTOR s 
)
static

Definition at line 630 of file viewport.c.

631{
632 FIXME("iface %p, d %p, s %p stub!\n", iface, d, s);
633
634 return E_NOTIMPL;
635}

◆ d3drm_viewport2_TransformVectors()

static HRESULT WINAPI d3drm_viewport2_TransformVectors ( IDirect3DRMViewport2 *  iface,
DWORD  vector_count,
D3DRMVECTOR4D dst,
D3DVECTOR src 
)
static

Definition at line 1019 of file viewport.c.

1021{
1022 FIXME("iface %p, vector_count %u, dst %p, src %p stub!\n", iface, vector_count, dst, src);
1023
1024 return E_NOTIMPL;
1025}

◆ d3drm_viewport_create()

HRESULT d3drm_viewport_create ( struct d3drm_viewport **  viewport,
IDirect3DRM *  d3drm 
)

Definition at line 1123 of file viewport.c.

1124{
1125 static const char classname[] = "Viewport";
1126 struct d3drm_viewport *object;
1127
1128 TRACE("viewport %p, d3drm %p.\n", viewport, d3drm);
1129
1130 if (!(object = heap_alloc_zero(sizeof(*object))))
1131 return E_OUTOFMEMORY;
1132
1133 object->IDirect3DRMViewport_iface.lpVtbl = &d3drm_viewport1_vtbl;
1134 object->IDirect3DRMViewport2_iface.lpVtbl = &d3drm_viewport2_vtbl;
1135 object->d3drm = d3drm;
1137
1138 *viewport = object;
1139
1140 return S_OK;
1141}
static const struct IDirect3DRMViewportVtbl d3drm_viewport1_vtbl
Definition: viewport.c:1080
static const struct IDirect3DRMViewport2Vtbl d3drm_viewport2_vtbl
Definition: viewport.c:1035
void d3drm_object_init(struct d3drm_object *object, const char *classname)
Definition: d3drm_main.c:39
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
WCHAR classname[128]
Definition: startup.c:15
Definition: d3drm.c:189

Referenced by d3drm3_CreateViewport(), and d3drm_create_viewport_object().

◆ d3drm_viewport_destroy()

static void d3drm_viewport_destroy ( struct d3drm_viewport viewport)
static

Definition at line 62 of file viewport.c.

63{
64 TRACE("viewport %p releasing attached interfaces.\n", viewport);
65
66 d3drm_object_cleanup((IDirect3DRMObject *)&viewport->IDirect3DRMViewport_iface, &viewport->obj);
67
68 if (viewport->d3d_viewport)
69 {
73 IDirect3DRM_Release(viewport->d3drm);
74 }
75
76 heap_free(viewport);
77}
static BOOL heap_free(void *mem)
Definition: appwiz.h:76
void d3drm_object_cleanup(IDirect3DRMObject *iface, struct d3drm_object *object)
Definition: d3drm_main.c:153

Referenced by d3drm_viewport2_Release().

◆ impl_from_IDirect3DRMViewport()

◆ impl_from_IDirect3DRMViewport2()

◆ WINE_DEFAULT_DEBUG_CHANNEL()

WINE_DEFAULT_DEBUG_CHANNEL ( d3drm  )

Variable Documentation

◆ d3drm_viewport1_vtbl

const struct IDirect3DRMViewportVtbl d3drm_viewport1_vtbl
static

Definition at line 1080 of file viewport.c.

Referenced by d3drm_viewport_create().

◆ d3drm_viewport2_vtbl

const struct IDirect3DRMViewport2Vtbl d3drm_viewport2_vtbl
static

Definition at line 1035 of file viewport.c.

Referenced by d3drm_viewport_create().