ReactOS  0.4.15-dev-1171-gab82533
d3drm.c File Reference
#include "d3drm_private.h"
Include dependency graph for d3drm.c:

Go to the source code of this file.

Classes

struct  d3drm
 

Functions

 WINE_DEFAULT_DEBUG_CHANNEL (d3drm)
 
static const charget_IID_string (const GUID *guid)
 
static HRESULT d3drm_create_texture_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_device_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_viewport_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_face_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_mesh_builder_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_frame_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_light_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_material_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_mesh_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_animation_object (void **object, IDirect3DRM *d3drm)
 
static HRESULT d3drm_create_wrap_object (void **object, IDirect3DRM *d3drm)
 
static struct d3drmimpl_from_IDirect3DRM (IDirect3DRM *iface)
 
static struct d3drmimpl_from_IDirect3DRM2 (IDirect3DRM2 *iface)
 
static struct d3drmimpl_from_IDirect3DRM3 (IDirect3DRM3 *iface)
 
static void d3drm_destroy (struct d3drm *d3drm)
 
static HRESULT WINAPI d3drm1_QueryInterface (IDirect3DRM *iface, REFIID riid, void **out)
 
static ULONG WINAPI d3drm1_AddRef (IDirect3DRM *iface)
 
static ULONG WINAPI d3drm1_Release (IDirect3DRM *iface)
 
static HRESULT WINAPI d3drm1_CreateObject (IDirect3DRM *iface, REFCLSID clsid, IUnknown *outer, REFIID iid, void **out)
 
static HRESULT WINAPI d3drm1_CreateFrame (IDirect3DRM *iface, IDirect3DRMFrame *parent_frame, IDirect3DRMFrame **frame)
 
static HRESULT WINAPI d3drm1_CreateMesh (IDirect3DRM *iface, IDirect3DRMMesh **mesh)
 
static HRESULT WINAPI d3drm1_CreateMeshBuilder (IDirect3DRM *iface, IDirect3DRMMeshBuilder **mesh_builder)
 
static HRESULT WINAPI d3drm1_CreateFace (IDirect3DRM *iface, IDirect3DRMFace **face)
 
static HRESULT WINAPI d3drm1_CreateAnimation (IDirect3DRM *iface, IDirect3DRMAnimation **animation)
 
static HRESULT WINAPI d3drm1_CreateAnimationSet (IDirect3DRM *iface, IDirect3DRMAnimationSet **set)
 
static HRESULT WINAPI d3drm1_CreateTexture (IDirect3DRM *iface, D3DRMIMAGE *image, IDirect3DRMTexture **texture)
 
static HRESULT WINAPI d3drm1_CreateLight (IDirect3DRM *iface, D3DRMLIGHTTYPE type, D3DCOLOR color, IDirect3DRMLight **light)
 
static HRESULT WINAPI d3drm1_CreateLightRGB (IDirect3DRM *iface, D3DRMLIGHTTYPE type, D3DVALUE red, D3DVALUE green, D3DVALUE blue, IDirect3DRMLight **light)
 
static HRESULT WINAPI d3drm1_CreateMaterial (IDirect3DRM *iface, D3DVALUE power, IDirect3DRMMaterial **material)
 
static HRESULT WINAPI d3drm1_CreateDevice (IDirect3DRM *iface, DWORD width, DWORD height, IDirect3DRMDevice **device)
 
static HRESULT WINAPI d3drm1_CreateDeviceFromSurface (IDirect3DRM *iface, GUID *guid, IDirectDraw *ddraw, IDirectDrawSurface *backbuffer, IDirect3DRMDevice **device)
 
static HRESULT WINAPI d3drm1_CreateDeviceFromD3D (IDirect3DRM *iface, IDirect3D *d3d, IDirect3DDevice *d3d_device, IDirect3DRMDevice **device)
 
static HRESULT WINAPI d3drm1_CreateDeviceFromClipper (IDirect3DRM *iface, IDirectDrawClipper *clipper, GUID *guid, int width, int height, IDirect3DRMDevice **device)
 
static HRESULT WINAPI d3drm1_CreateTextureFromSurface (IDirect3DRM *iface, IDirectDrawSurface *surface, IDirect3DRMTexture **texture)
 
static HRESULT WINAPI d3drm1_CreateShadow (IDirect3DRM *iface, IDirect3DRMVisual *visual, IDirect3DRMLight *light, D3DVALUE px, D3DVALUE py, D3DVALUE pz, D3DVALUE nx, D3DVALUE ny, D3DVALUE nz, IDirect3DRMVisual **shadow)
 
static HRESULT WINAPI d3drm1_CreateViewport (IDirect3DRM *iface, IDirect3DRMDevice *device, IDirect3DRMFrame *camera, DWORD x, DWORD y, DWORD width, DWORD height, IDirect3DRMViewport **viewport)
 
static HRESULT WINAPI d3drm1_CreateWrap (IDirect3DRM *iface, D3DRMWRAPTYPE type, IDirect3DRMFrame *frame, D3DVALUE ox, D3DVALUE oy, D3DVALUE oz, D3DVALUE dx, D3DVALUE dy, D3DVALUE dz, D3DVALUE ux, D3DVALUE uy, D3DVALUE uz, D3DVALUE ou, D3DVALUE ov, D3DVALUE su, D3DVALUE sv, IDirect3DRMWrap **wrap)
 
static HRESULT WINAPI d3drm1_CreateUserVisual (IDirect3DRM *iface, D3DRMUSERVISUALCALLBACK cb, void *ctx, IDirect3DRMUserVisual **visual)
 
static HRESULT WINAPI d3drm1_LoadTexture (IDirect3DRM *iface, const char *filename, IDirect3DRMTexture **texture)
 
static HRESULT WINAPI d3drm1_LoadTextureFromResource (IDirect3DRM *iface, HRSRC resource, IDirect3DRMTexture **texture)
 
static HRESULT WINAPI d3drm1_SetSearchPath (IDirect3DRM *iface, const char *path)
 
static HRESULT WINAPI d3drm1_AddSearchPath (IDirect3DRM *iface, const char *path)
 
static HRESULT WINAPI d3drm1_GetSearchPath (IDirect3DRM *iface, DWORD *size, char *path)
 
static HRESULT WINAPI d3drm1_SetDefaultTextureColors (IDirect3DRM *iface, DWORD color_count)
 
static HRESULT WINAPI d3drm1_SetDefaultTextureShades (IDirect3DRM *iface, DWORD shade_count)
 
static HRESULT WINAPI d3drm1_GetDevices (IDirect3DRM *iface, IDirect3DRMDeviceArray **array)
 
static HRESULT WINAPI d3drm1_GetNamedObject (IDirect3DRM *iface, const char *name, IDirect3DRMObject **object)
 
static HRESULT WINAPI d3drm1_EnumerateObjects (IDirect3DRM *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
 
static HRESULT WINAPI d3drm1_Load (IDirect3DRM *iface, void *source, void *object_id, IID **iids, DWORD iid_count, D3DRMLOADOPTIONS flags, D3DRMLOADCALLBACK load_cb, void *load_ctx, D3DRMLOADTEXTURECALLBACK load_tex_cb, void *load_tex_ctx, IDirect3DRMFrame *parent_frame)
 
static HRESULT WINAPI d3drm1_Tick (IDirect3DRM *iface, D3DVALUE tick)
 
static HRESULT WINAPI d3drm2_QueryInterface (IDirect3DRM2 *iface, REFIID riid, void **out)
 
static ULONG WINAPI d3drm2_AddRef (IDirect3DRM2 *iface)
 
static ULONG WINAPI d3drm2_Release (IDirect3DRM2 *iface)
 
static HRESULT WINAPI d3drm2_CreateObject (IDirect3DRM2 *iface, REFCLSID clsid, IUnknown *outer, REFIID iid, void **out)
 
static HRESULT WINAPI d3drm2_CreateFrame (IDirect3DRM2 *iface, IDirect3DRMFrame *parent_frame, IDirect3DRMFrame2 **frame)
 
static HRESULT WINAPI d3drm2_CreateMesh (IDirect3DRM2 *iface, IDirect3DRMMesh **mesh)
 
static HRESULT WINAPI d3drm2_CreateMeshBuilder (IDirect3DRM2 *iface, IDirect3DRMMeshBuilder2 **mesh_builder)
 
static HRESULT WINAPI d3drm2_CreateFace (IDirect3DRM2 *iface, IDirect3DRMFace **face)
 
static HRESULT WINAPI d3drm2_CreateAnimation (IDirect3DRM2 *iface, IDirect3DRMAnimation **animation)
 
static HRESULT WINAPI d3drm2_CreateAnimationSet (IDirect3DRM2 *iface, IDirect3DRMAnimationSet **set)
 
static HRESULT WINAPI d3drm2_CreateTexture (IDirect3DRM2 *iface, D3DRMIMAGE *image, IDirect3DRMTexture2 **texture)
 
static HRESULT WINAPI d3drm2_CreateLight (IDirect3DRM2 *iface, D3DRMLIGHTTYPE type, D3DCOLOR color, IDirect3DRMLight **light)
 
static HRESULT WINAPI d3drm2_CreateLightRGB (IDirect3DRM2 *iface, D3DRMLIGHTTYPE type, D3DVALUE red, D3DVALUE green, D3DVALUE blue, IDirect3DRMLight **light)
 
static HRESULT WINAPI d3drm2_CreateMaterial (IDirect3DRM2 *iface, D3DVALUE power, IDirect3DRMMaterial **material)
 
static HRESULT WINAPI d3drm2_CreateDevice (IDirect3DRM2 *iface, DWORD width, DWORD height, IDirect3DRMDevice2 **device)
 
static HRESULT WINAPI d3drm2_CreateDeviceFromSurface (IDirect3DRM2 *iface, GUID *guid, IDirectDraw *ddraw, IDirectDrawSurface *backbuffer, IDirect3DRMDevice2 **device)
 
static HRESULT WINAPI d3drm2_CreateDeviceFromD3D (IDirect3DRM2 *iface, IDirect3D2 *d3d, IDirect3DDevice2 *d3d_device, IDirect3DRMDevice2 **device)
 
static HRESULT WINAPI d3drm2_CreateDeviceFromClipper (IDirect3DRM2 *iface, IDirectDrawClipper *clipper, GUID *guid, int width, int height, IDirect3DRMDevice2 **device)
 
static HRESULT WINAPI d3drm2_CreateTextureFromSurface (IDirect3DRM2 *iface, IDirectDrawSurface *surface, IDirect3DRMTexture2 **texture)
 
static HRESULT WINAPI d3drm2_CreateShadow (IDirect3DRM2 *iface, IDirect3DRMVisual *visual, IDirect3DRMLight *light, D3DVALUE px, D3DVALUE py, D3DVALUE pz, D3DVALUE nx, D3DVALUE ny, D3DVALUE nz, IDirect3DRMVisual **shadow)
 
static HRESULT WINAPI d3drm2_CreateViewport (IDirect3DRM2 *iface, IDirect3DRMDevice *device, IDirect3DRMFrame *camera, DWORD x, DWORD y, DWORD width, DWORD height, IDirect3DRMViewport **viewport)
 
static HRESULT WINAPI d3drm2_CreateWrap (IDirect3DRM2 *iface, D3DRMWRAPTYPE type, IDirect3DRMFrame *frame, D3DVALUE ox, D3DVALUE oy, D3DVALUE oz, D3DVALUE dx, D3DVALUE dy, D3DVALUE dz, D3DVALUE ux, D3DVALUE uy, D3DVALUE uz, D3DVALUE ou, D3DVALUE ov, D3DVALUE su, D3DVALUE sv, IDirect3DRMWrap **wrap)
 
static HRESULT WINAPI d3drm2_CreateUserVisual (IDirect3DRM2 *iface, D3DRMUSERVISUALCALLBACK cb, void *ctx, IDirect3DRMUserVisual **visual)
 
static HRESULT WINAPI d3drm2_LoadTexture (IDirect3DRM2 *iface, const char *filename, IDirect3DRMTexture2 **texture)
 
static HRESULT WINAPI d3drm2_LoadTextureFromResource (IDirect3DRM2 *iface, HMODULE module, const char *resource_name, const char *resource_type, IDirect3DRMTexture2 **texture)
 
static HRESULT WINAPI d3drm2_SetSearchPath (IDirect3DRM2 *iface, const char *path)
 
static HRESULT WINAPI d3drm2_AddSearchPath (IDirect3DRM2 *iface, const char *path)
 
static HRESULT WINAPI d3drm2_GetSearchPath (IDirect3DRM2 *iface, DWORD *size, char *path)
 
static HRESULT WINAPI d3drm2_SetDefaultTextureColors (IDirect3DRM2 *iface, DWORD color_count)
 
static HRESULT WINAPI d3drm2_SetDefaultTextureShades (IDirect3DRM2 *iface, DWORD shade_count)
 
static HRESULT WINAPI d3drm2_GetDevices (IDirect3DRM2 *iface, IDirect3DRMDeviceArray **array)
 
static HRESULT WINAPI d3drm2_GetNamedObject (IDirect3DRM2 *iface, const char *name, IDirect3DRMObject **object)
 
static HRESULT WINAPI d3drm2_EnumerateObjects (IDirect3DRM2 *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
 
static HRESULT WINAPI d3drm2_Load (IDirect3DRM2 *iface, void *source, void *object_id, IID **iids, DWORD iid_count, D3DRMLOADOPTIONS flags, D3DRMLOADCALLBACK load_cb, void *load_ctx, D3DRMLOADTEXTURECALLBACK load_tex_cb, void *load_tex_ctx, IDirect3DRMFrame *parent_frame)
 
static HRESULT WINAPI d3drm2_Tick (IDirect3DRM2 *iface, D3DVALUE tick)
 
static HRESULT WINAPI d3drm2_CreateProgressiveMesh (IDirect3DRM2 *iface, IDirect3DRMProgressiveMesh **mesh)
 
static HRESULT WINAPI d3drm3_QueryInterface (IDirect3DRM3 *iface, REFIID riid, void **out)
 
static ULONG WINAPI d3drm3_AddRef (IDirect3DRM3 *iface)
 
static ULONG WINAPI d3drm3_Release (IDirect3DRM3 *iface)
 
static HRESULT WINAPI d3drm3_CreateObject (IDirect3DRM3 *iface, REFCLSID clsid, IUnknown *outer, REFIID iid, void **out)
 
static HRESULT WINAPI d3drm3_CreateFrame (IDirect3DRM3 *iface, IDirect3DRMFrame3 *parent, IDirect3DRMFrame3 **frame)
 
static HRESULT WINAPI d3drm3_CreateMesh (IDirect3DRM3 *iface, IDirect3DRMMesh **mesh)
 
static HRESULT WINAPI d3drm3_CreateMeshBuilder (IDirect3DRM3 *iface, IDirect3DRMMeshBuilder3 **mesh_builder)
 
static HRESULT WINAPI d3drm3_CreateFace (IDirect3DRM3 *iface, IDirect3DRMFace2 **face)
 
static HRESULT WINAPI d3drm3_CreateAnimation (IDirect3DRM3 *iface, IDirect3DRMAnimation2 **animation)
 
static HRESULT WINAPI d3drm3_CreateAnimationSet (IDirect3DRM3 *iface, IDirect3DRMAnimationSet2 **set)
 
static HRESULT WINAPI d3drm3_CreateTexture (IDirect3DRM3 *iface, D3DRMIMAGE *image, IDirect3DRMTexture3 **texture)
 
static HRESULT WINAPI d3drm3_CreateLight (IDirect3DRM3 *iface, D3DRMLIGHTTYPE type, D3DCOLOR color, IDirect3DRMLight **light)
 
static HRESULT WINAPI d3drm3_CreateLightRGB (IDirect3DRM3 *iface, D3DRMLIGHTTYPE type, D3DVALUE red, D3DVALUE green, D3DVALUE blue, IDirect3DRMLight **light)
 
static HRESULT WINAPI d3drm3_CreateMaterial (IDirect3DRM3 *iface, D3DVALUE power, IDirect3DRMMaterial2 **material)
 
static HRESULT WINAPI d3drm3_CreateDevice (IDirect3DRM3 *iface, DWORD width, DWORD height, IDirect3DRMDevice3 **device)
 
static HRESULT WINAPI d3drm3_CreateDeviceFromSurface (IDirect3DRM3 *iface, GUID *guid, IDirectDraw *ddraw, IDirectDrawSurface *backbuffer, DWORD flags, IDirect3DRMDevice3 **device)
 
static HRESULT WINAPI d3drm3_CreateDeviceFromD3D (IDirect3DRM3 *iface, IDirect3D2 *d3d, IDirect3DDevice2 *d3d_device, IDirect3DRMDevice3 **device)
 
static HRESULT WINAPI d3drm3_CreateDeviceFromClipper (IDirect3DRM3 *iface, IDirectDrawClipper *clipper, GUID *guid, int width, int height, IDirect3DRMDevice3 **device)
 
static HRESULT WINAPI d3drm3_CreateShadow (IDirect3DRM3 *iface, IUnknown *object, IDirect3DRMLight *light, D3DVALUE px, D3DVALUE py, D3DVALUE pz, D3DVALUE nx, D3DVALUE ny, D3DVALUE nz, IDirect3DRMShadow2 **shadow)
 
static HRESULT WINAPI d3drm3_CreateTextureFromSurface (IDirect3DRM3 *iface, IDirectDrawSurface *surface, IDirect3DRMTexture3 **texture)
 
static HRESULT WINAPI d3drm3_CreateViewport (IDirect3DRM3 *iface, IDirect3DRMDevice3 *device, IDirect3DRMFrame3 *camera, DWORD x, DWORD y, DWORD width, DWORD height, IDirect3DRMViewport2 **viewport)
 
static HRESULT WINAPI d3drm3_CreateWrap (IDirect3DRM3 *iface, D3DRMWRAPTYPE type, IDirect3DRMFrame3 *frame, D3DVALUE ox, D3DVALUE oy, D3DVALUE oz, D3DVALUE dx, D3DVALUE dy, D3DVALUE dz, D3DVALUE ux, D3DVALUE uy, D3DVALUE uz, D3DVALUE ou, D3DVALUE ov, D3DVALUE su, D3DVALUE sv, IDirect3DRMWrap **wrap)
 
static HRESULT WINAPI d3drm3_CreateUserVisual (IDirect3DRM3 *iface, D3DRMUSERVISUALCALLBACK cb, void *ctx, IDirect3DRMUserVisual **visual)
 
static HRESULT WINAPI d3drm3_LoadTexture (IDirect3DRM3 *iface, const char *filename, IDirect3DRMTexture3 **texture)
 
static HRESULT WINAPI d3drm3_LoadTextureFromResource (IDirect3DRM3 *iface, HMODULE module, const char *resource_name, const char *resource_type, IDirect3DRMTexture3 **texture)
 
static HRESULT WINAPI d3drm3_SetSearchPath (IDirect3DRM3 *iface, const char *path)
 
static HRESULT WINAPI d3drm3_AddSearchPath (IDirect3DRM3 *iface, const char *path)
 
static HRESULT WINAPI d3drm3_GetSearchPath (IDirect3DRM3 *iface, DWORD *size, char *path)
 
static HRESULT WINAPI d3drm3_SetDefaultTextureColors (IDirect3DRM3 *iface, DWORD color_count)
 
static HRESULT WINAPI d3drm3_SetDefaultTextureShades (IDirect3DRM3 *iface, DWORD shade_count)
 
static HRESULT WINAPI d3drm3_GetDevices (IDirect3DRM3 *iface, IDirect3DRMDeviceArray **array)
 
static HRESULT WINAPI d3drm3_GetNamedObject (IDirect3DRM3 *iface, const char *name, IDirect3DRMObject **object)
 
static HRESULT WINAPI d3drm3_EnumerateObjects (IDirect3DRM3 *iface, D3DRMOBJECTCALLBACK cb, void *ctx)
 
static HRESULT load_data (IDirect3DRM3 *iface, IDirectXFileData *data_object, IID **GUIDs, DWORD nb_GUIDs, D3DRMLOADCALLBACK LoadProc, void *ArgLP, D3DRMLOADTEXTURECALLBACK LoadTextureProc, void *ArgLTP, IDirect3DRMFrame3 *parent_frame)
 
static HRESULT WINAPI d3drm3_Load (IDirect3DRM3 *iface, void *source, void *object_id, IID **iids, DWORD iid_count, D3DRMLOADOPTIONS flags, D3DRMLOADCALLBACK load_cb, void *load_ctx, D3DRMLOADTEXTURECALLBACK load_tex_cb, void *load_tex_ctx, IDirect3DRMFrame3 *parent_frame)
 
static HRESULT WINAPI d3drm3_Tick (IDirect3DRM3 *iface, D3DVALUE tick)
 
static HRESULT WINAPI d3drm3_CreateProgressiveMesh (IDirect3DRM3 *iface, IDirect3DRMProgressiveMesh **mesh)
 
static HRESULT WINAPI d3drm3_RegisterClient (IDirect3DRM3 *iface, REFGUID guid, DWORD *id)
 
static HRESULT WINAPI d3drm3_UnregisterClient (IDirect3DRM3 *iface, REFGUID guid)
 
static HRESULT WINAPI d3drm3_CreateClippedVisual (IDirect3DRM3 *iface, IDirect3DRMVisual *visual, IDirect3DRMClippedVisual **clipped_visual)
 
static HRESULT WINAPI d3drm3_SetOptions (IDirect3DRM3 *iface, DWORD flags)
 
static HRESULT WINAPI d3drm3_GetOptions (IDirect3DRM3 *iface, DWORD *flags)
 
HRESULT WINAPI Direct3DRMCreate (IDirect3DRM **d3drm)
 
HRESULT WINAPI DllCanUnloadNow (void)
 
HRESULT WINAPI DllGetClassObject (REFCLSID rclsid, REFIID riid, void **ppv)
 

Variables

static const struct IDirect3DRMVtbl d3drm1_vtbl
 
static const struct IDirect3DRM2Vtbl d3drm2_vtbl
 
static const struct IDirect3DRM3Vtbl d3drm3_vtbl
 

Function Documentation

◆ d3drm1_AddRef()

static ULONG WINAPI d3drm1_AddRef ( IDirect3DRM *  iface)
static

Definition at line 247 of file d3drm.c.

248 {
249  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
250  ULONG refcount = InterlockedIncrement(&d3drm->ref1);
251 
252  TRACE("%p increasing refcount to %u.\n", iface, refcount);
253 
254  if (refcount == 1)
256 
257  return refcount;
258 }
#define TRACE(s)
Definition: solgame.cpp:4
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
LONG iface_count
Definition: d3drm.c:193
Definition: d3drm.c:188
#define InterlockedIncrement
Definition: armddk.h:53
unsigned int ULONG
Definition: retypes.h:1
LONG ref1
Definition: d3drm.c:193

◆ d3drm1_AddSearchPath()

static HRESULT WINAPI d3drm1_AddSearchPath ( IDirect3DRM *  iface,
const char path 
)
static

Definition at line 681 of file d3drm.c.

682 {
683  FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
684 
685  return E_NOTIMPL;
686 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define debugstr_a
Definition: kernel32.h:31
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm1_CreateAnimation()

static HRESULT WINAPI d3drm1_CreateAnimation ( IDirect3DRM *  iface,
IDirect3DRMAnimation **  animation 
)
static

Definition at line 333 of file d3drm.c.

334 {
335  struct d3drm_animation *object;
336  HRESULT hr;
337 
338  TRACE("iface %p, animation %p.\n", iface, animation);
339 
340  if (!animation)
341  return D3DRMERR_BADVALUE;
342 
343  if (FAILED(hr = d3drm_animation_create(&object, iface)))
344  return hr;
345 
346  *animation = &object->IDirect3DRMAnimation_iface;
347 
348  return S_OK;
349 }
HRESULT hr
Definition: shlfolder.c:183
HRESULT d3drm_animation_create(struct d3drm_animation **animation, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: frame.c:3881
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
#define S_OK
Definition: intsafe.h:51
void * object
Definition: jmemsys.h:48

◆ d3drm1_CreateAnimationSet()

static HRESULT WINAPI d3drm1_CreateAnimationSet ( IDirect3DRM *  iface,
IDirect3DRMAnimationSet **  set 
)
static

Definition at line 351 of file d3drm.c.

352 {
353  FIXME("iface %p, set %p stub!\n", iface, set);
354 
355  return E_NOTIMPL;
356 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99
Definition: _set.h:46

◆ d3drm1_CreateDevice()

static HRESULT WINAPI d3drm1_CreateDevice ( IDirect3DRM *  iface,
DWORD  width,
DWORD  height,
IDirect3DRMDevice **  device 
)
static

Definition at line 413 of file d3drm.c.

415 {
416  TRACE("iface %p, width %u, height %u, device %p.\n", iface, width, height, device);
417 
418  if (!device)
419  return D3DRMERR_BADVALUE;
420  *device = NULL;
421 
422  return D3DRMERR_BADDEVICE;
423 }
GLint GLint GLsizei width
Definition: gl.h:1546
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
#define D3DRMERR_BADDEVICE
Definition: d3drm.h:495

◆ d3drm1_CreateDeviceFromClipper()

static HRESULT WINAPI d3drm1_CreateDeviceFromClipper ( IDirect3DRM *  iface,
IDirectDrawClipper *  clipper,
GUID guid,
int  width,
int  height,
IDirect3DRMDevice **  device 
)
static

Definition at line 477 of file d3drm.c.

480 {
481  struct d3drm_device *object;
482  IDirectDraw *ddraw;
483  IDirectDrawSurface *render_target;
484  HRESULT hr;
485 
486  TRACE("iface %p, clipper %p, guid %s, width %d, height %d, device %p.\n",
488 
489  if (!device)
490  return D3DRMERR_BADVALUE;
491  *device = NULL;
492 
493  if (!clipper || !width || !height)
494  return D3DRMERR_BADVALUE;
495 
497  if (FAILED(hr))
498  return hr;
499 
500  if (FAILED(hr = d3drm_device_create(&object, iface)))
501  {
502  IDirectDraw_Release(ddraw);
503  return hr;
504  }
505 
507  if (FAILED(hr))
508  {
509  IDirectDraw_Release(ddraw);
510  d3drm_device_destroy(object);
511  return hr;
512  }
513 
514  hr = d3drm_device_init(object, 1, ddraw, render_target, TRUE);
515  IDirectDraw_Release(ddraw);
516  IDirectDrawSurface_Release(render_target);
517  if (FAILED(hr))
518  d3drm_device_destroy(object);
519  else
520  *device = &object->IDirect3DRMDevice_iface;
521 
522  return hr;
523 }
GLint GLint GLsizei width
Definition: gl.h:1546
HRESULT hr
Definition: shlfolder.c:183
#define TRUE
Definition: types.h:120
HRESULT d3drm_device_create(struct d3drm_device **device, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: device.c:1634
HRESULT WINAPI DirectDrawCreate(LPGUID lpGUID, LPDIRECTDRAW *lplpDD, LPUNKNOWN pUnkOuter)
Definition: main.c:86
const GUID * guid
HRESULT d3drm_device_create_surfaces_from_clipper(struct d3drm_device *object, IDirectDraw *ddraw, IDirectDrawClipper *clipper, int width, int height, IDirectDrawSurface **surface) DECLSPEC_HIDDEN
Definition: device.c:69
Definition: devices.h:37
void d3drm_device_destroy(struct d3drm_device *device) DECLSPEC_HIDDEN
Definition: device.c:40
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
HRESULT d3drm_device_init(struct d3drm_device *device, UINT version, IDirectDraw *ddraw, IDirectDrawSurface *surface, BOOL create_z_surface) DECLSPEC_HIDDEN
Definition: device.c:120
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
IDirectDrawClipper * clipper
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
IDirectDrawSurface * render_target
IDirectDraw * ddraw
void * object
Definition: jmemsys.h:48

◆ d3drm1_CreateDeviceFromD3D()

static HRESULT WINAPI d3drm1_CreateDeviceFromD3D ( IDirect3DRM *  iface,
IDirect3D *  d3d,
IDirect3DDevice *  d3d_device,
IDirect3DRMDevice **  device 
)
static

Definition at line 452 of file d3drm.c.

454 {
455  struct d3drm_device *object;
456  HRESULT hr;
457  TRACE("iface %p, d3d %p, d3d_device %p, device %p.\n",
458  iface, d3d, d3d_device, device);
459 
460  if (!device)
461  return D3DRMERR_BADVALUE;
462  *device = NULL;
463 
464  if (FAILED(hr = d3drm_device_create(&object, iface)))
465  return hr;
466 
467  if (FAILED(hr = IDirect3DRMDevice_InitFromD3D(&object->IDirect3DRMDevice_iface, d3d, d3d_device)))
468  {
469  d3drm_device_destroy(object);
470  return hr;
471  }
472  *device = &object->IDirect3DRMDevice_iface;
473 
474  return D3DRM_OK;
475 }
HRESULT hr
Definition: shlfolder.c:183
HRESULT d3drm_device_create(struct d3drm_device **device, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: device.c:1634
Definition: devices.h:37
void d3drm_device_destroy(struct d3drm_device *device) DECLSPEC_HIDDEN
Definition: device.c:40
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
#define IDirect3DRMDevice_InitFromD3D(p, a, b)
Definition: d3drmobj.h:421
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
void * object
Definition: jmemsys.h:48

◆ d3drm1_CreateDeviceFromSurface()

static HRESULT WINAPI d3drm1_CreateDeviceFromSurface ( IDirect3DRM *  iface,
GUID guid,
IDirectDraw *  ddraw,
IDirectDrawSurface *  backbuffer,
IDirect3DRMDevice **  device 
)
static

Definition at line 425 of file d3drm.c.

427 {
428  struct d3drm_device *object;
429  HRESULT hr;
430 
431  TRACE("iface %p, guid %s, ddraw %p, backbuffer %p, device %p.\n",
432  iface, debugstr_guid(guid), ddraw, backbuffer, device);
433 
434  if (!device)
435  return D3DRMERR_BADVALUE;
436  *device = NULL;
437 
438  if (!backbuffer || !ddraw)
439  return D3DRMERR_BADDEVICE;
440 
441  if (FAILED(hr = d3drm_device_create(&object, iface)))
442  return hr;
443 
444  if (SUCCEEDED(hr = d3drm_device_init(object, 1, ddraw, backbuffer, TRUE)))
445  *device = &object->IDirect3DRMDevice_iface;
446  else
447  d3drm_device_destroy(object);
448 
449  return hr;
450 }
HRESULT hr
Definition: shlfolder.c:183
#define TRUE
Definition: types.h:120
HRESULT d3drm_device_create(struct d3drm_device **device, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: device.c:1634
const GUID * guid
Definition: devices.h:37
void d3drm_device_destroy(struct d3drm_device *device) DECLSPEC_HIDDEN
Definition: device.c:40
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
HRESULT d3drm_device_init(struct d3drm_device *device, UINT version, IDirectDraw *ddraw, IDirectDrawSurface *surface, BOOL create_z_surface) DECLSPEC_HIDDEN
Definition: device.c:120
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
#define D3DRMERR_BADDEVICE
Definition: d3drm.h:495
void * object
Definition: jmemsys.h:48
#define SUCCEEDED(hr)
Definition: intsafe.h:49

◆ d3drm1_CreateFace()

static HRESULT WINAPI d3drm1_CreateFace ( IDirect3DRM *  iface,
IDirect3DRMFace **  face 
)
static

Definition at line 318 of file d3drm.c.

319 {
320  struct d3drm_face *object;
321  HRESULT hr;
322 
323  TRACE("iface %p, face %p.\n", iface, face);
324 
325  if (FAILED(hr = d3drm_face_create(&object)))
326  return hr;
327 
328  *face = &object->IDirect3DRMFace_iface;
329 
330  return S_OK;
331 }
HRESULT hr
Definition: shlfolder.c:183
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
HRESULT d3drm_face_create(struct d3drm_face **face) DECLSPEC_HIDDEN
Definition: face.c:620
#define S_OK
Definition: intsafe.h:51
void * object
Definition: jmemsys.h:48
GLenum GLuint GLint GLenum face
Definition: glext.h:7025

◆ d3drm1_CreateFrame()

static HRESULT WINAPI d3drm1_CreateFrame ( IDirect3DRM *  iface,
IDirect3DRMFrame *  parent_frame,
IDirect3DRMFrame **  frame 
)
static

Definition at line 284 of file d3drm.c.

286 {
287  struct d3drm_frame *object;
288  HRESULT hr;
289 
290  TRACE("iface %p, parent_frame %p, frame %p.\n", iface, parent_frame, frame);
291 
292  if (FAILED(hr = d3drm_frame_create(&object, (IUnknown *)parent_frame, iface)))
293  return hr;
294 
295  *frame = &object->IDirect3DRMFrame_iface;
296 
297  return D3DRM_OK;
298 }
HRESULT hr
Definition: shlfolder.c:183
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
HRESULT d3drm_frame_create(struct d3drm_frame **frame, IUnknown *parent_frame, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: frame.c:3129
void * object
Definition: jmemsys.h:48

◆ d3drm1_CreateLight()

static HRESULT WINAPI d3drm1_CreateLight ( IDirect3DRM *  iface,
D3DRMLIGHTTYPE  type,
D3DCOLOR  color,
IDirect3DRMLight **  light 
)
static

Definition at line 382 of file d3drm.c.

384 {
385  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
386 
387  TRACE("iface %p, type %#x, color 0x%08x, light %p.\n", iface, type, color, light);
388 
390 }
#define IDirect3DRM3_CreateLight(p, a, b, c)
Definition: d3drm.h:410
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
GLuint color
Definition: glext.h:6243
#define TRACE(s)
Definition: solgame.cpp:4
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
Definition: d3drm.c:188
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm1_CreateLightRGB()

static HRESULT WINAPI d3drm1_CreateLightRGB ( IDirect3DRM *  iface,
D3DRMLIGHTTYPE  type,
D3DVALUE  red,
D3DVALUE  green,
D3DVALUE  blue,
IDirect3DRMLight **  light 
)
static

Definition at line 392 of file d3drm.c.

394 {
395  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
396 
397  TRACE("iface %p, type %#x, red %.8e, green %.8e, blue %.8e, light %p.\n",
398  iface, type, red, green, blue, light);
399 
401 }
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
GLclampf GLclampf blue
Definition: gl.h:1740
#define TRACE(s)
Definition: solgame.cpp:4
GLclampf green
Definition: gl.h:1740
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
#define red
Definition: linetest.c:67
#define IDirect3DRM3_CreateLightRGB(p, a, b, c, d, e)
Definition: d3drm.h:411
Definition: d3drm.c:188
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm1_CreateMaterial()

static HRESULT WINAPI d3drm1_CreateMaterial ( IDirect3DRM *  iface,
D3DVALUE  power,
IDirect3DRMMaterial **  material 
)
static

Definition at line 403 of file d3drm.c.

405 {
406  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
407 
408  TRACE("iface %p, power %.8e, material %p.\n", iface, power, material);
409 
410  return IDirect3DRM3_CreateMaterial(&d3drm->IDirect3DRM3_iface, power, (IDirect3DRMMaterial2 **)material);
411 }
#define IDirect3DRM3_CreateMaterial(p, a, b)
Definition: d3drm.h:412
#define TRACE(s)
Definition: solgame.cpp:4
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
Definition: d3drm.c:188
float power
Definition: d3drm.c:3372
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm1_CreateMesh()

static HRESULT WINAPI d3drm1_CreateMesh ( IDirect3DRM *  iface,
IDirect3DRMMesh **  mesh 
)
static

Definition at line 300 of file d3drm.c.

301 {
302  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
303 
304  TRACE("iface %p, mesh %p.\n", iface, mesh);
305 
307 }
Definition: mesh.c:197
#define IDirect3DRM3_CreateMesh(p, a)
Definition: d3drm.h:404
#define TRACE(s)
Definition: solgame.cpp:4
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
Definition: d3drm.c:188
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm1_CreateMeshBuilder()

static HRESULT WINAPI d3drm1_CreateMeshBuilder ( IDirect3DRM *  iface,
IDirect3DRMMeshBuilder **  mesh_builder 
)
static

Definition at line 309 of file d3drm.c.

310 {
311  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
312 
313  TRACE("iface %p, mesh_builder %p.\n", iface, mesh_builder);
314 
315  return IDirect3DRM2_CreateMeshBuilder(&d3drm->IDirect3DRM2_iface, (IDirect3DRMMeshBuilder2 **)mesh_builder);
316 }
#define TRACE(s)
Definition: solgame.cpp:4
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
IDirect3DRM2 IDirect3DRM2_iface
Definition: d3drm.c:191
#define IDirect3DRM2_CreateMeshBuilder(p, a)
Definition: d3drm.h:257
IDirect3DRMMeshBuilder * mesh_builder
Definition: d3drm.c:3330
Definition: d3drm.c:188

◆ d3drm1_CreateObject()

static HRESULT WINAPI d3drm1_CreateObject ( IDirect3DRM *  iface,
REFCLSID  clsid,
IUnknown outer,
REFIID  iid,
void **  out 
)
static

Definition at line 273 of file d3drm.c.

275 {
276  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
277 
278  TRACE("iface %p, clsid %s, outer %p, iid %s, out %p.\n",
279  iface, debugstr_guid(clsid), outer, debugstr_guid(iid), out);
280 
282 }
#define IDirect3DRM3_CreateObject(p, a, b, c, d)
Definition: d3drm.h:402
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
static FILE * out
Definition: regtests2xml.c:44
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
REFCLSID clsid
Definition: msctf.c:82
Definition: d3drm.c:188
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm1_CreateShadow()

static HRESULT WINAPI d3drm1_CreateShadow ( IDirect3DRM *  iface,
IDirect3DRMVisual *  visual,
IDirect3DRMLight *  light,
D3DVALUE  px,
D3DVALUE  py,
D3DVALUE  pz,
D3DVALUE  nx,
D3DVALUE  ny,
D3DVALUE  nz,
IDirect3DRMVisual **  shadow 
)
static

Definition at line 549 of file d3drm.c.

552 {
553  FIXME("iface %p, visual %p, light %p, px %.8e, py %.8e, pz %.8e, nx %.8e, ny %.8e, nz %.8e, shadow %p stub!\n",
554  iface, visual, light, px, py, pz, nx, ny, nz, shadow);
555 
556  return E_NOTIMPL;
557 }
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
GLfloat GLfloat nz
Definition: glext.h:8896
#define FIXME(fmt,...)
Definition: debug.h:111
GLfloat GLfloat GLfloat GLfloat nx
Definition: glext.h:8898
#define E_NOTIMPL
Definition: ddrawi.h:99
GLfloat ny
Definition: glext.h:8896

◆ d3drm1_CreateTexture()

static HRESULT WINAPI d3drm1_CreateTexture ( IDirect3DRM *  iface,
D3DRMIMAGE image,
IDirect3DRMTexture **  texture 
)
static

Definition at line 358 of file d3drm.c.

360 {
361  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
362  IDirect3DRMTexture3 *texture3;
363  HRESULT hr;
364 
365  TRACE("iface %p, image %p, texture %p.\n", iface, image, texture);
366 
367  if (!texture)
368  return D3DRMERR_BADVALUE;
369 
371  {
372  *texture = NULL;
373  return hr;
374  }
375 
376  hr = IDirect3DRMTexture3_QueryInterface(texture3, &IID_IDirect3DRMTexture, (void **)texture);
377  IDirect3DRMTexture3_Release(texture3);
378 
379  return hr;
380 }
HRESULT hr
Definition: shlfolder.c:183
#define IDirect3DRM3_CreateTexture(p, a, b)
Definition: d3drm.h:409
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define IDirect3DRMTexture3_QueryInterface(p, a, b)
Definition: d3drmobj.h:3474
#define IDirect3DRMTexture3_Release(p)
Definition: d3drmobj.h:3476
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm1_CreateTextureFromSurface()

static HRESULT WINAPI d3drm1_CreateTextureFromSurface ( IDirect3DRM *  iface,
IDirectDrawSurface *  surface,
IDirect3DRMTexture **  texture 
)
static

Definition at line 525 of file d3drm.c.

527 {
528  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
529  IDirect3DRMTexture3 *texture3;
530  HRESULT hr;
531 
532  TRACE("iface %p, surface %p, texture %p.\n", iface, surface, texture);
533 
534  if (!texture)
535  return D3DRMERR_BADVALUE;
536 
538  {
539  *texture = NULL;
540  return hr;
541  }
542 
543  hr = IDirect3DRMTexture3_QueryInterface(texture3, &IID_IDirect3DRMTexture, (void **)texture);
544  IDirect3DRMTexture3_Release(texture3);
545 
546  return hr;
547 }
HRESULT hr
Definition: shlfolder.c:183
#define IDirect3DRM3_CreateTextureFromSurface(p, a, b)
Definition: d3drm.h:417
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define IDirect3DRMTexture3_QueryInterface(p, a, b)
Definition: d3drmobj.h:3474
#define IDirect3DRMTexture3_Release(p)
Definition: d3drmobj.h:3476
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm1_CreateUserVisual()

static HRESULT WINAPI d3drm1_CreateUserVisual ( IDirect3DRM *  iface,
D3DRMUSERVISUALCALLBACK  cb,
void ctx,
IDirect3DRMUserVisual **  visual 
)
static

Definition at line 622 of file d3drm.c.

624 {
625  FIXME("iface %p, cb %p, ctx %p visual %p stub!\n", iface, cb, ctx, visual);
626 
627  return E_NOTIMPL;
628 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32

◆ d3drm1_CreateViewport()

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

Definition at line 559 of file d3drm.c.

561 {
562  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
563  IDirect3DRMDevice3 *device3;
564  IDirect3DRMFrame3 *camera3;
565  IDirect3DRMViewport2 *viewport2;
566  HRESULT hr;
567 
568  TRACE("iface %p, device %p, camera %p, x %u, y %u, width %u, height %u, viewport %p.\n",
569  iface, device, camera, x, y, width, height, viewport);
570 
571  if (!viewport)
572  return D3DRMERR_BADVALUE;
573  *viewport = NULL;
574 
575  if (!device || !camera)
576  return D3DRMERR_BADOBJECT;
577 
578  if (FAILED(hr = IDirect3DRMDevice_QueryInterface(device, &IID_IDirect3DRMDevice3, (void **)&device3)))
579  return hr;
580 
581  if (FAILED(hr = IDirect3DRMFrame_QueryInterface(camera, &IID_IDirect3DRMFrame3, (void **)&camera3)))
582  {
584  return hr;
585  }
586 
587  hr = IDirect3DRM3_CreateViewport(&d3drm->IDirect3DRM3_iface, device3, camera3, x, y, width, height, &viewport2);
589  IDirect3DRMFrame3_Release(camera3);
590  if (FAILED(hr))
591  return hr;
592 
593  hr = IDirect3DRMViewport2_QueryInterface(viewport2, &IID_IDirect3DRMViewport, (void **)viewport);
594  IDirect3DRMViewport2_Release(viewport2);
595 
596  return hr;
597 }
GLint GLint GLsizei width
Definition: gl.h:1546
#define IDirect3DRM3_CreateViewport(p, a, b, c, d, e, f, g)
Definition: d3drm.h:419
#define IDirect3DRMViewport2_Release(p)
Definition: d3drmobj.h:991
HRESULT hr
Definition: shlfolder.c:183
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
#define IDirect3DRMDevice3_Release(p)
Definition: d3drmobj.h:693
#define IDirect3DRMViewport2_QueryInterface(p, a, b)
Definition: d3drmobj.h:989
#define D3DRMERR_BADOBJECT
Definition: d3drm.h:487
Definition: devices.h:37
#define IDirect3DRMDevice_QueryInterface(p, a, b)
Definition: d3drmobj.h:407
smooth NULL
Definition: ftsmooth.c:416
#define IDirect3DRMFrame3_Release(p)
Definition: d3drmobj.h:1708
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
Definition: d3drm.c:188
#define IDirect3DRMFrame_QueryInterface(p, a, b)
Definition: d3drmobj.h:1166
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm1_CreateWrap()

static HRESULT WINAPI d3drm1_CreateWrap ( IDirect3DRM *  iface,
D3DRMWRAPTYPE  type,
IDirect3DRMFrame *  frame,
D3DVALUE  ox,
D3DVALUE  oy,
D3DVALUE  oz,
D3DVALUE  dx,
D3DVALUE  dy,
D3DVALUE  dz,
D3DVALUE  ux,
D3DVALUE  uy,
D3DVALUE  uz,
D3DVALUE  ou,
D3DVALUE  ov,
D3DVALUE  su,
D3DVALUE  sv,
IDirect3DRMWrap **  wrap 
)
static

Definition at line 599 of file d3drm.c.

603 {
604  struct d3drm_wrap *object;
605  HRESULT hr;
606 
607  FIXME("iface %p, type %#x, frame %p, ox %.8e, oy %.8e, oz %.8e, dx %.8e, dy %.8e, dz %.8e, "
608  "ux %.8e, uy %.8e, uz %.8e, ou %.8e, ov %.8e, su %.8e, sv %.8e, wrap %p, semi-stub.\n",
609  iface, type, frame, ox, oy, oz, dx, dy, dz, ux, uy, uz, ou, ov, su, sv, wrap);
610 
611  if (!wrap)
612  return D3DRMERR_BADVALUE;
613 
614  if (FAILED(hr = d3drm_wrap_create(&object, iface)))
615  return hr;
616 
617  *wrap = &object->IDirect3DRMWrap_iface;
618 
619  return S_OK;
620 }
HRESULT hr
Definition: shlfolder.c:183
GLint dy
Definition: linetemp.h:97
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
#define FIXME(fmt,...)
Definition: debug.h:111
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
#define S_OK
Definition: intsafe.h:51
HRESULT d3drm_wrap_create(struct d3drm_wrap **wrap, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: meshbuilder.c:3019
GLint dx
Definition: linetemp.h:97
#define wrap(journal, var)
Definition: recovery.c:207
void * object
Definition: jmemsys.h:48

◆ d3drm1_EnumerateObjects()

static HRESULT WINAPI d3drm1_EnumerateObjects ( IDirect3DRM *  iface,
D3DRMOBJECTCALLBACK  cb,
void ctx 
)
static

Definition at line 724 of file d3drm.c.

725 {
726  FIXME("iface %p, cb %p, ctx %p stub!\n", iface, cb, ctx);
727 
728  return E_NOTIMPL;
729 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32

◆ d3drm1_GetDevices()

static HRESULT WINAPI d3drm1_GetDevices ( IDirect3DRM *  iface,
IDirect3DRMDeviceArray **  array 
)
static

Definition at line 709 of file d3drm.c.

710 {
711  FIXME("iface %p, array %p stub!\n", iface, array);
712 
713  return E_NOTIMPL;
714 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm1_GetNamedObject()

static HRESULT WINAPI d3drm1_GetNamedObject ( IDirect3DRM *  iface,
const char name,
IDirect3DRMObject **  object 
)
static

Definition at line 716 of file d3drm.c.

718 {
719  FIXME("iface %p, name %s, object %p stub!\n", iface, debugstr_a(name), object);
720 
721  return E_NOTIMPL;
722 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define debugstr_a
Definition: kernel32.h:31
#define E_NOTIMPL
Definition: ddrawi.h:99
Definition: name.c:38

◆ d3drm1_GetSearchPath()

static HRESULT WINAPI d3drm1_GetSearchPath ( IDirect3DRM *  iface,
DWORD size,
char path 
)
static

Definition at line 688 of file d3drm.c.

689 {
690  FIXME("iface %p, size %p, path %p stub!\n", iface, size, path);
691 
692  return E_NOTIMPL;
693 }
#define FIXME(fmt,...)
Definition: debug.h:111
GLsizeiptr size
Definition: glext.h:5919
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm1_Load()

static HRESULT WINAPI d3drm1_Load ( IDirect3DRM *  iface,
void source,
void object_id,
IID **  iids,
DWORD  iid_count,
D3DRMLOADOPTIONS  flags,
D3DRMLOADCALLBACK  load_cb,
void load_ctx,
D3DRMLOADTEXTURECALLBACK  load_tex_cb,
void load_tex_ctx,
IDirect3DRMFrame *  parent_frame 
)
static

Definition at line 731 of file d3drm.c.

734 {
735  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
736  IDirect3DRMFrame3 *parent_frame3 = NULL;
737  HRESULT hr = D3DRM_OK;
738 
739  TRACE("iface %p, source %p, object_id %p, iids %p, iid_count %u, flags %#x, "
740  "load_cb %p, load_ctx %p, load_tex_cb %p, load_tex_ctx %p, parent_frame %p.\n",
741  iface, source, object_id, iids, iid_count, flags,
742  load_cb, load_ctx, load_tex_cb, load_tex_ctx, parent_frame);
743 
744  if (parent_frame)
745  hr = IDirect3DRMFrame_QueryInterface(parent_frame, &IID_IDirect3DRMFrame3, (void **)&parent_frame3);
746  if (SUCCEEDED(hr))
747  hr = IDirect3DRM3_Load(&d3drm->IDirect3DRM3_iface, source, object_id, iids, iid_count,
748  flags, load_cb, load_ctx, load_tex_cb, load_tex_ctx, parent_frame3);
749  if (parent_frame3)
750  IDirect3DRMFrame3_Release(parent_frame3);
751 
752  return hr;
753 }
HRESULT hr
Definition: shlfolder.c:183
#define IDirect3DRM3_Load(p, a, b, c, d, e, f, g, h, i, j)
Definition: d3drm.h:432
smooth NULL
Definition: ftsmooth.c:416
#define IDirect3DRMFrame3_Release(p)
Definition: d3drmobj.h:1708
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
GLbitfield flags
Definition: glext.h:7161
Definition: d3drm.c:188
#define IDirect3DRMFrame_QueryInterface(p, a, b)
Definition: d3drmobj.h:1166
#define SUCCEEDED(hr)
Definition: intsafe.h:49
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm1_LoadTexture()

static HRESULT WINAPI d3drm1_LoadTexture ( IDirect3DRM *  iface,
const char filename,
IDirect3DRMTexture **  texture 
)
static

Definition at line 630 of file d3drm.c.

632 {
633  struct d3drm_texture *object;
634  HRESULT hr;
635 
636  TRACE("iface %p, filename %s, texture %p.\n", iface, debugstr_a(filename), texture);
637 
638  if (!texture)
639  return D3DRMERR_BADVALUE;
640 
641  if (FAILED(hr = d3drm_texture_create(&object, iface)))
642  return hr;
643 
644  *texture = &object->IDirect3DRMTexture_iface;
646  {
648  *texture = NULL;
649  if (!filename)
650  return D3DRMERR_BADVALUE;
651 
653  }
654 
655  return D3DRM_OK;
656 }
HRESULT hr
Definition: shlfolder.c:183
const char * filename
Definition: ioapi.h:135
#define D3DRMERR_BADOBJECT
Definition: d3drm.h:487
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
#define debugstr_a
Definition: kernel32.h:31
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
HRESULT d3drm_texture_create(struct d3drm_texture **texture, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: texture.c:1412
#define IDirect3DRMTexture_InitFromFile(p, a)
Definition: d3drmobj.h:3243
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
#define D3DRMERR_FILENOTFOUND
Definition: d3drm.h:493
void * object
Definition: jmemsys.h:48
#define IDirect3DRMTexture_Release(p)
Definition: d3drmobj.h:3232

◆ d3drm1_LoadTextureFromResource()

static HRESULT WINAPI d3drm1_LoadTextureFromResource ( IDirect3DRM *  iface,
HRSRC  resource,
IDirect3DRMTexture **  texture 
)
static

Definition at line 658 of file d3drm.c.

660 {
661  struct d3drm_texture *object;
662  HRESULT hr;
663 
664  FIXME("iface %p, resource %p, texture %p stub!\n", iface, resource, texture);
665 
666  if (FAILED(hr = d3drm_texture_create(&object, iface)))
667  return hr;
668 
669  *texture = &object->IDirect3DRMTexture_iface;
670 
671  return D3DRM_OK;
672 }
HRESULT hr
Definition: shlfolder.c:183
#define FIXME(fmt,...)
Definition: debug.h:111
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
HRESULT d3drm_texture_create(struct d3drm_texture **texture, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: texture.c:1412
void * object
Definition: jmemsys.h:48

◆ d3drm1_QueryInterface()

static HRESULT WINAPI d3drm1_QueryInterface ( IDirect3DRM *  iface,
REFIID  riid,
void **  out 
)
static

Definition at line 217 of file d3drm.c.

218 {
219  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
220 
221  TRACE("iface %p, riid %s, out %p.\n", iface, debugstr_guid(riid), out);
222 
223  if (IsEqualGUID(riid, &IID_IDirect3DRM)
225  {
227  }
228  else if (IsEqualGUID(riid, &IID_IDirect3DRM2))
229  {
231  }
232  else if (IsEqualGUID(riid, &IID_IDirect3DRM3))
233  {
235  }
236  else
237  {
238  *out = NULL;
239  WARN("%s not implemented, returning CLASS_E_CLASSNOTAVAILABLE.\n", debugstr_guid(riid));
241  }
242 
243  IUnknown_AddRef((IUnknown *)*out);
244  return S_OK;
245 }
REFIID riid
Definition: precomp.h:44
#define WARN(fmt,...)
Definition: debug.h:112
#define CLASS_E_CLASSNOTAVAILABLE
Definition: winerror.h:2663
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
const GUID IID_IUnknown
static FILE * out
Definition: regtests2xml.c:44
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
IDirect3DRM2 IDirect3DRM2_iface
Definition: d3drm.c:191
Definition: d3drm.c:188
#define S_OK
Definition: intsafe.h:51
BOOL WINAPI IsEqualGUID(REFGUID rguid1, REFGUID rguid2)
Definition: compobj.c:4112
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

Referenced by d3drm2_QueryInterface(), and d3drm3_QueryInterface().

◆ d3drm1_Release()

static ULONG WINAPI d3drm1_Release ( IDirect3DRM *  iface)
static

Definition at line 260 of file d3drm.c.

261 {
262  struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
263  ULONG refcount = InterlockedDecrement(&d3drm->ref1);
264 
265  TRACE("%p decreasing refcount to %u.\n", iface, refcount);
266 
267  if (!refcount && !InterlockedDecrement(&d3drm->iface_count))
269 
270  return refcount;
271 }
#define TRACE(s)
Definition: solgame.cpp:4
static struct d3drm * impl_from_IDirect3DRM(IDirect3DRM *iface)
Definition: d3drm.c:196
#define InterlockedDecrement
Definition: armddk.h:52
static void d3drm_destroy(struct d3drm *d3drm)
Definition: d3drm.c:211
LONG iface_count
Definition: d3drm.c:193
Definition: d3drm.c:188
unsigned int ULONG
Definition: retypes.h:1
LONG ref1
Definition: d3drm.c:193

◆ d3drm1_SetDefaultTextureColors()

static HRESULT WINAPI d3drm1_SetDefaultTextureColors ( IDirect3DRM *  iface,
DWORD  color_count 
)
static

Definition at line 695 of file d3drm.c.

696 {
697  FIXME("iface %p, color_count %u stub!\n", iface, color_count);
698 
699  return E_NOTIMPL;
700 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm1_SetDefaultTextureShades()

static HRESULT WINAPI d3drm1_SetDefaultTextureShades ( IDirect3DRM *  iface,
DWORD  shade_count 
)
static

Definition at line 702 of file d3drm.c.

703 {
704  FIXME("iface %p, shade_count %u stub!\n", iface, shade_count);
705 
706  return E_NOTIMPL;
707 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm1_SetSearchPath()

static HRESULT WINAPI d3drm1_SetSearchPath ( IDirect3DRM *  iface,
const char path 
)
static

Definition at line 674 of file d3drm.c.

675 {
676  FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
677 
678  return E_NOTIMPL;
679 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define debugstr_a
Definition: kernel32.h:31
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm1_Tick()

static HRESULT WINAPI d3drm1_Tick ( IDirect3DRM *  iface,
D3DVALUE  tick 
)
static

Definition at line 755 of file d3drm.c.

756 {
757  FIXME("iface %p, tick %.8e stub!\n", iface, tick);
758 
759  return E_NOTIMPL;
760 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm2_AddRef()

static ULONG WINAPI d3drm2_AddRef ( IDirect3DRM2 *  iface)
static

Definition at line 808 of file d3drm.c.

809 {
810  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
811  ULONG refcount = InterlockedIncrement(&d3drm->ref2);
812 
813  TRACE("%p increasing refcount to %u.\n", iface, refcount);
814 
815  if (refcount == 1)
817 
818  return refcount;
819 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define TRACE(s)
Definition: solgame.cpp:4
LONG iface_count
Definition: d3drm.c:193
Definition: d3drm.c:188
#define InterlockedIncrement
Definition: armddk.h:53
LONG ref2
Definition: d3drm.c:193
unsigned int ULONG
Definition: retypes.h:1

◆ d3drm2_AddSearchPath()

static HRESULT WINAPI d3drm2_AddSearchPath ( IDirect3DRM2 *  iface,
const char path 
)
static

Definition at line 1195 of file d3drm.c.

1196 {
1197  FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
1198 
1199  return E_NOTIMPL;
1200 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define debugstr_a
Definition: kernel32.h:31
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm2_CreateAnimation()

static HRESULT WINAPI d3drm2_CreateAnimation ( IDirect3DRM2 *  iface,
IDirect3DRMAnimation **  animation 
)
static

Definition at line 896 of file d3drm.c.

897 {
898  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
899 
900  TRACE("iface %p, animation %p.\n", iface, animation);
901 
903 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
#define IDirect3DRM_CreateAnimation(p, a)
Definition: d3drm.h:118
Definition: d3drm.c:188

◆ d3drm2_CreateAnimationSet()

static HRESULT WINAPI d3drm2_CreateAnimationSet ( IDirect3DRM2 *  iface,
IDirect3DRMAnimationSet **  set 
)
static

Definition at line 905 of file d3drm.c.

906 {
907  FIXME("iface %p, set %p stub!\n", iface, set);
908 
909  return E_NOTIMPL;
910 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99
Definition: _set.h:46

◆ d3drm2_CreateDevice()

static HRESULT WINAPI d3drm2_CreateDevice ( IDirect3DRM2 *  iface,
DWORD  width,
DWORD  height,
IDirect3DRMDevice2 **  device 
)
static

Definition at line 967 of file d3drm.c.

969 {
970  TRACE("iface %p, width %u, height %u, device %p.\n", iface, width, height, device);
971 
972  if (!device)
973  return D3DRMERR_BADVALUE;
974  *device = NULL;
975 
976  return D3DRMERR_BADDEVICE;
977 }
GLint GLint GLsizei width
Definition: gl.h:1546
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
#define D3DRMERR_BADDEVICE
Definition: d3drm.h:495

◆ d3drm2_CreateDeviceFromClipper()

static HRESULT WINAPI d3drm2_CreateDeviceFromClipper ( IDirect3DRM2 *  iface,
IDirectDrawClipper *  clipper,
GUID guid,
int  width,
int  height,
IDirect3DRMDevice2 **  device 
)
static

Definition at line 1025 of file d3drm.c.

1028 {
1029  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
1030  IDirect3DRMDevice3 *device3;
1031  HRESULT hr;
1032 
1033  TRACE("iface %p, clipper %p, guid %s, width %d, height %d, device %p.\n",
1034  iface, clipper, debugstr_guid(guid), width, height, device);
1035 
1036  if (!device)
1037  return D3DRMERR_BADVALUE;
1038  *device = NULL;
1040  if (FAILED(hr))
1041  return hr;
1042 
1043  hr = IDirect3DRMDevice3_QueryInterface(device3, &IID_IDirect3DRMDevice2, (void**)device);
1044  IDirect3DRMDevice3_Release(device3);
1045 
1046  return hr;
1047 }
GLint GLint GLsizei width
Definition: gl.h:1546
HRESULT hr
Definition: shlfolder.c:183
#define IDirect3DRMDevice3_QueryInterface(p, a, b)
Definition: d3drmobj.h:691
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define IDirect3DRMDevice3_Release(p)
Definition: d3drmobj.h:693
const GUID * guid
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
Definition: d3drm.c:188
#define IDirect3DRM3_CreateDeviceFromClipper(p, a, b, c, d, e)
Definition: d3drm.h:416
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateDeviceFromD3D()

static HRESULT WINAPI d3drm2_CreateDeviceFromD3D ( IDirect3DRM2 *  iface,
IDirect3D2 *  d3d,
IDirect3DDevice2 *  d3d_device,
IDirect3DRMDevice2 **  device 
)
static

Definition at line 1001 of file d3drm.c.

1003 {
1004  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
1005  IDirect3DRMDevice3 *device3;
1006  HRESULT hr;
1007 
1008  TRACE("iface %p, d3d %p, d3d_device %p, device %p.\n",
1009  iface, d3d, d3d_device, device);
1010 
1011  if (!device)
1012  return D3DRMERR_BADVALUE;
1013  *device = NULL;
1014 
1016  if (FAILED(hr))
1017  return hr;
1018 
1019  hr = IDirect3DRMDevice3_QueryInterface(device3, &IID_IDirect3DRMDevice2, (void **)device);
1020  IDirect3DRMDevice3_Release(device3);
1021 
1022  return hr;
1023 }
HRESULT hr
Definition: shlfolder.c:183
#define IDirect3DRMDevice3_QueryInterface(p, a, b)
Definition: d3drmobj.h:691
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define IDirect3DRMDevice3_Release(p)
Definition: d3drmobj.h:693
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define IDirect3DRM3_CreateDeviceFromD3D(p, a, b, c)
Definition: d3drm.h:415
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateDeviceFromSurface()

static HRESULT WINAPI d3drm2_CreateDeviceFromSurface ( IDirect3DRM2 *  iface,
GUID guid,
IDirectDraw *  ddraw,
IDirectDrawSurface *  backbuffer,
IDirect3DRMDevice2 **  device 
)
static

Definition at line 979 of file d3drm.c.

981 {
982  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
983  IDirect3DRMDevice3 *device3;
984  HRESULT hr;
985  TRACE("iface %p, guid %s, ddraw %p, backbuffer %p, device %p.\n",
986  iface, debugstr_guid(guid), ddraw, backbuffer, device);
987 
988  if (!device)
989  return D3DRMERR_BADVALUE;
990  *device = NULL;
992  if (FAILED(hr))
993  return hr;
994 
995  hr = IDirect3DRMDevice3_QueryInterface(device3, &IID_IDirect3DRMDevice2, (void**)device);
997 
998  return hr;
999 }
HRESULT hr
Definition: shlfolder.c:183
#define IDirect3DRMDevice3_QueryInterface(p, a, b)
Definition: d3drmobj.h:691
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define IDirect3DRMDevice3_Release(p)
Definition: d3drmobj.h:693
const GUID * guid
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define IDirect3DRM3_CreateDeviceFromSurface(p, a, b, c, d, e)
Definition: d3drm.h:414
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateFace()

static HRESULT WINAPI d3drm2_CreateFace ( IDirect3DRM2 *  iface,
IDirect3DRMFace **  face 
)
static

Definition at line 887 of file d3drm.c.

888 {
889  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
890 
891  TRACE("iface %p, face %p.\n", iface, face);
892 
894 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
Definition: d3drm.c:188
#define IDirect3DRM_CreateFace(p, a)
Definition: d3drm.h:117
GLenum GLuint GLint GLenum face
Definition: glext.h:7025

◆ d3drm2_CreateFrame()

static HRESULT WINAPI d3drm2_CreateFrame ( IDirect3DRM2 *  iface,
IDirect3DRMFrame *  parent_frame,
IDirect3DRMFrame2 **  frame 
)
static

Definition at line 845 of file d3drm.c.

847 {
848  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
849  struct d3drm_frame *object;
850  HRESULT hr;
851 
852  TRACE("iface %p, parent_frame %p, frame %p.\n", iface, parent_frame, frame);
853 
854  if (FAILED(hr = d3drm_frame_create(&object, (IUnknown *)parent_frame, &d3drm->IDirect3DRM_iface)))
855  return hr;
856 
857  *frame = &object->IDirect3DRMFrame2_iface;
858 
859  return D3DRM_OK;
860 }
HRESULT hr
Definition: shlfolder.c:183
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
Definition: d3drm.c:188
HRESULT d3drm_frame_create(struct d3drm_frame **frame, IUnknown *parent_frame, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: frame.c:3129
void * object
Definition: jmemsys.h:48

◆ d3drm2_CreateLight()

static HRESULT WINAPI d3drm2_CreateLight ( IDirect3DRM2 *  iface,
D3DRMLIGHTTYPE  type,
D3DCOLOR  color,
IDirect3DRMLight **  light 
)
static

Definition at line 936 of file d3drm.c.

938 {
939  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
940 
941  TRACE("iface %p, type %#x, color 0x%08x, light %p.\n", iface, type, color, light);
942 
944 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define IDirect3DRM3_CreateLight(p, a, b, c)
Definition: d3drm.h:410
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
GLuint color
Definition: glext.h:6243
#define TRACE(s)
Definition: solgame.cpp:4
Definition: d3drm.c:188
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateLightRGB()

static HRESULT WINAPI d3drm2_CreateLightRGB ( IDirect3DRM2 *  iface,
D3DRMLIGHTTYPE  type,
D3DVALUE  red,
D3DVALUE  green,
D3DVALUE  blue,
IDirect3DRMLight **  light 
)
static

Definition at line 946 of file d3drm.c.

948 {
949  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
950 
951  TRACE("iface %p, type %#x, red %.8e, green %.8e, blue %.8e, light %p.\n",
952  iface, type, red, green, blue, light);
953 
955 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
GLclampf GLclampf blue
Definition: gl.h:1740
#define TRACE(s)
Definition: solgame.cpp:4
GLclampf green
Definition: gl.h:1740
#define red
Definition: linetest.c:67
#define IDirect3DRM3_CreateLightRGB(p, a, b, c, d, e)
Definition: d3drm.h:411
Definition: d3drm.c:188
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateMaterial()

static HRESULT WINAPI d3drm2_CreateMaterial ( IDirect3DRM2 *  iface,
D3DVALUE  power,
IDirect3DRMMaterial **  material 
)
static

Definition at line 957 of file d3drm.c.

959 {
960  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
961 
962  TRACE("iface %p, power %.8e, material %p.\n", iface, power, material);
963 
964  return IDirect3DRM3_CreateMaterial(&d3drm->IDirect3DRM3_iface, power, (IDirect3DRMMaterial2 **)material);
965 }
#define IDirect3DRM3_CreateMaterial(p, a, b)
Definition: d3drm.h:412
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define TRACE(s)
Definition: solgame.cpp:4
Definition: d3drm.c:188
float power
Definition: d3drm.c:3372
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateMesh()

static HRESULT WINAPI d3drm2_CreateMesh ( IDirect3DRM2 *  iface,
IDirect3DRMMesh **  mesh 
)
static

Definition at line 862 of file d3drm.c.

863 {
864  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
865 
866  TRACE("iface %p, mesh %p.\n", iface, mesh);
867 
869 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
Definition: mesh.c:197
#define IDirect3DRM3_CreateMesh(p, a)
Definition: d3drm.h:404
#define TRACE(s)
Definition: solgame.cpp:4
Definition: d3drm.c:188
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateMeshBuilder()

static HRESULT WINAPI d3drm2_CreateMeshBuilder ( IDirect3DRM2 *  iface,
IDirect3DRMMeshBuilder2 **  mesh_builder 
)
static

Definition at line 871 of file d3drm.c.

872 {
873  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
874  struct d3drm_mesh_builder *object;
875  HRESULT hr;
876 
877  TRACE("iface %p, mesh_builder %p.\n", iface, mesh_builder);
878 
880  return hr;
881 
882  *mesh_builder = &object->IDirect3DRMMeshBuilder2_iface;
883 
884  return S_OK;
885 }
HRESULT hr
Definition: shlfolder.c:183
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
HRESULT d3drm_mesh_builder_create(struct d3drm_mesh_builder **mesh_builder, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: meshbuilder.c:2334
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
IDirect3DRMMeshBuilder * mesh_builder
Definition: d3drm.c:3330
Definition: d3drm.c:188
#define S_OK
Definition: intsafe.h:51
void * object
Definition: jmemsys.h:48

◆ d3drm2_CreateObject()

static HRESULT WINAPI d3drm2_CreateObject ( IDirect3DRM2 *  iface,
REFCLSID  clsid,
IUnknown outer,
REFIID  iid,
void **  out 
)
static

Definition at line 834 of file d3drm.c.

836 {
837  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
838 
839  TRACE("iface %p, clsid %s, outer %p, iid %s, out %p.\n",
840  iface, debugstr_guid(clsid), outer, debugstr_guid(iid), out);
841 
843 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define IDirect3DRM3_CreateObject(p, a, b, c, d)
Definition: d3drm.h:402
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
static FILE * out
Definition: regtests2xml.c:44
REFCLSID clsid
Definition: msctf.c:82
Definition: d3drm.c:188
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateProgressiveMesh()

static HRESULT WINAPI d3drm2_CreateProgressiveMesh ( IDirect3DRM2 *  iface,
IDirect3DRMProgressiveMesh **  mesh 
)
static

Definition at line 1276 of file d3drm.c.

1277 {
1278  FIXME("iface %p, mesh %p stub!\n", iface, mesh);
1279 
1280  return E_NOTIMPL;
1281 }
Definition: mesh.c:197
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm2_CreateShadow()

static HRESULT WINAPI d3drm2_CreateShadow ( IDirect3DRM2 *  iface,
IDirect3DRMVisual *  visual,
IDirect3DRMLight *  light,
D3DVALUE  px,
D3DVALUE  py,
D3DVALUE  pz,
D3DVALUE  nx,
D3DVALUE  ny,
D3DVALUE  nz,
IDirect3DRMVisual **  shadow 
)
static

Definition at line 1073 of file d3drm.c.

1076 {
1077  FIXME("iface %p, visual %p, light %p, px %.8e, py %.8e, pz %.8e, nx %.8e, ny %.8e, nz %.8e, shadow %p stub!\n",
1078  iface, visual, light, px, py, pz, nx, ny, nz, shadow);
1079 
1080  return E_NOTIMPL;
1081 }
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
GLfloat GLfloat nz
Definition: glext.h:8896
#define FIXME(fmt,...)
Definition: debug.h:111
GLfloat GLfloat GLfloat GLfloat nx
Definition: glext.h:8898
#define E_NOTIMPL
Definition: ddrawi.h:99
GLfloat ny
Definition: glext.h:8896

◆ d3drm2_CreateTexture()

static HRESULT WINAPI d3drm2_CreateTexture ( IDirect3DRM2 *  iface,
D3DRMIMAGE image,
IDirect3DRMTexture2 **  texture 
)
static

Definition at line 912 of file d3drm.c.

914 {
915  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
916  IDirect3DRMTexture3 *texture3;
917  HRESULT hr;
918 
919  TRACE("iface %p, image %p, texture %p.\n", iface, image, texture);
920 
921  if (!texture)
922  return D3DRMERR_BADVALUE;
923 
925  {
926  *texture = NULL;
927  return hr;
928  }
929 
930  hr = IDirect3DRMTexture3_QueryInterface(texture3, &IID_IDirect3DRMTexture2, (void **)texture);
931  IDirect3DRMTexture3_Release(texture3);
932 
933  return hr;
934 }
HRESULT hr
Definition: shlfolder.c:183
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define IDirect3DRM3_CreateTexture(p, a, b)
Definition: d3drm.h:409
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define IDirect3DRMTexture3_QueryInterface(p, a, b)
Definition: d3drmobj.h:3474
#define IDirect3DRMTexture3_Release(p)
Definition: d3drmobj.h:3476
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateTextureFromSurface()

static HRESULT WINAPI d3drm2_CreateTextureFromSurface ( IDirect3DRM2 *  iface,
IDirectDrawSurface *  surface,
IDirect3DRMTexture2 **  texture 
)
static

Definition at line 1049 of file d3drm.c.

1051 {
1052  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
1053  IDirect3DRMTexture3 *texture3;
1054  HRESULT hr;
1055 
1056  TRACE("iface %p, surface %p, texture %p.\n", iface, surface, texture);
1057 
1058  if (!texture)
1059  return D3DRMERR_BADVALUE;
1060 
1062  {
1063  *texture = NULL;
1064  return hr;
1065  }
1066 
1067  hr = IDirect3DRMTexture3_QueryInterface(texture3, &IID_IDirect3DRMTexture, (void **)texture);
1068  IDirect3DRMTexture3_Release(texture3);
1069 
1070  return hr;
1071 }
HRESULT hr
Definition: shlfolder.c:183
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define IDirect3DRM3_CreateTextureFromSurface(p, a, b)
Definition: d3drm.h:417
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define IDirect3DRMTexture3_QueryInterface(p, a, b)
Definition: d3drmobj.h:3474
#define IDirect3DRMTexture3_Release(p)
Definition: d3drmobj.h:3476
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateUserVisual()

static HRESULT WINAPI d3drm2_CreateUserVisual ( IDirect3DRM2 *  iface,
D3DRMUSERVISUALCALLBACK  cb,
void ctx,
IDirect3DRMUserVisual **  visual 
)
static

Definition at line 1138 of file d3drm.c.

1140 {
1141  FIXME("iface %p, cb %p, ctx %p, visual %p stub!\n", iface, cb, ctx, visual);
1142 
1143  return E_NOTIMPL;
1144 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32

◆ d3drm2_CreateViewport()

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

Definition at line 1083 of file d3drm.c.

1085 {
1086  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
1087  IDirect3DRMDevice3 *device3;
1088  IDirect3DRMFrame3 *camera3;
1089  IDirect3DRMViewport2 *viewport2;
1090  HRESULT hr;
1091 
1092  TRACE("iface %p, device %p, camera %p, x %u, y %u, width %u, height %u, viewport %p.\n",
1093  iface, device, camera, x, y, width, height, viewport);
1094 
1095  if (!viewport)
1096  return D3DRMERR_BADVALUE;
1097  *viewport = NULL;
1098 
1099  if (!device || !camera)
1100  return D3DRMERR_BADOBJECT;
1101 
1102  if (FAILED(hr = IDirect3DRMDevice_QueryInterface(device, &IID_IDirect3DRMDevice3, (void **)&device3)))
1103  return hr;
1104 
1105  if (FAILED(hr = IDirect3DRMFrame_QueryInterface(camera, &IID_IDirect3DRMFrame3, (void **)&camera3)))
1106  {
1107  IDirect3DRMDevice3_Release(device3);
1108  return hr;
1109  }
1110 
1111  hr = IDirect3DRM3_CreateViewport(&d3drm->IDirect3DRM3_iface, device3, camera3, x, y, width, height, &viewport2);
1112  IDirect3DRMDevice3_Release(device3);
1113  IDirect3DRMFrame3_Release(camera3);
1114  if (FAILED(hr))
1115  return hr;
1116 
1117  hr = IDirect3DRMViewport2_QueryInterface(viewport2, &IID_IDirect3DRMViewport, (void **)viewport);
1118  IDirect3DRMViewport2_Release(viewport2);
1119 
1120  return hr;
1121 }
GLint GLint GLsizei width
Definition: gl.h:1546
#define IDirect3DRM3_CreateViewport(p, a, b, c, d, e, f, g)
Definition: d3drm.h:419
#define IDirect3DRMViewport2_Release(p)
Definition: d3drmobj.h:991
HRESULT hr
Definition: shlfolder.c:183
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
#define IDirect3DRMDevice3_Release(p)
Definition: d3drmobj.h:693
#define IDirect3DRMViewport2_QueryInterface(p, a, b)
Definition: d3drmobj.h:989
#define D3DRMERR_BADOBJECT
Definition: d3drm.h:487
Definition: devices.h:37
#define IDirect3DRMDevice_QueryInterface(p, a, b)
Definition: d3drmobj.h:407
smooth NULL
Definition: ftsmooth.c:416
#define IDirect3DRMFrame3_Release(p)
Definition: d3drmobj.h:1708
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
Definition: d3drm.c:188
#define IDirect3DRMFrame_QueryInterface(p, a, b)
Definition: d3drmobj.h:1166
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_CreateWrap()

static HRESULT WINAPI d3drm2_CreateWrap ( IDirect3DRM2 *  iface,
D3DRMWRAPTYPE  type,
IDirect3DRMFrame *  frame,
D3DVALUE  ox,
D3DVALUE  oy,
D3DVALUE  oz,
D3DVALUE  dx,
D3DVALUE  dy,
D3DVALUE  dz,
D3DVALUE  ux,
D3DVALUE  uy,
D3DVALUE  uz,
D3DVALUE  ou,
D3DVALUE  ov,
D3DVALUE  su,
D3DVALUE  sv,
IDirect3DRMWrap **  wrap 
)
static

Definition at line 1123 of file d3drm.c.

1127 {
1128  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
1129 
1130  TRACE("iface %p, type %#x, frame %p, ox %.8e, oy %.8e, oz %.8e, dx %.8e, dy %.8e, dz %.8e, "
1131  "ux %.8e, uy %.8e, uz %.8e, ou %.8e, ov %.8e, su %.8e, sv %.8e, wrap %p.\n",
1132  iface, type, frame, ox, oy, oz, dx, dy, dz, ux, uy, uz, ou, ov, su, sv, wrap);
1133 
1134  return IDirect3DRM_CreateWrap(&d3drm->IDirect3DRM_iface, type, frame, ox, oy, oz, dx, dy, dz, ux, uy, uz,
1135  ou, ov, su, sv, wrap);
1136 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
GLint dy
Definition: linetemp.h:97
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
#define IDirect3DRM_CreateWrap(p, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, q)
Definition: d3drm.h:131
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
Definition: d3drm.c:188
GLint dx
Definition: linetemp.h:97
#define wrap(journal, var)
Definition: recovery.c:207

◆ d3drm2_EnumerateObjects()

static HRESULT WINAPI d3drm2_EnumerateObjects ( IDirect3DRM2 *  iface,
D3DRMOBJECTCALLBACK  cb,
void ctx 
)
static

Definition at line 1238 of file d3drm.c.

1239 {
1240  FIXME("iface %p, cb %p, ctx %p stub!\n", iface, cb, ctx);
1241 
1242  return E_NOTIMPL;
1243 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32

◆ d3drm2_GetDevices()

static HRESULT WINAPI d3drm2_GetDevices ( IDirect3DRM2 *  iface,
IDirect3DRMDeviceArray **  array 
)
static

Definition at line 1223 of file d3drm.c.

1224 {
1225  FIXME("iface %p, array %p stub!\n", iface, array);
1226 
1227  return E_NOTIMPL;
1228 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm2_GetNamedObject()

static HRESULT WINAPI d3drm2_GetNamedObject ( IDirect3DRM2 *  iface,
const char name,
IDirect3DRMObject **  object 
)
static

Definition at line 1230 of file d3drm.c.

1232 {
1233  FIXME("iface %p, name %s, object %p stub!\n", iface, debugstr_a(name), object);
1234 
1235  return E_NOTIMPL;
1236 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define debugstr_a
Definition: kernel32.h:31
#define E_NOTIMPL
Definition: ddrawi.h:99
Definition: name.c:38

◆ d3drm2_GetSearchPath()

static HRESULT WINAPI d3drm2_GetSearchPath ( IDirect3DRM2 *  iface,
DWORD size,
char path 
)
static

Definition at line 1202 of file d3drm.c.

1203 {
1204  FIXME("iface %p, size %p, path %p stub!\n", iface, size, path);
1205 
1206  return E_NOTIMPL;
1207 }
#define FIXME(fmt,...)
Definition: debug.h:111
GLsizeiptr size
Definition: glext.h:5919
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm2_Load()

static HRESULT WINAPI d3drm2_Load ( IDirect3DRM2 *  iface,
void source,
void object_id,
IID **  iids,
DWORD  iid_count,
D3DRMLOADOPTIONS  flags,
D3DRMLOADCALLBACK  load_cb,
void load_ctx,
D3DRMLOADTEXTURECALLBACK  load_tex_cb,
void load_tex_ctx,
IDirect3DRMFrame *  parent_frame 
)
static

Definition at line 1245 of file d3drm.c.

1248 {
1249  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
1250  IDirect3DRMFrame3 *parent_frame3 = NULL;
1251  HRESULT hr = D3DRM_OK;
1252 
1253  TRACE("iface %p, source %p, object_id %p, iids %p, iid_count %u, flags %#x, "
1254  "load_cb %p, load_ctx %p, load_tex_cb %p, load_tex_ctx %p, parent_frame %p.\n",
1255  iface, source, object_id, iids, iid_count, flags,
1256  load_cb, load_ctx, load_tex_cb, load_tex_ctx, parent_frame);
1257 
1258  if (parent_frame)
1259  hr = IDirect3DRMFrame_QueryInterface(parent_frame, &IID_IDirect3DRMFrame3, (void **)&parent_frame3);
1260  if (SUCCEEDED(hr))
1261  hr = IDirect3DRM3_Load(&d3drm->IDirect3DRM3_iface, source, object_id, iids, iid_count,
1262  flags, load_cb, load_ctx, load_tex_cb, load_tex_ctx, parent_frame3);
1263  if (parent_frame3)
1264  IDirect3DRMFrame3_Release(parent_frame3);
1265 
1266  return hr;
1267 }
HRESULT hr
Definition: shlfolder.c:183
#define IDirect3DRM3_Load(p, a, b, c, d, e, f, g, h, i, j)
Definition: d3drm.h:432
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
smooth NULL
Definition: ftsmooth.c:416
#define IDirect3DRMFrame3_Release(p)
Definition: d3drmobj.h:1708
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
GLbitfield flags
Definition: glext.h:7161
Definition: d3drm.c:188
#define IDirect3DRMFrame_QueryInterface(p, a, b)
Definition: d3drmobj.h:1166
#define SUCCEEDED(hr)
Definition: intsafe.h:49
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192

◆ d3drm2_LoadTexture()

static HRESULT WINAPI d3drm2_LoadTexture ( IDirect3DRM2 *  iface,
const char filename,
IDirect3DRMTexture2 **  texture 
)
static

Definition at line 1146 of file d3drm.c.

1148 {
1149  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
1150  IDirect3DRMTexture3 *texture3;
1151  HRESULT hr;
1152 
1153  TRACE("iface %p, filename %s, texture %p.\n", iface, debugstr_a(filename), texture);
1154 
1155  if (!texture)
1156  return D3DRMERR_BADVALUE;
1157 
1159  {
1160  *texture = NULL;
1161  return hr;
1162  }
1163 
1164  hr = IDirect3DRMTexture3_QueryInterface(texture3, &IID_IDirect3DRMTexture2, (void **)texture);
1165  IDirect3DRMTexture3_Release(texture3);
1166 
1167  return hr;
1168 }
HRESULT hr
Definition: shlfolder.c:183
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
const char * filename
Definition: ioapi.h:135
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
#define debugstr_a
Definition: kernel32.h:31
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define IDirect3DRMTexture3_QueryInterface(p, a, b)
Definition: d3drmobj.h:3474
#define IDirect3DRMTexture3_Release(p)
Definition: d3drmobj.h:3476
IDirect3DRM3 IDirect3DRM3_iface
Definition: d3drm.c:192
#define IDirect3DRM3_LoadTexture(p, a, b)
Definition: d3drm.h:422

◆ d3drm2_LoadTextureFromResource()

static HRESULT WINAPI d3drm2_LoadTextureFromResource ( IDirect3DRM2 *  iface,
HMODULE  module,
const char resource_name,
const char resource_type,
IDirect3DRMTexture2 **  texture 
)
static

Definition at line 1170 of file d3drm.c.

1172 {
1173  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
1174  struct d3drm_texture *object;
1175  HRESULT hr;
1176 
1177  FIXME("iface %p, resource_name %s, resource_type %s, texture %p stub!\n",
1178  iface, debugstr_a(resource_name), debugstr_a(resource_type), texture);
1179 
1181  return hr;
1182 
1183  *texture = &object->IDirect3DRMTexture2_iface;
1184 
1185  return D3DRM_OK;
1186 }
HRESULT hr
Definition: shlfolder.c:183
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define FIXME(fmt,...)
Definition: debug.h:111
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
#define debugstr_a
Definition: kernel32.h:31
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
HRESULT d3drm_texture_create(struct d3drm_texture **texture, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: texture.c:1412
Definition: d3drm.c:188
void * object
Definition: jmemsys.h:48

◆ d3drm2_QueryInterface()

static HRESULT WINAPI d3drm2_QueryInterface ( IDirect3DRM2 *  iface,
REFIID  riid,
void **  out 
)
static

Definition at line 801 of file d3drm.c.

802 {
803  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
804 
806 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
REFIID riid
Definition: precomp.h:44
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
static FILE * out
Definition: regtests2xml.c:44
static HRESULT WINAPI d3drm1_QueryInterface(IDirect3DRM *iface, REFIID riid, void **out)
Definition: d3drm.c:217
Definition: d3drm.c:188

◆ d3drm2_Release()

static ULONG WINAPI d3drm2_Release ( IDirect3DRM2 *  iface)
static

Definition at line 821 of file d3drm.c.

822 {
823  struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
824  ULONG refcount = InterlockedDecrement(&d3drm->ref2);
825 
826  TRACE("%p decreasing refcount to %u.\n", iface, refcount);
827 
828  if (!refcount && !InterlockedDecrement(&d3drm->iface_count))
830 
831  return refcount;
832 }
static struct d3drm * impl_from_IDirect3DRM2(IDirect3DRM2 *iface)
Definition: d3drm.c:201
#define TRACE(s)
Definition: solgame.cpp:4
#define InterlockedDecrement
Definition: armddk.h:52
static void d3drm_destroy(struct d3drm *d3drm)
Definition: d3drm.c:211
LONG iface_count
Definition: d3drm.c:193
Definition: d3drm.c:188
LONG ref2
Definition: d3drm.c:193
unsigned int ULONG
Definition: retypes.h:1

◆ d3drm2_SetDefaultTextureColors()

static HRESULT WINAPI d3drm2_SetDefaultTextureColors ( IDirect3DRM2 *  iface,
DWORD  color_count 
)
static

Definition at line 1209 of file d3drm.c.

1210 {
1211  FIXME("iface %p, color_count %u stub!\n", iface, color_count);
1212 
1213  return E_NOTIMPL;
1214 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm2_SetDefaultTextureShades()

static HRESULT WINAPI d3drm2_SetDefaultTextureShades ( IDirect3DRM2 *  iface,
DWORD  shade_count 
)
static

Definition at line 1216 of file d3drm.c.

1217 {
1218  FIXME("iface %p, shade_count %u stub!\n", iface, shade_count);
1219 
1220  return E_NOTIMPL;
1221 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm2_SetSearchPath()

static HRESULT WINAPI d3drm2_SetSearchPath ( IDirect3DRM2 *  iface,
const char path 
)
static

Definition at line 1188 of file d3drm.c.

1189 {
1190  FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
1191 
1192  return E_NOTIMPL;
1193 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define debugstr_a
Definition: kernel32.h:31
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm2_Tick()

static HRESULT WINAPI d3drm2_Tick ( IDirect3DRM2 *  iface,
D3DVALUE  tick 
)
static

Definition at line 1269 of file d3drm.c.

1270 {
1271  FIXME("iface %p, tick %.8e stub!\n", iface, tick);
1272 
1273  return E_NOTIMPL;
1274 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm3_AddRef()

static ULONG WINAPI d3drm3_AddRef ( IDirect3DRM3 *  iface)
static

Definition at line 1330 of file d3drm.c.

1331 {
1332  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1333  ULONG refcount = InterlockedIncrement(&d3drm->ref3);
1334 
1335  TRACE("%p increasing refcount to %u.\n", iface, refcount);
1336 
1337  if (refcount == 1)
1339 
1340  return refcount;
1341 }
#define TRACE(s)
Definition: solgame.cpp:4
LONG iface_count
Definition: d3drm.c:193
Definition: d3drm.c:188
#define InterlockedIncrement
Definition: armddk.h:53
LONG ref3
Definition: d3drm.c:193
unsigned int ULONG
Definition: retypes.h:1
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_AddSearchPath()

static HRESULT WINAPI d3drm3_AddSearchPath ( IDirect3DRM3 *  iface,
const char path 
)
static

Definition at line 1873 of file d3drm.c.

1874 {
1875  FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
1876 
1877  return E_NOTIMPL;
1878 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define debugstr_a
Definition: kernel32.h:31
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm3_CreateAnimation()

static HRESULT WINAPI d3drm3_CreateAnimation ( IDirect3DRM3 *  iface,
IDirect3DRMAnimation2 **  animation 
)
static

Definition at line 1495 of file d3drm.c.

1496 {
1497  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1498  struct d3drm_animation *object;
1499  HRESULT hr;
1500 
1501  TRACE("iface %p, animation %p.\n", iface, animation);
1502 
1504  return hr;
1505 
1506  *animation = &object->IDirect3DRMAnimation2_iface;
1507 
1508  return hr;
1509 }
HRESULT hr
Definition: shlfolder.c:183
HRESULT d3drm_animation_create(struct d3drm_animation **animation, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: frame.c:3881
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
Definition: d3drm.c:188
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateAnimationSet()

static HRESULT WINAPI d3drm3_CreateAnimationSet ( IDirect3DRM3 *  iface,
IDirect3DRMAnimationSet2 **  set 
)
static

Definition at line 1511 of file d3drm.c.

1512 {
1513  FIXME("iface %p, set %p stub!\n", iface, set);
1514 
1515  return E_NOTIMPL;
1516 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99
Definition: _set.h:46

◆ d3drm3_CreateClippedVisual()

static HRESULT WINAPI d3drm3_CreateClippedVisual ( IDirect3DRM3 *  iface,
IDirect3DRMVisual *  visual,
IDirect3DRMClippedVisual **  clipped_visual 
)
static

Definition at line 2255 of file d3drm.c.

2257 {
2258  FIXME("iface %p, visual %p, clipped_visual %p stub!\n", iface, visual, clipped_visual);
2259 
2260  return E_NOTIMPL;
2261 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm3_CreateDevice()

static HRESULT WINAPI d3drm3_CreateDevice ( IDirect3DRM3 *  iface,
DWORD  width,
DWORD  height,
IDirect3DRMDevice3 **  device 
)
static

Definition at line 1603 of file d3drm.c.

1605 {
1606  TRACE("iface %p, width %u, height %u, device %p.\n", iface, width, height, device);
1607 
1608  if (!device)
1609  return D3DRMERR_BADVALUE;
1610  *device = NULL;
1611 
1612  return D3DRMERR_BADDEVICE;
1613 }
GLint GLint GLsizei width
Definition: gl.h:1546
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
#define D3DRMERR_BADDEVICE
Definition: d3drm.h:495

◆ d3drm3_CreateDeviceFromClipper()

static HRESULT WINAPI d3drm3_CreateDeviceFromClipper ( IDirect3DRM3 *  iface,
IDirectDrawClipper *  clipper,
GUID guid,
int  width,
int  height,
IDirect3DRMDevice3 **  device 
)
static

Definition at line 1673 of file d3drm.c.

1676 {
1677  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1678  struct d3drm_device *object;
1679  IDirectDraw *ddraw;
1680  IDirectDrawSurface *render_target;
1681  HRESULT hr;
1682 
1683  TRACE("iface %p, clipper %p, guid %s, width %d, height %d, device %p.\n",
1685 
1686  if (!device)
1687  return D3DRMERR_BADVALUE;
1688  *device = NULL;
1689 
1690  if (!clipper || !width || !height)
1691  return D3DRMERR_BADVALUE;
1692 
1694  if (FAILED(hr))
1695  return hr;
1696 
1698  {
1699  IDirectDraw_Release(ddraw);
1700  return hr;
1701  }
1702 
1704  if (FAILED(hr))
1705  {
1706  IDirectDraw_Release(ddraw);
1707  d3drm_device_destroy(object);
1708  return hr;
1709  }
1710 
1711  hr = d3drm_device_init(object, 3, ddraw, render_target, TRUE);
1712  IDirectDraw_Release(ddraw);
1713  IDirectDrawSurface_Release(render_target);
1714  if (FAILED(hr))
1715  d3drm_device_destroy(object);
1716  else
1717  *device = &object->IDirect3DRMDevice3_iface;
1718 
1719  return hr;
1720 }
GLint GLint GLsizei width
Definition: gl.h:1546
HRESULT hr
Definition: shlfolder.c:183
#define TRUE
Definition: types.h:120
HRESULT d3drm_device_create(struct d3drm_device **device, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: device.c:1634
HRESULT WINAPI DirectDrawCreate(LPGUID lpGUID, LPDIRECTDRAW *lplpDD, LPUNKNOWN pUnkOuter)
Definition: main.c:86
const GUID * guid
HRESULT d3drm_device_create_surfaces_from_clipper(struct d3drm_device *object, IDirectDraw *ddraw, IDirectDrawClipper *clipper, int width, int height, IDirectDrawSurface **surface) DECLSPEC_HIDDEN
Definition: device.c:69
Definition: devices.h:37
void d3drm_device_destroy(struct d3drm_device *device) DECLSPEC_HIDDEN
Definition: device.c:40
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
HRESULT d3drm_device_init(struct d3drm_device *device, UINT version, IDirectDraw *ddraw, IDirectDrawSurface *surface, BOOL create_z_surface) DECLSPEC_HIDDEN
Definition: device.c:120
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
IDirectDrawClipper * clipper
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
Definition: d3drm.c:188
IDirectDrawSurface * render_target
IDirectDraw * ddraw
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateDeviceFromD3D()

static HRESULT WINAPI d3drm3_CreateDeviceFromD3D ( IDirect3DRM3 *  iface,
IDirect3D2 *  d3d,
IDirect3DDevice2 *  d3d_device,
IDirect3DRMDevice3 **  device 
)
static

Definition at line 1646 of file d3drm.c.

1648 {
1649  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1650  struct d3drm_device *object;
1651  HRESULT hr;
1652 
1653  TRACE("iface %p, d3d %p, d3d_device %p, device %p.\n",
1654  iface, d3d, d3d_device, device);
1655 
1656  if (!device)
1657  return D3DRMERR_BADVALUE;
1658  *device = NULL;
1659 
1661  return hr;
1662 
1663  if (FAILED(hr = IDirect3DRMDevice3_InitFromD3D2(&object->IDirect3DRMDevice3_iface, d3d, d3d_device)))
1664  {
1665  d3drm_device_destroy(object);
1666  return hr;
1667  }
1668  *device = &object->IDirect3DRMDevice3_iface;
1669 
1670  return D3DRM_OK;
1671 }
HRESULT hr
Definition: shlfolder.c:183
HRESULT d3drm_device_create(struct d3drm_device **device, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: device.c:1634
Definition: devices.h:37
void d3drm_device_destroy(struct d3drm_device *device) DECLSPEC_HIDDEN
Definition: device.c:40
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define IDirect3DRMDevice3_InitFromD3D2(p, a, b)
Definition: d3drmobj.h:728
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateDeviceFromSurface()

static HRESULT WINAPI d3drm3_CreateDeviceFromSurface ( IDirect3DRM3 *  iface,
GUID guid,
IDirectDraw *  ddraw,
IDirectDrawSurface *  backbuffer,
DWORD  flags,
IDirect3DRMDevice3 **  device 
)
static

Definition at line 1615 of file d3drm.c.

1617 {
1618  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1619  struct d3drm_device *object;
1620  BOOL use_z_surface;
1621  HRESULT hr;
1622 
1623  TRACE("iface %p, guid %s, ddraw %p, backbuffer %p, flags %#x, device %p.\n",
1624  iface, debugstr_guid(guid), ddraw, backbuffer, flags, device);
1625 
1626  if (!device)
1627  return D3DRMERR_BADVALUE;
1628  *device = NULL;
1629 
1630  if (!backbuffer || !ddraw)
1631  return D3DRMERR_BADDEVICE;
1632 
1634  return hr;
1635 
1636  use_z_surface = !(flags & D3DRMDEVICE_NOZBUFFER);
1637 
1638  if (SUCCEEDED(hr = d3drm_device_init(object, 3, ddraw, backbuffer, use_z_surface)))
1639  *device = &object->IDirect3DRMDevice3_iface;
1640  else
1641  d3drm_device_destroy(object);
1642 
1643  return hr;
1644 }
HRESULT hr
Definition: shlfolder.c:183
HRESULT d3drm_device_create(struct d3drm_device **device, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: device.c:1634
const GUID * guid
unsigned int BOOL
Definition: ntddk_ex.h:94
Definition: devices.h:37
void d3drm_device_destroy(struct d3drm_device *device) DECLSPEC_HIDDEN
Definition: device.c:40
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
HRESULT d3drm_device_init(struct d3drm_device *device, UINT version, IDirectDraw *ddraw, IDirectDrawSurface *surface, BOOL create_z_surface) DECLSPEC_HIDDEN
Definition: device.c:120
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
GLbitfield flags
Definition: glext.h:7161
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define D3DRMERR_BADDEVICE
Definition: d3drm.h:495
#define D3DRMDEVICE_NOZBUFFER
Definition: d3drmdef.h:271
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206
#define SUCCEEDED(hr)
Definition: intsafe.h:49

◆ d3drm3_CreateFace()

static HRESULT WINAPI d3drm3_CreateFace ( IDirect3DRM3 *  iface,
IDirect3DRMFace2 **  face 
)
static

Definition at line 1478 of file d3drm.c.

1479 {
1480  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1481  IDirect3DRMFace *face1;
1482  HRESULT hr;
1483 
1484  TRACE("iface %p, face %p.\n", iface, face);
1485 
1487  return hr;
1488 
1489  hr = IDirect3DRMFace_QueryInterface(face1, &IID_IDirect3DRMFace2, (void **)face);
1490  IDirect3DRMFace_Release(face1);
1491 
1492  return hr;
1493 }
#define IDirect3DRMFace_Release(p)
Definition: d3drmobj.h:2310
HRESULT hr
Definition: shlfolder.c:183
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
Definition: d3drm.c:188
#define IDirect3DRM_CreateFace(p, a)
Definition: d3drm.h:117
#define IDirect3DRMFace_QueryInterface(p, a, b)
Definition: d3drmobj.h:2308
GLenum GLuint GLint GLenum face
Definition: glext.h:7025
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateFrame()

static HRESULT WINAPI d3drm3_CreateFrame ( IDirect3DRM3 *  iface,
IDirect3DRMFrame3 *  parent,
IDirect3DRMFrame3 **  frame 
)
static

Definition at line 1429 of file d3drm.c.

1431 {
1432  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1433  struct d3drm_frame *object;
1434  HRESULT hr;
1435 
1436  TRACE("iface %p, parent %p, frame %p.\n", iface, parent, frame);
1437 
1439  return hr;
1440 
1441  *frame = &object->IDirect3DRMFrame3_iface;
1442 
1443  return D3DRM_OK;
1444 }
HRESULT hr
Definition: shlfolder.c:183
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
r parent
Definition: btrfs.c:2944
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
Definition: d3drm.c:188
HRESULT d3drm_frame_create(struct d3drm_frame **frame, IUnknown *parent_frame, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: frame.c:3129
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateLight()

static HRESULT WINAPI d3drm3_CreateLight ( IDirect3DRM3 *  iface,
D3DRMLIGHTTYPE  type,
D3DCOLOR  color,
IDirect3DRMLight **  light 
)
static

Definition at line 1545 of file d3drm.c.

1547 {
1548  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1549  struct d3drm_light *object;
1550  HRESULT hr;
1551 
1552  FIXME("iface %p, type %#x, color 0x%08x, light %p partial stub!\n", iface, type, color, light);
1553 
1555  {
1556  IDirect3DRMLight_SetType(&object->IDirect3DRMLight_iface, type);
1557  IDirect3DRMLight_SetColor(&object->IDirect3DRMLight_iface, color);
1558  }
1559 
1560  *light = &object->IDirect3DRMLight_iface;
1561 
1562  return hr;
1563 }
#define IDirect3DRMLight_SetColor(p, a)
Definition: d3drmobj.h:3132
HRESULT hr
Definition: shlfolder.c:183
HRESULT d3drm_light_create(struct d3drm_light **light, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: light.c:371
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
GLuint color
Definition: glext.h:6243
#define FIXME(fmt,...)
Definition: debug.h:111
#define IDirect3DRMLight_SetType(p, a)
Definition: d3drmobj.h:3131
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
Definition: d3drm.c:188
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206
#define SUCCEEDED(hr)
Definition: intsafe.h:49

◆ d3drm3_CreateLightRGB()

static HRESULT WINAPI d3drm3_CreateLightRGB ( IDirect3DRM3 *  iface,
D3DRMLIGHTTYPE  type,
D3DVALUE  red,
D3DVALUE  green,
D3DVALUE  blue,
IDirect3DRMLight **  light 
)
static

Definition at line 1565 of file d3drm.c.

1567 {
1568  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1569  struct d3drm_light *object;
1570  HRESULT hr;
1571 
1572  FIXME("iface %p, type %#x, red %.8e, green %.8e, blue %.8e, light %p partial stub!\n",
1573  iface, type, red, green, blue, light);
1574 
1576  {
1577  IDirect3DRMLight_SetType(&object->IDirect3DRMLight_iface, type);
1578  IDirect3DRMLight_SetColorRGB(&object->IDirect3DRMLight_iface, red, green, blue);
1579  }
1580 
1581  *light = &object->IDirect3DRMLight_iface;
1582 
1583  return hr;
1584 }
HRESULT hr
Definition: shlfolder.c:183
HRESULT d3drm_light_create(struct d3drm_light **light, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: light.c:371
#define IDirect3DRMLight_SetColorRGB(p, a, b, c)
Definition: d3drmobj.h:3133
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
#define FIXME(fmt,...)
Definition: debug.h:111
GLclampf GLclampf blue
Definition: gl.h:1740
#define IDirect3DRMLight_SetType(p, a)
Definition: d3drmobj.h:3131
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
GLclampf green
Definition: gl.h:1740
#define red
Definition: linetest.c:67
Definition: d3drm.c:188
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206
#define SUCCEEDED(hr)
Definition: intsafe.h:49

◆ d3drm3_CreateMaterial()

static HRESULT WINAPI d3drm3_CreateMaterial ( IDirect3DRM3 *  iface,
D3DVALUE  power,
IDirect3DRMMaterial2 **  material 
)
static

Definition at line 1586 of file d3drm.c.

1588 {
1589  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1590  struct d3drm_material *object;
1591  HRESULT hr;
1592 
1593  TRACE("iface %p, power %.8e, material %p.\n", iface, power, material);
1594 
1596  IDirect3DRMMaterial2_SetPower(&object->IDirect3DRMMaterial2_iface, power);
1597 
1598  *material = &object->IDirect3DRMMaterial2_iface;
1599 
1600  return hr;
1601 }
HRESULT hr
Definition: shlfolder.c:183
HRESULT d3drm_material_create(struct d3drm_material **material, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: material.c:279
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
Definition: d3drm.c:188
float power
Definition: d3drm.c:3372
#define IDirect3DRMMaterial2_SetPower(p, a)
Definition: d3drmobj.h:3743
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206
#define SUCCEEDED(hr)
Definition: intsafe.h:49

◆ d3drm3_CreateMesh()

static HRESULT WINAPI d3drm3_CreateMesh ( IDirect3DRM3 *  iface,
IDirect3DRMMesh **  mesh 
)
static

Definition at line 1446 of file d3drm.c.

1447 {
1448  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1449  struct d3drm_mesh *object;
1450  HRESULT hr;
1451 
1452  TRACE("iface %p, mesh %p.\n", iface, mesh);
1453 
1454  if (FAILED(hr = d3drm_mesh_create(&object, &d3drm->IDirect3DRM_iface)))
1455  return hr;
1456 
1457  *mesh = &object->IDirect3DRMMesh_iface;
1458 
1459  return S_OK;
1460 }
HRESULT hr
Definition: shlfolder.c:183
Definition: mesh.c:197
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
HRESULT d3drm_mesh_create(struct d3drm_mesh **mesh, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: meshbuilder.c:2833
Definition: d3drm.c:188
#define S_OK
Definition: intsafe.h:51
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateMeshBuilder()

static HRESULT WINAPI d3drm3_CreateMeshBuilder ( IDirect3DRM3 *  iface,
IDirect3DRMMeshBuilder3 **  mesh_builder 
)
static

Definition at line 1462 of file d3drm.c.

1463 {
1464  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1465  struct d3drm_mesh_builder *object;
1466  HRESULT hr;
1467 
1468  TRACE("iface %p, mesh_builder %p.\n", iface, mesh_builder);
1469 
1471  return hr;
1472 
1473  *mesh_builder = &object->IDirect3DRMMeshBuilder3_iface;
1474 
1475  return S_OK;
1476 }
HRESULT hr
Definition: shlfolder.c:183
HRESULT d3drm_mesh_builder_create(struct d3drm_mesh_builder **mesh_builder, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: meshbuilder.c:2334
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
IDirect3DRMMeshBuilder * mesh_builder
Definition: d3drm.c:3330
Definition: d3drm.c:188
#define S_OK
Definition: intsafe.h:51
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateObject()

static HRESULT WINAPI d3drm3_CreateObject ( IDirect3DRM3 *  iface,
REFCLSID  clsid,
IUnknown outer,
REFIID  iid,
void **  out 
)
static

Definition at line 1356 of file d3drm.c.

1358 {
1359  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1360  IUnknown *object;
1361  unsigned int i;
1362  HRESULT hr;
1363 
1364  static const struct
1365  {
1366  const CLSID *clsid;
1367  HRESULT (*create_object)(void **object, IDirect3DRM *d3drm);
1368  }
1369  object_table[] =
1370  {
1371  {&CLSID_CDirect3DRMTexture, d3drm_create_texture_object},
1372  {&CLSID_CDirect3DRMDevice, d3drm_create_device_object},
1373  {&CLSID_CDirect3DRMViewport, d3drm_create_viewport_object},
1374  {&CLSID_CDirect3DRMFace, d3drm_create_face_object},
1375  {&CLSID_CDirect3DRMMeshBuilder, d3drm_create_mesh_builder_object},
1376  {&CLSID_CDirect3DRMFrame, d3drm_create_frame_object},
1377  {&CLSID_CDirect3DRMLight, d3drm_create_light_object},
1378  {&CLSID_CDirect3DRMMaterial, d3drm_create_material_object},
1379  {&CLSID_CDirect3DRMMesh, d3drm_create_mesh_object},
1380  {&CLSID_CDirect3DRMAnimation, d3drm_create_animation_object},
1381  {&CLSID_CDirect3DRMWrap, d3drm_create_wrap_object},
1382  };
1383 
1384  TRACE("iface %p, clsid %s, outer %p, iid %s, out %p.\n",
1385  iface, debugstr_guid(clsid), outer, debugstr_guid(iid), out);
1386 
1387  if (!out)
1388  return D3DRMERR_BADVALUE;
1389 
1390  if (!clsid || !iid)
1391  {
1392  *out = NULL;
1393  return D3DRMERR_BADVALUE;
1394  }
1395 
1396  if (outer)
1397  {
1398  FIXME("COM aggregation for outer IUnknown (%p) not implemented. Returning E_NOTIMPL.\n", outer);
1399  *out = NULL;
1400  return E_NOTIMPL;
1401  }
1402 
1403  for (i = 0; i < ARRAY_SIZE(object_table); ++i)
1404  {
1405  if (IsEqualGUID(clsid, object_table[i].clsid))
1406  {
1407  if (FAILED(hr = object_table[i].create_object((void **)&object, &d3drm->IDirect3DRM_iface)))
1408  {
1409  *out = NULL;
1410  return hr;
1411  }
1412  break;
1413  }
1414  }
1415  if (i == ARRAY_SIZE(object_table))
1416  {
1417  FIXME("%s not implemented. Returning CLASSFACTORY_E_FIRST.\n", debugstr_guid(clsid));
1418  *out = NULL;
1419  return CLASSFACTORY_E_FIRST;
1420  }
1421 
1422  if (FAILED(hr = IUnknown_QueryInterface(object, iid, out)))
1423  *out = NULL;
1424  IUnknown_Release(object);
1425 
1426  return hr;
1427 }
#define HRESULT
Definition: msvc.h:7
static HRESULT d3drm_create_light_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:123
#define CLASSFACTORY_E_FIRST
Definition: winerror.h:2661
HRESULT hr
Definition: shlfolder.c:183
static HRESULT d3drm_create_frame_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:110
static HRESULT d3drm_create_mesh_builder_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:97
static HRESULT d3drm_create_material_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:136
static HRESULT d3drm_create_wrap_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:175
static HRESULT d3drm_create_texture_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:45
static HRESULT d3drm_create_face_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:84
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define FIXME(fmt,...)
Definition: debug.h:111
smooth NULL
Definition: ftsmooth.c:416
static HRESULT d3drm_create_viewport_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:71
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
static FILE * out
Definition: regtests2xml.c:44
static HRESULT d3drm_create_device_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:58
REFCLSID clsid
Definition: msctf.c:82
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
static HRESULT d3drm_create_mesh_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:149
#define ARRAY_SIZE(a)
Definition: main.h:24
#define E_NOTIMPL
Definition: ddrawi.h:99
static HRESULT d3drm_create_animation_object(void **object, IDirect3DRM *d3drm)
Definition: d3drm.c:162
BOOL WINAPI IsEqualGUID(REFGUID rguid1, REFGUID rguid2)
Definition: compobj.c:4112
HRESULT create_object(script_ctx_t *, jsdisp_t *, jsdisp_t **) DECLSPEC_HIDDEN
Definition: object.c:731
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateProgressiveMesh()

static HRESULT WINAPI d3drm3_CreateProgressiveMesh ( IDirect3DRM3 *  iface,
IDirect3DRMProgressiveMesh **  mesh 
)
static

Definition at line 2234 of file d3drm.c.

2235 {
2236  FIXME("iface %p, mesh %p stub!\n", iface, mesh);
2237 
2238  return E_NOTIMPL;
2239 }
Definition: mesh.c:197
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm3_CreateShadow()

static HRESULT WINAPI d3drm3_CreateShadow ( IDirect3DRM3 *  iface,
IUnknown object,
IDirect3DRMLight *  light,
D3DVALUE  px,
D3DVALUE  py,
D3DVALUE  pz,
D3DVALUE  nx,
D3DVALUE  ny,
D3DVALUE  nz,
IDirect3DRMShadow2 **  shadow 
)
static

Definition at line 1722 of file d3drm.c.

1724 {
1725  FIXME("iface %p, object %p, light %p, px %.8e, py %.8e, pz %.8e, nx %.8e, ny %.8e, nz %.8e, shadow %p stub!\n",
1726  iface, object, light, px, py, pz, nx, ny, nz, shadow);
1727 
1728  return E_NOTIMPL;
1729 }
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
GLfloat GLfloat nz
Definition: glext.h:8896
#define FIXME(fmt,...)
Definition: debug.h:111
GLfloat GLfloat GLfloat GLfloat nx
Definition: glext.h:8898
#define E_NOTIMPL
Definition: ddrawi.h:99
GLfloat ny
Definition: glext.h:8896

◆ d3drm3_CreateTexture()

static HRESULT WINAPI d3drm3_CreateTexture ( IDirect3DRM3 *  iface,
D3DRMIMAGE image,
IDirect3DRMTexture3 **  texture 
)
static

Definition at line 1518 of file d3drm.c.

1520 {
1521  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1522  struct d3drm_texture *object;
1523  HRESULT hr;
1524 
1525  TRACE("iface %p, image %p, texture %p.\n", iface, image, texture);
1526 
1527  if (!texture)
1528  return D3DRMERR_BADVALUE;
1529 
1531  return hr;
1532 
1533  *texture = &object->IDirect3DRMTexture3_iface;
1534 
1536  {
1538  *texture = NULL;
1539  return D3DRMERR_BADVALUE;
1540  }
1541 
1542  return D3DRM_OK;
1543 }
#define IDirect3DRMTexture3_InitFromImage(p, a)
Definition: d3drmobj.h:3506
HRESULT hr
Definition: shlfolder.c:183
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
HRESULT d3drm_texture_create(struct d3drm_texture **texture, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: texture.c:1412
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define IDirect3DRMTexture3_Release(p)
Definition: d3drmobj.h:3476
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateTextureFromSurface()

static HRESULT WINAPI d3drm3_CreateTextureFromSurface ( IDirect3DRM3 *  iface,
IDirectDrawSurface *  surface,
IDirect3DRMTexture3 **  texture 
)
static

Definition at line 1731 of file d3drm.c.

1733 {
1734  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1735  struct d3drm_texture *object;
1736  HRESULT hr;
1737 
1738  TRACE("iface %p, surface %p, texture %p.\n", iface, surface, texture);
1739 
1740  if (!texture)
1741  return D3DRMERR_BADVALUE;
1742 
1744  return hr;
1745 
1746  *texture = &object->IDirect3DRMTexture3_iface;
1747 
1749  {
1751  *texture = NULL;
1752  return D3DRMERR_BADVALUE;
1753  }
1754 
1755  return D3DRM_OK;
1756 }
HRESULT hr
Definition: shlfolder.c:183
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
GLenum GLuint texture
Definition: glext.h:6295
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
HRESULT d3drm_texture_create(struct d3drm_texture **texture, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: texture.c:1412
IDirectDrawSurface * surface
Definition: d3drm_private.h:66
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
#define IDirect3DRMTexture3_InitFromSurface(p, a)
Definition: d3drmobj.h:3488
Definition: d3drm.c:188
#define IDirect3DRMTexture3_Release(p)
Definition: d3drmobj.h:3476
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateUserVisual()

static HRESULT WINAPI d3drm3_CreateUserVisual ( IDirect3DRM3 *  iface,
D3DRMUSERVISUALCALLBACK  cb,
void ctx,
IDirect3DRMUserVisual **  visual 
)
static

Definition at line 1814 of file d3drm.c.

1816 {
1817  FIXME("iface %p, cb %p, ctx %p, visual %p stub!\n", iface, cb, ctx, visual);
1818 
1819  return E_NOTIMPL;
1820 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32

◆ d3drm3_CreateViewport()

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

Definition at line 1758 of file d3drm.c.

1760 {
1761  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1762  struct d3drm_viewport *object;
1763  HRESULT hr;
1764 
1765  TRACE("iface %p, device %p, camera %p, x %u, y %u, width %u, height %u, viewport %p.\n",
1766  iface, device, camera, x, y, width, height, viewport);
1767 
1768  if (!viewport)
1769  return D3DRMERR_BADVALUE;
1770  *viewport = NULL;
1771 
1772  if (!device || !camera)
1773  return D3DRMERR_BADOBJECT;
1774 
1776  return hr;
1777 
1778  *viewport = &object->IDirect3DRMViewport2_iface;
1779 
1780  if (FAILED(hr = IDirect3DRMViewport2_Init(*viewport, device, camera, x, y, width, height)))
1781  {
1782  IDirect3DRMViewport2_Release(*viewport);
1783  *viewport = NULL;
1784  return D3DRMERR_BADVALUE;
1785  }
1786 
1787  return D3DRM_OK;
1788 }
GLint GLint GLsizei width
Definition: gl.h:1546
#define IDirect3DRMViewport2_Release(p)
Definition: d3drmobj.h:991
HRESULT hr
Definition: shlfolder.c:183
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
#define D3DRMERR_BADOBJECT
Definition: d3drm.h:487
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define IDirect3DRMViewport2_Init(p, a, b, c, d, e, f)
Definition: d3drmobj.h:1002
#define TRACE(s)
Definition: solgame.cpp:4
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
Definition: d3drm.c:188
IDirect3DRMFrame * camera
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
HRESULT d3drm_viewport_create(struct d3drm_viewport **viewport, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: viewport.c:1123
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_CreateWrap()

static HRESULT WINAPI d3drm3_CreateWrap ( IDirect3DRM3 *  iface,
D3DRMWRAPTYPE  type,
IDirect3DRMFrame3 *  frame,
D3DVALUE  ox,
D3DVALUE  oy,
D3DVALUE  oz,
D3DVALUE  dx,
D3DVALUE  dy,
D3DVALUE  dz,
D3DVALUE  ux,
D3DVALUE  uy,
D3DVALUE  uz,
D3DVALUE  ou,
D3DVALUE  ov,
D3DVALUE  su,
D3DVALUE  sv,
IDirect3DRMWrap **  wrap 
)
static

Definition at line 1790 of file d3drm.c.

1794 {
1795  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1796  struct d3drm_wrap *object;
1797  HRESULT hr;
1798 
1799  FIXME("iface %p, type %#x, frame %p, ox %.8e, oy %.8e, oz %.8e, dx %.8e, dy %.8e, dz %.8e, "
1800  "ux %.8e, uy %.8e, uz %.8e, ou %.8e, ov %.8e, su %.8e, sv %.8e, wrap %p, semi-stub.\n",
1801  iface, type, frame, ox, oy, oz, dx, dy, dz, ux, uy, uz, ou, ov, su, sv, wrap);
1802 
1803  if (!wrap)
1804  return D3DRMERR_BADVALUE;
1805 
1806  if (FAILED(hr = d3drm_wrap_create(&object, &d3drm->IDirect3DRM_iface)))
1807  return hr;
1808 
1809  *wrap = &object->IDirect3DRMWrap_iface;
1810 
1811  return S_OK;
1812 }
HRESULT hr
Definition: shlfolder.c:183
GLint dy
Definition: linetemp.h:97
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
#define FIXME(fmt,...)
Definition: debug.h:111
IDirect3DRM IDirect3DRM_iface
Definition: d3drm.c:190
LONG HRESULT
Definition: typedefs.h:79
#define D3DRMERR_BADVALUE
Definition: d3drm.h:496
Definition: d3drm.c:188
#define S_OK
Definition: intsafe.h:51
HRESULT d3drm_wrap_create(struct d3drm_wrap **wrap, IDirect3DRM *d3drm) DECLSPEC_HIDDEN
Definition: meshbuilder.c:3019
GLint dx
Definition: linetemp.h:97
#define wrap(journal, var)
Definition: recovery.c:207
void * object
Definition: jmemsys.h:48
static struct d3drm * impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
Definition: d3drm.c:206

◆ d3drm3_EnumerateObjects()

static HRESULT WINAPI d3drm3_EnumerateObjects ( IDirect3DRM3 *  iface,
D3DRMOBJECTCALLBACK  cb,
void ctx 
)
static

Definition at line 1916 of file d3drm.c.

1917 {
1918  FIXME("iface %p, cb %p, ctx %p stub!\n", iface, cb, ctx);
1919 
1920  return E_NOTIMPL;
1921 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32

◆ d3drm3_GetDevices()

static HRESULT WINAPI d3drm3_GetDevices ( IDirect3DRM3 *  iface,
IDirect3DRMDeviceArray **  array 
)
static

Definition at line 1901 of file d3drm.c.

1902 {
1903  FIXME("iface %p, array %p stub!\n", iface, array);
1904 
1905  return E_NOTIMPL;
1906 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm3_GetNamedObject()

static HRESULT WINAPI d3drm3_GetNamedObject ( IDirect3DRM3 *  iface,
const char name,
IDirect3DRMObject **  object 
)
static

Definition at line 1908 of file d3drm.c.

1910 {
1911  FIXME("iface %p, name %s, object %p stub!\n", iface, debugstr_a(name), object);
1912 
1913  return E_NOTIMPL;
1914 }
#define FIXME(fmt,...)
Definition: debug.h:111
#define debugstr_a
Definition: kernel32.h:31
#define E_NOTIMPL
Definition: ddrawi.h:99
Definition: name.c:38

◆ d3drm3_GetOptions()

static HRESULT WINAPI d3drm3_GetOptions ( IDirect3DRM3 *  iface,
DWORD flags 
)
static

Definition at line 2270 of file d3drm.c.

2271 {
2272  FIXME("iface %p, flags %p stub!\n", iface, flags);
2273 
2274  return E_NOTIMPL;
2275 }
#define FIXME(fmt,...)
Definition: debug.h:111
GLbitfield flags
Definition: glext.h:7161
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm3_GetSearchPath()

static HRESULT WINAPI d3drm3_GetSearchPath ( IDirect3DRM3 *  iface,
DWORD size,
char path 
)
static

Definition at line 1880 of file d3drm.c.

1881 {
1882  FIXME("iface %p, size %p, path %p stub!\n", iface, size, path);
1883 
1884  return E_NOTIMPL;
1885 }
#define FIXME(fmt,...)
Definition: debug.h:111
GLsizeiptr size
Definition: glext.h:5919
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3drm3_Load()

static HRESULT WINAPI d3drm3_Load ( IDirect3DRM3 *  iface,
void source,
void object_id,
IID **  iids,
DWORD  iid_count,
D3DRMLOADOPTIONS  flags,
D3DRMLOADCALLBACK  load_cb,
void load_ctx,
D3DRMLOADTEXTURECALLBACK  load_tex_cb,
void load_tex_ctx,
IDirect3DRMFrame3 *  parent_frame 
)
static

Definition at line 2109 of file d3drm.c.

2112 {
2113  DXFILELOADOPTIONS load_options;
2114  IDirectXFile *file = NULL;
2115  IDirectXFileEnumObject *enum_object = NULL;
2116  IDirectXFileData *data = NULL;
2117  HRESULT hr;
2118  const GUID* pGuid;
2119  DWORD size;
2120  struct d3drm_file_header *header;
2122  DWORD i;
2123 
2124  TRACE("iface %p, source %p, object_id %p, iids %p, iid_count %u, flags %#x, "
2125  "load_cb %p, load_ctx %p, load_tex_cb %p, load_tex_ctx %p, parent_frame %p.\n",
2126  iface, source, object_id, iids, iid_count, flags,
2127  load_cb, load_ctx, load_tex_cb, load_tex_ctx, parent_frame);
2128 
2129  TRACE("Looking for GUIDs:\n");
2130  for (i = 0; i < iid_count; ++i)
2131  TRACE("- %s (%s)\n", debugstr_guid(iids[i]), get_IID_string(iids[i]));
2132 
2133  if (flags == D3DRMLOAD_FROMMEMORY)
2134  {
2135  load_options = DXFILELOAD_FROMMEMORY;
2136  }
2137  else if (flags == D3DRMLOAD_FROMFILE)
2138  {
2139  load_options = DXFILELOAD_FROMFILE;
2140  TRACE("Loading from file %s\n", debugstr_a(source));
2141  }
2142  else
2143  {
2144  FIXME("Load options %#x not supported yet.\n", flags);
2145  return E_NOTIMPL;
2146  }
2147 
2149  if (hr != DXFILE_OK)
2150  goto end;
2151 
2153  if (hr != DXFILE_OK)
2154  goto end;
2155 
2156  hr = IDirectXFile_CreateEnumObject(file, source, load_options, &enum_object);
2157  if (hr != DXFILE_OK)
2158  goto end;
2159 
2161  if (hr != DXFILE_OK)
2162  goto end;
2163 
2164  hr = IDirectXFileData_GetType(data, &pGuid);
2165  if (hr != DXFILE_OK)
2166  goto end;
2167 
2168  TRACE("Found object type whose GUID = %s\n", debugstr_guid(pGuid));
2169 
2170  if (!IsEqualGUID(pGuid, &TID_DXFILEHeader))
2171  {
2173  goto end;
2174  }
2175 
2176  hr = IDirectXFileData_GetData(data, NULL, &size, (void **)&header);
2177  if ((hr != DXFILE_OK) || (size != sizeof(*header)))
2178  goto end;
2179 
2180  TRACE("Version is %u.%u, flags %#x.\n", header->major, header->minor, header->flags);
2181 
2182  /* Version must be 1.0.x */
2183  if ((header->major != 1) || (header->minor != 0))
2184  {
2186  goto end;
2187  }
2188 
2190  data = NULL;
2191 
2192  while (1)
2193  {
2195  if (hr == DXFILEERR_NOMOREOBJECTS)
2196  {
2197  TRACE("No more object\n");
2198  break;
2199  }
2200  else if (hr != DXFILE_OK)
2201  {
2203  goto end;
2204  }
2205 
2206  ret = load_data(iface, data, iids, iid_count, load_cb, load_ctx, load_tex_cb, load_tex_ctx, parent_frame);
2207  if (ret != D3DRM_OK)
2208  goto end;
2209 
2211  data = NULL;
2212  }
2213 
2214  ret = D3DRM_OK;
2215 
2216 end:
2217  if (data)
2219  if (enum_object)
2220  IDirectXFileEnumObject_Release(enum_object);
2221  if (file)
2223 
2224  return ret;
2225 }
HRESULT hr
Definition: shlfolder.c:183
#define IDirectXFileEnumObject_Release(p)
Definition: dxfile.h:107
ACPI_SIZE strlen(const char *String)
Definition: utclib.c:269
#define IDirectXFileData_Release(p)
Definition: dxfile.h:185
#define D3DRMLOAD_FROMMEMORY
Definition: d3drmdef.h:343
#define IDirectXFile_Release(p)
Definition: dxfile.h:82
GLuint GLuint end
Definition: gl.h:1545
#define DXFILEERR_NOMOREOBJECTS
Definition: dxfile.h:291
#define DXFILELOAD_FROMFILE
Definition: dxfile.h:37
#define DXFILE_OK
Definition: dxfile.h:268
#define IDirectXFile_RegisterTemplates(p, a, b)
Definition: dxfile.h:86
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define D3DRMERR_BADOBJECT
Definition: d3drm.h:487
static HRESULT load_data(IDirect3DRM3 *iface, IDirectXFileData *data_object, IID **GUIDs, DWORD nb_GUIDs, D3DRMLOADCALLBACK LoadProc, void *ArgLP, D3DRMLOADTEXTURECALLBACK LoadTextureProc, void *ArgLTP, IDirect3DRMFrame3 *parent_frame)
Definition: d3drm.c:1923
#define FIXME(fmt,...)
Definition: debug.h:111
#define IDirectXFileEnumObject_GetNextDataObject(p, a)
Definition: dxfile.h:109
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
#define debugstr_a
Definition: kernel32.h:31
LONG HRESULT
Definition: typedefs.h:79
#define D3DRM_OK
Definition: d3drm.h:486
unsigned long DWORD
Definition: ntddk_ex.h:95
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
GLbitfield flags
Definition: glext.h:7161
static const char * get_IID_string(const GUID *guid)
Definition: d3drm.c:27
#define IDirectXFile_CreateEnumObject(p, a, b, c)
Definition: dxfile.h:84
DWORD DXFILELOADOPTIONS
Definition: dxfile.h:35
int ret
#define IDirectXFileData_GetData(p, a, b, c)
Definition: dxfile.h:190
#define IDirectXFileData_GetType(p, a)
Definition: dxfile.h:191
#define E_NOTIMPL
Definition: ddrawi.h:99
BOOL WINAPI IsEqualGUID(REFGUID rguid1, REFGUID rguid2)
Definition: compobj.c:4112
HRESULT WINAPI DirectXFileCreate(LPDIRECTXFILE *lplpDirectXFile)
Definition: main.c:153
#define D3DRMERR_BADFILE
Definition: d3drm.h:494
char templates[]
Definition: meshbuilder.c:39
struct CFHEADER header
Definition: fdi.c:101
#define D3DRMLOAD_FROMFILE
Definition: d3drmdef.h:341
Definition: fci.c:126
#define DXFILELOAD_FROMMEMORY
Definition: dxfile.h:39

◆ d3drm3_LoadTexture()

static HRESULT WINAPI d3drm3_LoadTexture ( IDirect3DRM3 *  iface,
const char filename,
IDirect3DRMTexture3 **  texture 
)
static

Definition at line 1822 of file d3drm.c.

1824 {
1825  struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
1826  struct d3drm_texture *object;
1827  HRESULT hr;
1828 
1829