ReactOS 0.4.17-dev-966-gf06eace
surface.c
Go to the documentation of this file.
1/*
2 * IDirect3DSurface9 implementation
3 *
4 * Copyright 2002-2005 Jason Edmeades
5 * Raphael Junqueira
6 *
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Lesser General Public
9 * License as published by the Free Software Foundation; either
10 * version 2.1 of the License, or (at your option) any later version.
11 *
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Lesser General Public License for more details.
16 *
17 * You should have received a copy of the GNU Lesser General Public
18 * License along with this library; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
20 */
21
22#include "d3d9_private.h"
23
25
27{
29}
30
32{
33 TRACE("iface %p, riid %s, out %p.\n", iface, debugstr_guid(riid), out);
34
35 if (IsEqualGUID(riid, &IID_IDirect3DSurface9)
36 || IsEqualGUID(riid, &IID_IDirect3DResource9)
38 {
40 *out = iface;
41 return S_OK;
42 }
43
44 WARN("%s not implemented, returning E_NOINTERFACE.\n", debugstr_guid(riid));
45
46 *out = NULL;
47 return E_NOINTERFACE;
48}
49
51{
52 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
53 ULONG refcount;
54
55 TRACE("iface %p.\n", iface);
56
57 if (surface->texture)
58 {
59 TRACE("Forwarding to %p.\n", surface->texture);
60 return IDirect3DBaseTexture9_AddRef(&surface->texture->IDirect3DBaseTexture9_iface);
61 }
62
63 refcount = InterlockedIncrement(&surface->resource.refcount);
64 TRACE("%p increasing refcount to %lu.\n", iface, refcount);
65
66 if (refcount == 1)
67 {
68 if (surface->parent_device)
70 if (surface->wined3d_rtv)
73 if (surface->swapchain)
75 }
76
77 return refcount;
78}
79
81{
82 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
83 ULONG refcount;
84
85 TRACE("iface %p.\n", iface);
86
87 if (surface->texture)
88 {
89 TRACE("Forwarding to %p.\n", surface->texture);
90 return IDirect3DBaseTexture9_Release(&surface->texture->IDirect3DBaseTexture9_iface);
91 }
92
93 if (!surface->resource.refcount)
94 {
95 WARN("Surface does not have any references.\n");
96 return 0;
97 }
98
99 refcount = InterlockedDecrement(&surface->resource.refcount);
100 TRACE("%p decreasing refcount to %lu.\n", iface, refcount);
101
102 if (!refcount)
103 {
105
106 if (surface->wined3d_rtv)
108 if (surface->swapchain)
110 /* Releasing the texture may free the d3d9 object, so do not access it
111 * after releasing the texture. */
113
114 /* Release the device last, as it may cause the device to be destroyed. */
115 if (parent_device)
117 }
118
119 return refcount;
120}
121
123{
124 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
125
126 TRACE("iface %p, device %p.\n", iface, device);
127
128 if (surface->texture)
129 return IDirect3DBaseTexture9_GetDevice(&surface->texture->IDirect3DBaseTexture9_iface, device);
130
133
134 TRACE("Returning device %p.\n", *device);
135
136 return D3D_OK;
137}
138
140 const void *data, DWORD data_size, DWORD flags)
141{
142 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
143 TRACE("iface %p, guid %s, data %p, data_size %lu, flags %#lx.\n",
144 iface, debugstr_guid(guid), data, data_size, flags);
145
146 return d3d9_resource_set_private_data(&surface->resource, guid, data, data_size, flags);
147}
148
150 void *data, DWORD *data_size)
151{
152 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
153 TRACE("iface %p, guid %s, data %p, data_size %p.\n",
154 iface, debugstr_guid(guid), data, data_size);
155
156 return d3d9_resource_get_private_data(&surface->resource, guid, data, data_size);
157}
158
160{
161 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
162 TRACE("iface %p, guid %s.\n", iface, debugstr_guid(guid));
163
165}
166
168{
169 TRACE("iface %p, priority %lu. Ignored on surfaces.\n", iface, priority);
170 return 0;
171}
172
174{
175 TRACE("iface %p. Ignored on surfaces.\n", iface);
176 return 0;
177}
178
180{
181 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
182
183 TRACE("iface %p.\n", iface);
184
188}
189
191{
192 TRACE("iface %p.\n", iface);
193
194 return D3DRTYPE_SURFACE;
195}
196
198{
199 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
200 HRESULT hr;
201
202 TRACE("iface %p, riid %s, container %p.\n", iface, debugstr_guid(riid), container);
203
204 if (!surface->container)
205 return E_NOINTERFACE;
206
207 hr = IUnknown_QueryInterface(surface->container, riid, container);
208
209 TRACE("Returning %p.\n", *container);
210
211 return hr;
212}
213
215{
216 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
217 struct wined3d_sub_resource_desc wined3d_desc;
218
219 TRACE("iface %p, desc %p.\n", iface, desc);
220
224
225 desc->Format = d3dformat_from_wined3dformat(wined3d_desc.format);
226 desc->Type = D3DRTYPE_SURFACE;
227 desc->Usage = d3dusage_from_wined3dusage(wined3d_desc.usage, wined3d_desc.bind_flags);
228 desc->Pool = d3dpool_from_wined3daccess(wined3d_desc.access, wined3d_desc.usage);
229 desc->MultiSampleType = d3dmultisample_type_from_wined3d(wined3d_desc.multisample_type);
230 desc->MultiSampleQuality = wined3d_desc.multisample_quality;
231 desc->Width = wined3d_desc.width;
232 desc->Height = wined3d_desc.height;
233
234 return D3D_OK;
235}
236
238 D3DLOCKED_RECT *locked_rect, const RECT *rect, DWORD flags)
239{
240 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
241 struct wined3d_box box;
242 struct wined3d_map_desc map_desc;
243 HRESULT hr;
244
245 TRACE("iface %p, locked_rect %p, rect %s, flags %#lx.\n",
246 iface, locked_rect, wine_dbgstr_rect(rect), flags);
247
248 if (rect)
250
252 &map_desc, rect ? &box : NULL, wined3dmapflags_from_d3dmapflags(flags, 0));
253
254 if (SUCCEEDED(hr))
255 {
256 locked_rect->Pitch = map_desc.row_pitch;
257 locked_rect->pBits = map_desc.data;
258 }
259
260 if (hr == E_INVALIDARG)
261 return D3DERR_INVALIDCALL;
262 return hr;
263}
264
266{
267 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
268 HRESULT hr;
269
270 TRACE("iface %p.\n", iface);
271
274 if (SUCCEEDED(hr) && surface->texture)
277
278 if (hr == WINEDDERR_NOTLOCKED)
279 {
281 if (surface->texture)
282 type = IDirect3DBaseTexture9_GetType(&surface->texture->IDirect3DBaseTexture9_iface);
283 else
286 }
287 return hr;
288}
289
291{
292 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
293 HRESULT hr;
294
295 TRACE("iface %p, dc %p.\n", iface, dc);
296
300
301 return hr;
302}
303
305{
306 struct d3d9_surface *surface = impl_from_IDirect3DSurface9(iface);
307 HRESULT hr;
308
309 TRACE("iface %p, dc %p.\n", iface, dc);
310
313 if (SUCCEEDED(hr) && surface->texture)
316
317 return hr;
318}
319
320static const struct IDirect3DSurface9Vtbl d3d9_surface_vtbl =
321{
322 /* IUnknown */
326 /* IDirect3DResource9 */
335 /* IDirect3DSurface9 */
342};
343
345{
346 struct d3d9_surface *surface = parent;
348 free(surface);
349}
350
352{
354};
355
357 unsigned int sub_resource_idx, IUnknown *container)
358{
359 IDirect3DBaseTexture9 *texture;
360 struct d3d9_surface *surface;
361
362 if (!(surface = calloc(1, sizeof(*surface))))
363 return NULL;
364
366 d3d9_resource_init(&surface->resource);
367 surface->resource.refcount = 0;
368 list_init(&surface->rtv_entry);
369 surface->container = container;
373
374 if (surface->container && SUCCEEDED(IUnknown_QueryInterface(surface->container,
375 &IID_IDirect3DBaseTexture9, (void **)&texture)))
376 {
379 }
380
383
384 TRACE("Created surface %p.\n", surface);
385 return surface;
386}
387
389{
390 struct d3d9_surface *surface = parent;
391
392 /* If the surface reference count drops to zero, we release our reference
393 * to the view, but don't clear the pointer yet, in case e.g. a
394 * GetRenderTarget() call brings the surface back before the view is
395 * actually destroyed. When the view is destroyed, we need to clear the
396 * pointer, or a subsequent surface AddRef() would reference it again.
397 *
398 * This is safe because as long as the view still has a reference to the
399 * texture, the surface is also still alive, and we're called before the
400 * view releases that reference. */
401 surface->wined3d_rtv = NULL;
402 list_remove(&surface->rtv_entry);
403}
404
406{
408};
409
411{
413 device = surface->texture ? &surface->texture->parent_device->IDirect3DDevice9Ex_iface : surface->parent_device;
415}
416
418{
419 HRESULT hr;
420
421 /* The surface reference count can be equal to 0 when this function is
422 * called. In order to properly manage the render target view reference
423 * count, we temporarily increment the surface reference count. */
425
426 if (surface->wined3d_rtv)
427 return surface->wined3d_rtv;
428
430 surface->sub_resource_idx, surface, &d3d9_view_wined3d_parent_ops, &surface->wined3d_rtv)))
431 {
432 ERR("Failed to create rendertarget view, hr %#lx.\n", hr);
434 return NULL;
435 }
436
437 if (surface->texture)
438 list_add_head(&surface->texture->rtv_list, &surface->rtv_entry);
439
440 return surface->wined3d_rtv;
441}
442
444 struct wined3d_rendertarget_view *rtv)
445{
446 if (rtv)
448}
449
451{
452 if (!iface)
453 return NULL;
454 assert(iface->lpVtbl == &d3d9_surface_vtbl);
455
456 return impl_from_IDirect3DSurface9(iface);
457}
#define InterlockedIncrement
Definition: armddk.h:53
#define InterlockedDecrement
Definition: armddk.h:52
static const char * wine_dbgstr_rect(const RECT *prc)
Definition: atltest.h:160
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
Definition: precomp.h:23
static void list_remove(struct list_entry *entry)
Definition: list.h:90
static void list_add_head(struct list_entry *head, struct list_entry *entry)
Definition: list.h:76
static void list_init(struct list_entry *head)
Definition: list.h:51
#define WARN(fmt,...)
Definition: precomp.h:61
#define ERR(fmt,...)
Definition: precomp.h:57
const GUID IID_IUnknown
#define STDMETHODCALLTYPE
Definition: bdasup.h:9
RECT rect
Definition: combotst.c:67
HDC dc
Definition: cylfrac.c:34
#define D3DERR_INVALIDCALL
Definition: d3d10_private.h:42
static DWORD d3dusage_from_wined3dusage(unsigned int wined3d_usage, unsigned int bind_flags)
Definition: d3d8_private.h:305
D3DFORMAT d3dformat_from_wined3dformat(enum wined3d_format_id format)
Definition: device.c:33
static D3DMULTISAMPLE_TYPE d3dmultisample_type_from_wined3d(enum wined3d_multisample_type type)
Definition: d3d8_private.h:387
unsigned int wined3dmapflags_from_d3dmapflags(unsigned int flags, unsigned int usage)
Definition: device.c:135
static D3DPOOL d3dpool_from_wined3daccess(unsigned int access, unsigned int usage)
Definition: d3d8_private.h:315
enum _D3DRESOURCETYPE D3DRESOURCETYPE
@ D3DRTYPE_TEXTURE
Definition: d3d8types.h:812
@ D3DRTYPE_SURFACE
Definition: d3d8types.h:810
#define IDirect3DDevice9Ex_Release(p)
Definition: d3d9.h:1930
#define IDirect3DBaseTexture9_GetDevice(p, a)
Definition: d3d9.h:665
#define IDirect3DSurface9_AddRef(p)
Definition: d3d9.h:449
#define IDirect3DDevice9Ex_AddRef(p)
Definition: d3d9.h:1929
#define IDirect3DBaseTexture9_Release(p)
Definition: d3d9.h:663
#define IDirect3DBaseTexture9_AddRef(p)
Definition: d3d9.h:662
#define IDirect3DDevice9_AddRef(p)
Definition: d3d9.h:1335
#define IDirect3DBaseTexture9_GetType(p)
Definition: d3d9.h:672
void d3d9_resource_init(struct d3d9_resource *resource)
Definition: d3d9_main.c:345
HRESULT d3d9_resource_free_private_data(struct d3d9_resource *resource, const GUID *guid)
Definition: d3d9_main.c:289
HRESULT d3d9_resource_set_private_data(struct d3d9_resource *resource, const GUID *guid, const void *data, DWORD data_size, DWORD flags)
Definition: d3d9_main.c:351
void d3d9_resource_cleanup(struct d3d9_resource *resource)
Definition: d3d9_main.c:284
HRESULT d3d9_resource_get_private_data(struct d3d9_resource *resource, const GUID *guid, void *data, DWORD *data_size)
Definition: d3d9_main.c:307
#define D3D_OK
Definition: d3d.h:106
#define E_INVALIDARG
Definition: ddrawi.h:101
#define free
Definition: debug_ros.c:5
HRESULT hr
Definition: delayimp.cpp:582
#define NULL
Definition: types.h:112
static void STDMETHODCALLTYPE surface_wined3d_object_destroyed(void *parent)
Definition: surface.c:306
static void STDMETHODCALLTYPE view_wined3d_object_destroyed(void *parent)
Definition: surface.c:350
void d3d9_surface_release_rendertarget_view(struct d3d9_surface *surface, struct wined3d_rendertarget_view *rtv)
Definition: surface.c:443
struct d3d9_device * d3d9_surface_get_device(const struct d3d9_surface *surface)
Definition: surface.c:410
static const struct IDirect3DSurface9Vtbl d3d9_surface_vtbl
Definition: surface.c:320
static D3DRESOURCETYPE WINAPI d3d9_surface_GetType(IDirect3DSurface9 *iface)
Definition: surface.c:190
static HRESULT WINAPI d3d9_surface_GetPrivateData(IDirect3DSurface9 *iface, REFGUID guid, void *data, DWORD *data_size)
Definition: surface.c:149
static HRESULT WINAPI d3d9_surface_GetDesc(IDirect3DSurface9 *iface, D3DSURFACE_DESC *desc)
Definition: surface.c:214
struct d3d9_surface * d3d9_surface_create(struct wined3d_texture *wined3d_texture, unsigned int sub_resource_idx, IUnknown *container)
Definition: surface.c:356
static HRESULT WINAPI d3d9_surface_GetDC(IDirect3DSurface9 *iface, HDC *dc)
Definition: surface.c:290
static HRESULT WINAPI d3d9_surface_QueryInterface(IDirect3DSurface9 *iface, REFIID riid, void **out)
Definition: surface.c:31
static HRESULT WINAPI d3d9_surface_GetDevice(IDirect3DSurface9 *iface, IDirect3DDevice9 **device)
Definition: surface.c:122
static HRESULT WINAPI d3d9_surface_LockRect(IDirect3DSurface9 *iface, D3DLOCKED_RECT *locked_rect, const RECT *rect, DWORD flags)
Definition: surface.c:237
static const struct wined3d_parent_ops d3d9_view_wined3d_parent_ops
Definition: surface.c:405
static HRESULT WINAPI d3d9_surface_SetPrivateData(IDirect3DSurface9 *iface, REFGUID guid, const void *data, DWORD data_size, DWORD flags)
Definition: surface.c:139
struct wined3d_rendertarget_view * d3d9_surface_acquire_rendertarget_view(struct d3d9_surface *surface)
Definition: surface.c:417
static DWORD WINAPI d3d9_surface_SetPriority(IDirect3DSurface9 *iface, DWORD priority)
Definition: surface.c:167
struct d3d9_surface * unsafe_impl_from_IDirect3DSurface9(IDirect3DSurface9 *iface)
Definition: surface.c:450
static ULONG WINAPI d3d9_surface_AddRef(IDirect3DSurface9 *iface)
Definition: surface.c:50
static void WINAPI d3d9_surface_PreLoad(IDirect3DSurface9 *iface)
Definition: surface.c:179
static HRESULT WINAPI d3d9_surface_FreePrivateData(IDirect3DSurface9 *iface, REFGUID guid)
Definition: surface.c:159
static HRESULT WINAPI d3d9_surface_UnlockRect(IDirect3DSurface9 *iface)
Definition: surface.c:265
static HRESULT WINAPI d3d9_surface_GetContainer(IDirect3DSurface9 *iface, REFIID riid, void **container)
Definition: surface.c:197
static struct d3d9_surface * impl_from_IDirect3DSurface9(IDirect3DSurface9 *iface)
Definition: surface.c:26
static HRESULT WINAPI d3d9_surface_ReleaseDC(IDirect3DSurface9 *iface, HDC dc)
Definition: surface.c:304
static const struct wined3d_parent_ops d3d9_surface_wined3d_parent_ops
Definition: surface.c:351
static DWORD WINAPI d3d9_surface_GetPriority(IDirect3DSurface9 *iface)
Definition: surface.c:173
static ULONG WINAPI d3d9_surface_Release(IDirect3DSurface9 *iface)
Definition: surface.c:80
void CDECL wined3d_resource_preload(struct wined3d_resource *resource)
Definition: resource.c:311
HRESULT CDECL wined3d_resource_unmap(struct wined3d_resource *resource, unsigned int sub_resource_idx)
Definition: resource.c:304
HRESULT CDECL wined3d_resource_map(struct wined3d_resource *resource, unsigned int sub_resource_idx, struct wined3d_map_desc *map_desc, const struct wined3d_box *box, uint32_t flags)
Definition: resource.c:295
HRESULT CDECL wined3d_texture_get_dc(struct wined3d_texture *texture, unsigned int sub_resource_idx, HDC *dc)
Definition: texture.c:4243
HRESULT CDECL wined3d_texture_get_sub_resource_desc(const struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_sub_resource_desc *desc)
Definition: texture.c:4055
struct wined3d_swapchain *CDECL wined3d_texture_get_swapchain(struct wined3d_texture *texture)
Definition: texture.c:4028
void CDECL wined3d_texture_set_sub_resource_parent(struct wined3d_texture *texture, unsigned int sub_resource_idx, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: texture.c:4043
struct wined3d_resource *CDECL wined3d_texture_get_resource(struct wined3d_texture *texture)
Definition: texture.c:1649
ULONG CDECL wined3d_texture_decref(struct wined3d_texture *texture)
Definition: texture.c:1606
ULONG CDECL wined3d_texture_incref(struct wined3d_texture *texture)
Definition: texture.c:1516
HRESULT CDECL wined3d_texture_release_dc(struct wined3d_texture *texture, unsigned int sub_resource_idx, HDC dc)
Definition: texture.c:4291
HRESULT CDECL wined3d_rendertarget_view_create_from_sub_resource(struct wined3d_texture *texture, unsigned int sub_resource_idx, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_rendertarget_view **view)
Definition: view.c:946
ULONG CDECL wined3d_rendertarget_view_incref(struct wined3d_rendertarget_view *view)
Definition: view.c:365
ULONG CDECL wined3d_rendertarget_view_decref(struct wined3d_rendertarget_view *view)
Definition: view.c:379
GUID guid
Definition: version.c:147
#define assert(_expr)
Definition: assert.h:32
r parent
Definition: btrfs.c:3010
DWORD IDirect3DSurface9
Definition: dxva2api.idl:23
DWORD IDirect3DDevice9
Definition: dxva2api.idl:22
DWORD IDirect3DDevice9Ex
Definition: dxvahd.idl:22
unsigned long DWORD
Definition: ntddk_ex.h:95
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
GLenum GLuint texture
Definition: glext.h:6295
GLbitfield flags
Definition: glext.h:7161
REFIID riid
Definition: atlbase.h:39
#define S_OK
Definition: intsafe.h:52
#define SUCCEEDED(hr)
Definition: intsafe.h:50
#define FAILED(hr)
Definition: intsafe.h:51
#define debugstr_guid
Definition: kernel32.h:35
static HDC
Definition: imagelist.c:88
D3D11_SHADER_VARIABLE_DESC desc
Definition: reflection.c:1683
static int priority
Definition: timer.c:163
#define IsEqualGUID(rguid1, rguid2)
Definition: guiddef.h:147
#define REFIID
Definition: guiddef.h:118
#define calloc
Definition: rosglue.h:14
#define TRACE(s)
Definition: solgame.cpp:4
Definition: dcommon.idl:28
long bottom
Definition: dcommon.idl:29
long right
Definition: dcommon.idl:29
long left
Definition: dcommon.idl:29
long top
Definition: dcommon.idl:29
Definition: scsiwmi.h:51
Definition: palette.c:466
IUnknown * container
Definition: d3d9_private.h:177
IDirect3DDevice9Ex * parent_device
Definition: d3d9_private.h:176
struct wined3d_texture * wined3d_texture
Definition: d3d9_private.h:172
struct wined3d_swapchain * swapchain
Definition: d3d9_private.h:179
struct list rtv_entry
Definition: d3d9_private.h:174
IDirect3DSurface9 IDirect3DSurface9_iface
Definition: d3d9_private.h:170
struct d3d9_resource resource
Definition: d3d9_private.h:171
struct wined3d_rendertarget_view * wined3d_rtv
Definition: d3d9_private.h:175
struct d3d9_texture * texture
Definition: d3d9_private.h:178
unsigned int sub_resource_idx
Definition: d3d9_private.h:173
Definition: devices.h:37
enum wined3d_format_id format
Definition: wined3d.h:1806
unsigned int multisample_quality
Definition: wined3d.h:1808
unsigned int bind_flags
Definition: wined3d.h:1810
enum wined3d_multisample_type multisample_type
Definition: wined3d.h:1807
#define CONTAINING_RECORD(address, type, field)
Definition: typedefs.h:260
uint32_t ULONG
Definition: typedefs.h:59
wchar_t tm const _CrtWcstime_Writes_and_advances_ptr_ count wchar_t ** out
Definition: wcsftime.cpp:383
#define WINAPI
Definition: msvc.h:6
static struct d3d9_device * impl_from_IDirect3DDevice9Ex(IDirect3DDevice9Ex *iface)
Definition: d3d9_private.h:310
struct d3d9_texture * unsafe_impl_from_IDirect3DBaseTexture9(IDirect3DBaseTexture9 *iface)
Definition: texture.c:1204
void d3d9_texture_flag_auto_gen_mipmap(struct d3d9_texture *texture)
Definition: texture.c:106
ULONG CDECL wined3d_swapchain_decref(struct wined3d_swapchain *swapchain)
Definition: swapchain.c:144
ULONG CDECL wined3d_swapchain_incref(struct wined3d_swapchain *swapchain)
Definition: swapchain.c:135
#define WINEDDERR_NOTLOCKED
Definition: wined3d.h:46
static void wined3d_box_set(struct wined3d_box *box, unsigned int left, unsigned int top, unsigned int right, unsigned int bottom, unsigned int front, unsigned int back)
Definition: wined3d.h:3006
void WINAPI wined3d_mutex_unlock(void)
Definition: wined3d_main.c:544
void WINAPI wined3d_mutex_lock(void)
Definition: wined3d_main.c:539
#define E_NOINTERFACE
Definition: winerror.h:3479