45 IDirect3DRMFrame *root_frame;
64 TRACE(
"viewport %p releasing attached interfaces.\n", viewport);
120 TRACE(
"%p increasing refcount to %u.\n", iface, refcount);
129 TRACE(
"iface %p.\n", iface);
139 TRACE(
"%p decreasing refcount to %u.\n", iface, refcount);
151 TRACE(
"iface %p.\n", iface);
177 TRACE(
"iface %p, cb %p, ctx %p\n", iface,
cb,
ctx);
187 TRACE(
"iface %p, cb %p, ctx %p\n", iface,
cb,
ctx);
197 TRACE(
"iface %p, cb %p, ctx %p\n", iface,
cb,
ctx);
207 TRACE(
"iface %p, cb %p, ctx %p\n", iface,
cb,
ctx);
216 TRACE(
"iface %p, data %#x\n", iface,
data);
226 TRACE(
"iface %p, data %#x\n", iface,
data);
235 TRACE(
"iface %p\n", iface);
237 return viewport->
obj.appdata;
244 TRACE(
"iface %p.\n", iface);
310 IDirect3D *d3d1 =
NULL;
312 IDirect3DMaterial *material =
NULL;
316 TRACE(
"iface %p, device %p, camera %p, x %u, y %u, width %u, height %u.\n",
319 if (!device_obj || !camera
370 viewport->
device = device_obj;
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;
407 IDirect3DRMDevice3 *device3;
410 TRACE(
"iface %p, device %p, camera %p, x %u, y %u, width %u, height %u.\n",
432 IDirectDrawSurface *
ds;
433 DWORD clear_flags = 0;
435 TRACE(
"iface %p, flags %#x.\n", iface,
flags);
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;
448 hr = IDirectDrawSurface_GetAttachedSurface(viewport->
device->render_target, &caps, &
ds);
452 IDirectDrawSurface_Release(
ds);
456 FIXME(
"Flag D3DRMCLEAR_DIRTYRECT not implemented yet.\n");
468 TRACE(
"iface %p.\n", iface);
475 FIXME(
"iface %p, frame %p stub!\n", iface, frame);
482 FIXME(
"iface %p, frame %p stub!\n", iface, frame);
491 TRACE(
"iface %p, front %.8e.\n", iface,
front);
508 TRACE(
"iface %p, front %.8e.\n", iface,
front);
517 TRACE(
"iface %p, back %.8e.\n", iface, back);
522 if (back <= viewport->
clip.front)
525 viewport->
clip.back = back;
534 TRACE(
"iface %p, back %.8e.\n", iface, back);
543 TRACE(
"iface %p, field %.8e.\n", iface,
field);
563 TRACE(
"iface %p, field %.8e.\n", iface,
field);
570 FIXME(
"iface %p, b %#x stub!\n", iface,
b);
577 FIXME(
"iface %p, b %#x stub!\n", iface,
b);
587 TRACE(
"iface %p, camera %p.\n", iface, camera);
589 if (!camera || !viewport->
camera)
604 TRACE(
"iface %p, camera %p.\n", iface, camera);
614 TRACE(
"iface %p, type %#x.\n", iface,
type);
625 TRACE(
"iface %p, type %#x.\n", iface,
type);
632 FIXME(
"iface %p, d %p, s %p stub!\n", iface,
d,
s);
639 FIXME(
"iface %p, d %p, s %p stub!\n", iface,
d,
s);
646 FIXME(
"iface %p, d %p, s %p stub!\n", iface,
d,
s);
653 FIXME(
"iface %p, d %p, s %p stub!\n", iface,
d,
s);
661 FIXME(
"iface %p, x %d, y %d, width %u, height %u stub!\n", iface,
x,
y,
width,
height);
669 FIXME(
"iface %p, x %d, y %d, width %u, height %u stub!\n", iface,
x,
y,
width,
height);
677 FIXME(
"iface %p, x1 %u, y1 %u, x2 %u, y2 %u stub!\n", iface,
x1,
y1,
x2,
y2);
685 FIXME(
"iface %p, x1 %u, y1 %u, x2 %u, y2 %u stub!\n", iface,
x1,
y1,
x2,
y2);
695 TRACE(
"iface %p, left %.8e, right %.8e, bottom %.8e, top %.8e.\n",
714 TRACE(
"iface %p, left %.8e, right %.8e, bottom %.8e, top %.8e.\n",
739 IDirect3DRMFrame3 *camera3;
742 TRACE(
"iface %p, camera %p.\n", iface, camera);
797 TRACE(
"iface %p, left %p, right %p, bottom %p, top %p.\n",
816 TRACE(
"iface %p, left %p, right %p, bottom %p, top %p.\n",
823 LONG x,
LONG y, IDirect3DRMPickedArray **visuals)
825 FIXME(
"iface %p, x %d, y %d, visuals %p stub!\n", iface,
x,
y, visuals);
831 LONG x,
LONG y, IDirect3DRMPickedArray **visuals)
833 FIXME(
"iface %p, x %d, y %d, visuals %p stub!\n", iface,
x,
y, visuals);
840 FIXME(
"iface %p stub!\n", iface);
847 FIXME(
"iface %p stub!\n", iface);
854 FIXME(
"iface %p stub!\n", iface);
861 FIXME(
"iface %p stub!\n", iface);
868 FIXME(
"iface %p stub!\n", iface);
875 FIXME(
"iface %p stub!\n", iface);
882 FIXME(
"iface %p stub!\n", iface);
889 FIXME(
"iface %p stub!\n", iface);
896 FIXME(
"iface %p stub!\n", iface);
903 FIXME(
"iface %p stub!\n", iface);
912 TRACE(
"iface %p.\n", iface);
917 return (viewport->
clip.right - viewport->
clip.left
918 + viewport->
clip.top - viewport->
clip.bottom) / 4.0f;
925 TRACE(
"iface %p.\n", iface);
934 TRACE(
"iface %p.\n", iface);
939 return viewport->
clip.back;
946 TRACE(
"iface %p.\n", iface);
955 TRACE(
"iface %p.\n", iface);
960 return viewport->
clip.front;
967 TRACE(
"iface %p.\n", iface);
976 TRACE(
"iface %p.\n", iface);
985 TRACE(
"iface %p.\n", iface);
991 IDirect3DViewport **viewport)
995 TRACE(
"iface %p, viewport %p.\n", iface, viewport);
1010 IDirect3DViewport **viewport)
1014 TRACE(
"iface %p, viewport %p.\n", iface, viewport);
1022 FIXME(
"iface %p, vector_count %u, dst %p, src %p stub!\n", iface, vector_count,
dst,
src);
1030 FIXME(
"iface %p, vector_count %u, dst %p, src %p stub!\n", iface, vector_count,
dst,
src);
1125 static const char classname[] =
"Viewport";
1128 TRACE(
"viewport %p, d3drm %p.\n", viewport,
d3drm);
1130 if (!(
object = heap_alloc_zero(
sizeof(*
object))))
1135 object->d3drm =
d3drm;
static BOOL heap_free(void *mem)
#define InterlockedIncrement
#define InterlockedDecrement
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
#define IDirect3DViewport_SetViewport(p, a)
#define IDirect3D_CreateViewport(p, a, b)
#define IDirect3DViewport_AddRef(p)
#define IDirect3D_Release(p)
#define IDirect3DMaterial_Release(p)
#define IDirect3DViewport_Release(p)
#define IDirect3DMaterial_GetHandle(p, a, b)
#define IDirect3DViewport_SetBackground(p, a)
#define IDirect3D_CreateMaterial(p, a, b)
#define IDirect3DMaterial_SetMaterial(p, a)
#define IDirect3DDevice_AddViewport(p, a)
#define IDirect3DDevice_GetDirect3D(p, a)
#define IDirect3DViewport_Clear(p, a, b, c)
#define IDirect3DDevice_Release(p)
static HRESULT WINAPI d3drm_viewport2_InverseTransform(IDirect3DRMViewport2 *iface, D3DVECTOR *d, D3DRMVECTOR4D *s)
static HRESULT WINAPI d3drm_viewport1_Clone(IDirect3DRMViewport *iface, IUnknown *outer, REFIID iid, void **out)
static HRESULT WINAPI d3drm_viewport2_Pick(IDirect3DRMViewport2 *iface, LONG x, LONG y, IDirect3DRMPickedArray **visuals)
static HRESULT WINAPI d3drm_viewport1_GetPlane(IDirect3DRMViewport *iface, D3DVALUE *left, D3DVALUE *right, D3DVALUE *bottom, D3DVALUE *top)
static BOOL WINAPI d3drm_viewport2_GetUniformScaling(IDirect3DRMViewport2 *iface)
static HRESULT WINAPI d3drm_viewport2_SetPlane(IDirect3DRMViewport2 *iface, D3DVALUE left, D3DVALUE right, D3DVALUE bottom, D3DVALUE top)
static HRESULT WINAPI d3drm_viewport1_SetFront(IDirect3DRMViewport *iface, D3DVALUE front)
static LONG WINAPI d3drm_viewport1_GetY(IDirect3DRMViewport *iface)
static HRESULT WINAPI d3drm_viewport2_GetCamera(IDirect3DRMViewport2 *iface, IDirect3DRMFrame3 **camera)
static DWORD WINAPI d3drm_viewport1_GetHeight(IDirect3DRMViewport *iface)
static LONG WINAPI d3drm_viewport1_GetX(IDirect3DRMViewport *iface)
static HRESULT d3drm_update_background_material(struct d3drm_viewport *viewport)
static D3DVALUE WINAPI d3drm_viewport1_GetField(IDirect3DRMViewport *iface)
static D3DVALUE WINAPI d3drm_viewport1_GetBack(IDirect3DRMViewport *iface)
static HRESULT WINAPI d3drm_viewport1_Render(IDirect3DRMViewport *iface, IDirect3DRMFrame *frame)
static HRESULT WINAPI d3drm_viewport2_SetCamera(IDirect3DRMViewport2 *iface, IDirect3DRMFrame3 *camera)
static LONG WINAPI d3drm_viewport2_GetY(IDirect3DRMViewport2 *iface)
static D3DVALUE WINAPI d3drm_viewport2_GetFront(IDirect3DRMViewport2 *iface)
static HRESULT WINAPI d3drm_viewport2_SetUniformScaling(IDirect3DRMViewport2 *iface, BOOL b)
static HRESULT WINAPI d3drm_viewport1_GetName(IDirect3DRMViewport *iface, DWORD *size, char *name)
static ULONG WINAPI d3drm_viewport1_Release(IDirect3DRMViewport *iface)
static DWORD WINAPI d3drm_viewport2_GetWidth(IDirect3DRMViewport2 *iface)
static DWORD WINAPI d3drm_viewport1_GetWidth(IDirect3DRMViewport *iface)
static HRESULT WINAPI d3drm_viewport1_SetName(IDirect3DRMViewport *iface, const char *name)
static HRESULT WINAPI d3drm_viewport1_Transform(IDirect3DRMViewport *iface, D3DRMVECTOR4D *d, D3DVECTOR *s)
static HRESULT WINAPI d3drm_viewport2_GetDevice(IDirect3DRMViewport2 *iface, IDirect3DRMDevice3 **device)
static ULONG WINAPI d3drm_viewport1_AddRef(IDirect3DRMViewport *iface)
static HRESULT WINAPI d3drm_viewport1_SetBack(IDirect3DRMViewport *iface, D3DVALUE back)
static HRESULT WINAPI d3drm_viewport1_Configure(IDirect3DRMViewport *iface, LONG x, LONG y, DWORD width, DWORD height)
static HRESULT WINAPI d3drm_viewport2_TransformVectors(IDirect3DRMViewport2 *iface, DWORD vector_count, D3DRMVECTOR4D *dst, D3DVECTOR *src)
static HRESULT WINAPI d3drm_viewport2_Transform(IDirect3DRMViewport2 *iface, D3DRMVECTOR4D *d, D3DVECTOR *s)
static HRESULT WINAPI d3drm_viewport1_GetDirect3DViewport(IDirect3DRMViewport *iface, IDirect3DViewport **viewport)
static D3DVALUE WINAPI d3drm_viewport2_GetBack(IDirect3DRMViewport2 *iface)
static HRESULT WINAPI d3drm_viewport1_Pick(IDirect3DRMViewport *iface, LONG x, LONG y, IDirect3DRMPickedArray **visuals)
static HRESULT WINAPI d3drm_viewport2_GetPlane(IDirect3DRMViewport2 *iface, D3DVALUE *left, D3DVALUE *right, D3DVALUE *bottom, D3DVALUE *top)
static BOOL WINAPI d3drm_viewport1_GetUniformScaling(IDirect3DRMViewport *iface)
static HRESULT WINAPI d3drm_viewport2_GetName(IDirect3DRMViewport2 *iface, DWORD *size, char *name)
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 ULONG WINAPI d3drm_viewport2_Release(IDirect3DRMViewport2 *iface)
static HRESULT WINAPI d3drm_viewport2_DeleteDestroyCallback(IDirect3DRMViewport2 *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
static void d3drm_normalize_d3d_color(D3DCOLORVALUE *color_value, D3DCOLOR color)
static ULONG WINAPI d3drm_viewport2_AddRef(IDirect3DRMViewport2 *iface)
static HRESULT WINAPI d3drm_viewport1_SetProjection(IDirect3DRMViewport *iface, D3DRMPROJECTIONTYPE type)
static HRESULT WINAPI d3drm_viewport1_Clear(IDirect3DRMViewport *iface)
static D3DRMPROJECTIONTYPE WINAPI d3drm_viewport2_GetProjection(IDirect3DRMViewport2 *iface)
static D3DVALUE WINAPI d3drm_viewport2_GetField(IDirect3DRMViewport2 *iface)
static struct d3drm_viewport * impl_from_IDirect3DRMViewport2(IDirect3DRMViewport2 *iface)
static HRESULT WINAPI d3drm_viewport1_SetUniformScaling(IDirect3DRMViewport *iface, BOOL b)
static HRESULT WINAPI d3drm_viewport1_QueryInterface(IDirect3DRMViewport *iface, REFIID riid, void **out)
static DWORD WINAPI d3drm_viewport2_GetHeight(IDirect3DRMViewport2 *iface)
static void d3drm_viewport_destroy(struct d3drm_viewport *viewport)
static HRESULT WINAPI d3drm_viewport1_SetCamera(IDirect3DRMViewport *iface, IDirect3DRMFrame *camera)
static HRESULT WINAPI d3drm_viewport1_ForceUpdate(IDirect3DRMViewport *iface, DWORD x1, DWORD y1, DWORD x2, DWORD y2)
static HRESULT WINAPI d3drm_viewport1_AddDestroyCallback(IDirect3DRMViewport *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
static HRESULT WINAPI d3drm_viewport1_SetAppData(IDirect3DRMViewport *iface, DWORD data)
static HRESULT WINAPI d3drm_viewport2_AddDestroyCallback(IDirect3DRMViewport2 *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
static HRESULT WINAPI d3drm_viewport2_Clear(IDirect3DRMViewport2 *iface, DWORD flags)
static LONG WINAPI d3drm_viewport2_GetX(IDirect3DRMViewport2 *iface)
static HRESULT WINAPI d3drm_viewport1_SetPlane(IDirect3DRMViewport *iface, D3DVALUE left, D3DVALUE right, D3DVALUE bottom, D3DVALUE top)
static HRESULT WINAPI d3drm_viewport2_ForceUpdate(IDirect3DRMViewport2 *iface, DWORD x1, DWORD y1, DWORD x2, DWORD y2)
static HRESULT WINAPI d3drm_viewport1_SetField(IDirect3DRMViewport *iface, D3DVALUE field)
static D3DRMPROJECTIONTYPE WINAPI d3drm_viewport1_GetProjection(IDirect3DRMViewport *iface)
static HRESULT WINAPI d3drm_viewport2_GetDirect3DViewport(IDirect3DRMViewport2 *iface, IDirect3DViewport **viewport)
static HRESULT WINAPI d3drm_viewport2_SetName(IDirect3DRMViewport2 *iface, const char *name)
static HRESULT WINAPI d3drm_viewport2_SetFront(IDirect3DRMViewport2 *iface, D3DVALUE front)
static HRESULT WINAPI d3drm_viewport2_GetClassName(IDirect3DRMViewport2 *iface, DWORD *size, char *name)
static HRESULT WINAPI d3drm_viewport2_SetAppData(IDirect3DRMViewport2 *iface, DWORD data)
static HRESULT WINAPI d3drm_viewport1_GetClassName(IDirect3DRMViewport *iface, DWORD *size, char *name)
static HRESULT WINAPI d3drm_viewport2_SetField(IDirect3DRMViewport2 *iface, D3DVALUE field)
static const struct IDirect3DRMViewportVtbl d3drm_viewport1_vtbl
static HRESULT WINAPI d3drm_viewport2_Clone(IDirect3DRMViewport2 *iface, IUnknown *outer, REFIID iid, void **out)
static HRESULT WINAPI d3drm_viewport1_Init(IDirect3DRMViewport *iface, IDirect3DRMDevice *device, IDirect3DRMFrame *camera, DWORD x, DWORD y, DWORD width, DWORD height)
static HRESULT WINAPI d3drm_viewport1_DeleteDestroyCallback(IDirect3DRMViewport *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
static HRESULT WINAPI d3drm_viewport2_SetProjection(IDirect3DRMViewport2 *iface, D3DRMPROJECTIONTYPE type)
static DWORD WINAPI d3drm_viewport2_GetAppData(IDirect3DRMViewport2 *iface)
static struct d3drm_viewport * impl_from_IDirect3DRMViewport(IDirect3DRMViewport *iface)
static HRESULT WINAPI d3drm_viewport2_Render(IDirect3DRMViewport2 *iface, IDirect3DRMFrame3 *frame)
static D3DVALUE WINAPI d3drm_viewport1_GetFront(IDirect3DRMViewport *iface)
static HRESULT WINAPI d3drm_viewport2_QueryInterface(IDirect3DRMViewport2 *iface, REFIID riid, void **out)
static HRESULT WINAPI d3drm_viewport1_GetDevice(IDirect3DRMViewport *iface, IDirect3DRMDevice **device)
static HRESULT WINAPI d3drm_viewport1_GetCamera(IDirect3DRMViewport *iface, IDirect3DRMFrame **camera)
static HRESULT WINAPI d3drm_viewport2_Init(IDirect3DRMViewport2 *iface, IDirect3DRMDevice3 *device, IDirect3DRMFrame3 *camera, DWORD x, DWORD y, DWORD width, DWORD height)
HRESULT d3drm_viewport_create(struct d3drm_viewport **viewport, IDirect3DRM *d3drm)
static const struct IDirect3DRMViewport2Vtbl d3drm_viewport2_vtbl
static DWORD WINAPI d3drm_viewport1_GetAppData(IDirect3DRMViewport *iface)
static HRESULT WINAPI d3drm_viewport2_SetBack(IDirect3DRMViewport2 *iface, D3DVALUE back)
static HRESULT WINAPI d3drm_viewport2_InverseTransformVectors(IDirect3DRMViewport2 *iface, DWORD vector_count, D3DVECTOR *dst, D3DRMVECTOR4D *src)
#define D3DRMERR_BADVALUE
#define IDirect3DRM_Release(p)
#define D3DRMERR_BADOBJECT
#define IDirect3DRM_AddRef(p)
void d3drm_object_cleanup(IDirect3DRMObject *iface, struct d3drm_object *object)
void d3drm_object_init(struct d3drm_object *object, const char *classname)
HRESULT d3drm_object_get_name(struct d3drm_object *object, DWORD *size, char *name)
HRESULT d3drm_object_delete_destroy_callback(struct d3drm_object *object, D3DRMOBJECTCALLBACK cb, void *ctx)
HRESULT d3drm_object_add_destroy_callback(struct d3drm_object *object, D3DRMOBJECTCALLBACK cb, void *ctx)
HRESULT d3drm_object_set_name(struct d3drm_object *object, const char *name)
HRESULT d3drm_object_get_class_name(struct d3drm_object *object, DWORD *size, char *name)
struct d3drm_frame * unsafe_impl_from_IDirect3DRMFrame(IDirect3DRMFrame *iface) DECLSPEC_HIDDEN
struct d3drm_device * unsafe_impl_from_IDirect3DRMDevice3(IDirect3DRMDevice3 *iface) DECLSPEC_HIDDEN
struct d3drm_frame * unsafe_impl_from_IDirect3DRMFrame3(IDirect3DRMFrame3 *iface) DECLSPEC_HIDDEN
#define D3DRMCLEAR_TARGET
#define D3DRMCLEAR_DIRTYRECTS
#define D3DRMCLEAR_ZBUFFER
enum _D3DRMPROJECTIONTYPE D3DRMPROJECTIONTYPE
#define IDirect3DRMFrame_Release(p)
#define IDirect3DRMFrame3_QueryInterface(p, a, b)
#define IDirect3DRMFrame_GetSceneBackground(p)
#define IDirect3DRMDevice3_Release(p)
#define IDirect3DRMDevice_AddRef(p)
#define IDirect3DRMFrame_QueryInterface(p, a, b)
#define IDirect3DRMDevice3_AddRef(p)
#define IDirect3DRMFrame_GetScene(p, a)
#define IDirect3DRMDevice_QueryInterface(p, a, b)
#define IDirect3DRMFrame_AddRef(p)
#define IDirect3DRMDevice3_GetDirect3DDevice(p, a)
void(__cdecl * D3DRMOBJECTCALLBACK)(struct IDirect3DRMObject *obj, void *arg)
#define RGBA_GETGREEN(rgb)
#define RGBA_GETALPHA(rgb)
#define RGBA_GETBLUE(rgb)
static void cleanup(void)
GLint GLint GLint GLint GLint x
GLuint GLuint GLsizei GLenum type
GLint GLint GLint GLint GLint GLint y
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
GLint GLint GLsizei GLsizei height
GLint GLint GLsizei width
GLenum GLenum GLenum GLenum GLenum scale
GLdouble GLdouble GLdouble GLdouble top
GLboolean GLboolean GLboolean b
static HMODULE MODULEINFO DWORD cb
static float(__cdecl *square_half_float)(float x
#define IsEqualGUID(rguid1, rguid2)
static struct address_cache * front
IDirect3DRMFrame3 IDirect3DRMFrame3_iface
IDirect3DRMFrame IDirect3DRMFrame_iface
IDirect3DRMViewport IDirect3DRMViewport_iface
struct d3drm_device * device
IDirect3DRMViewport2 IDirect3DRMViewport2_iface
IDirect3DRMFrame * camera
IDirect3DViewport * d3d_viewport
IDirect3DMaterial * material
D3DRMPROJECTIONTYPE projection
#define CONTAINING_RECORD(address, type, field)
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG _In_ LONG _In_ LONG x2
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG _In_ LONG y1
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG x1
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG _In_ LONG _In_ LONG _In_ LONG y2
#define CLASS_E_CLASSNOTAVAILABLE