Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
503b1639
Commit
503b1639
authored
May 31, 2012
by
Henri Verbeet
Committed by
Alexandre Julliard
May 31, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d9: Get rid of IDirect3DVertexBuffer9Impl.
parent
5227dfa8
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
54 additions
and
62 deletions
+54
-62
buffer.c
dlls/d3d9/buffer.c
+41
-42
d3d9_private.h
dlls/d3d9/d3d9_private.h
+7
-14
device.c
dlls/d3d9/device.c
+6
-6
No files found.
dlls/d3d9/buffer.c
View file @
503b1639
...
...
@@ -23,42 +23,42 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d9
);
static
inline
IDirect3DVertexBuffer9Impl
*
impl_from_IDirect3DVertexBuffer9
(
IDirect3DVertexBuffer9
*
iface
)
static
inline
struct
d3d9_vertexbuffer
*
impl_from_IDirect3DVertexBuffer9
(
IDirect3DVertexBuffer9
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
IDirect3DVertexBuffer9Impl
,
IDirect3DVertexBuffer9_iface
);
return
CONTAINING_RECORD
(
iface
,
struct
d3d9_vertexbuffer
,
IDirect3DVertexBuffer9_iface
);
}
static
HRESULT
WINAPI
d3d9_vertexbuffer_QueryInterface
(
IDirect3DVertexBuffer9
*
iface
,
REFIID
riid
,
void
**
o
bjec
t
)
static
HRESULT
WINAPI
d3d9_vertexbuffer_QueryInterface
(
IDirect3DVertexBuffer9
*
iface
,
REFIID
riid
,
void
**
o
u
t
)
{
TRACE
(
"iface %p, riid %s, o
bject %p.
\n
"
,
iface
,
debugstr_guid
(
riid
),
objec
t
);
TRACE
(
"iface %p, riid %s, o
ut %p.
\n
"
,
iface
,
debugstr_guid
(
riid
),
ou
t
);
if
(
IsEqualGUID
(
riid
,
&
IID_IDirect3DVertexBuffer9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IUnknown
))
{
IDirect3DVertexBuffer9_AddRef
(
iface
);
*
o
bjec
t
=
iface
;
*
o
u
t
=
iface
;
return
S_OK
;
}
WARN
(
"%s not implemented, returning E_NOINTERFACE.
\n
"
,
debugstr_guid
(
riid
));
*
o
bjec
t
=
NULL
;
*
o
u
t
=
NULL
;
return
E_NOINTERFACE
;
}
static
ULONG
WINAPI
d3d9_vertexbuffer_AddRef
(
IDirect3DVertexBuffer9
*
iface
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
ULONG
refcount
=
InterlockedIncrement
(
&
buffer
->
ref
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
ULONG
refcount
=
InterlockedIncrement
(
&
buffer
->
ref
count
);
TRACE
(
"%p increasing refcount to %u.
\n
"
,
iface
,
refcount
);
if
(
refcount
==
1
)
{
IDirect3DDevice9Ex_AddRef
(
buffer
->
parent
D
evice
);
IDirect3DDevice9Ex_AddRef
(
buffer
->
parent
_d
evice
);
wined3d_mutex_lock
();
wined3d_buffer_incref
(
buffer
->
wine
D3DVertexB
uffer
);
wined3d_buffer_incref
(
buffer
->
wine
d3d_b
uffer
);
wined3d_mutex_unlock
();
}
...
...
@@ -67,17 +67,17 @@ static ULONG WINAPI d3d9_vertexbuffer_AddRef(IDirect3DVertexBuffer9 *iface)
static
ULONG
WINAPI
d3d9_vertexbuffer_Release
(
IDirect3DVertexBuffer9
*
iface
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
ULONG
refcount
=
InterlockedDecrement
(
&
buffer
->
ref
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
ULONG
refcount
=
InterlockedDecrement
(
&
buffer
->
ref
count
);
TRACE
(
"%p decreasing refcount to %u.
\n
"
,
iface
,
refcount
);
if
(
!
refcount
)
{
IDirect3DDevice9Ex
*
device
=
buffer
->
parent
D
evice
;
IDirect3DDevice9Ex
*
device
=
buffer
->
parent
_d
evice
;
wined3d_mutex_lock
();
wined3d_buffer_decref
(
buffer
->
wine
D3DVertexB
uffer
);
wined3d_buffer_decref
(
buffer
->
wine
d3d_b
uffer
);
wined3d_mutex_unlock
();
/* Release the device last, as it may cause the device to be destroyed. */
...
...
@@ -87,14 +87,13 @@ static ULONG WINAPI d3d9_vertexbuffer_Release(IDirect3DVertexBuffer9 *iface)
return
refcount
;
}
static
HRESULT
WINAPI
d3d9_vertexbuffer_GetDevice
(
IDirect3DVertexBuffer9
*
iface
,
IDirect3DDevice9
**
device
)
static
HRESULT
WINAPI
d3d9_vertexbuffer_GetDevice
(
IDirect3DVertexBuffer9
*
iface
,
IDirect3DDevice9
**
device
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
TRACE
(
"iface %p, device %p.
\n
"
,
iface
,
device
);
*
device
=
(
IDirect3DDevice9
*
)
buffer
->
parent
D
evice
;
*
device
=
(
IDirect3DDevice9
*
)
buffer
->
parent
_d
evice
;
IDirect3DDevice9_AddRef
(
*
device
);
TRACE
(
"Returning device %p.
\n
"
,
*
device
);
...
...
@@ -105,7 +104,7 @@ static HRESULT WINAPI d3d9_vertexbuffer_GetDevice(IDirect3DVertexBuffer9 *iface,
static
HRESULT
WINAPI
d3d9_vertexbuffer_SetPrivateData
(
IDirect3DVertexBuffer9
*
iface
,
REFGUID
guid
,
const
void
*
data
,
DWORD
data_size
,
DWORD
flags
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
wined3d_resource
*
resource
;
HRESULT
hr
;
...
...
@@ -113,7 +112,7 @@ static HRESULT WINAPI d3d9_vertexbuffer_SetPrivateData(IDirect3DVertexBuffer9 *i
iface
,
debugstr_guid
(
guid
),
data
,
data_size
,
flags
);
wined3d_mutex_lock
();
resource
=
wined3d_buffer_get_resource
(
buffer
->
wine
D3DVertexB
uffer
);
resource
=
wined3d_buffer_get_resource
(
buffer
->
wine
d3d_b
uffer
);
hr
=
wined3d_resource_set_private_data
(
resource
,
guid
,
data
,
data_size
,
flags
);
wined3d_mutex_unlock
();
...
...
@@ -123,7 +122,7 @@ static HRESULT WINAPI d3d9_vertexbuffer_SetPrivateData(IDirect3DVertexBuffer9 *i
static
HRESULT
WINAPI
d3d9_vertexbuffer_GetPrivateData
(
IDirect3DVertexBuffer9
*
iface
,
REFGUID
guid
,
void
*
data
,
DWORD
*
data_size
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
wined3d_resource
*
resource
;
HRESULT
hr
;
...
...
@@ -131,7 +130,7 @@ static HRESULT WINAPI d3d9_vertexbuffer_GetPrivateData(IDirect3DVertexBuffer9 *i
iface
,
debugstr_guid
(
guid
),
data
,
data_size
);
wined3d_mutex_lock
();
resource
=
wined3d_buffer_get_resource
(
buffer
->
wine
D3DVertexB
uffer
);
resource
=
wined3d_buffer_get_resource
(
buffer
->
wine
d3d_b
uffer
);
hr
=
wined3d_resource_get_private_data
(
resource
,
guid
,
data
,
data_size
);
wined3d_mutex_unlock
();
...
...
@@ -140,14 +139,14 @@ static HRESULT WINAPI d3d9_vertexbuffer_GetPrivateData(IDirect3DVertexBuffer9 *i
static
HRESULT
WINAPI
d3d9_vertexbuffer_FreePrivateData
(
IDirect3DVertexBuffer9
*
iface
,
REFGUID
guid
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
wined3d_resource
*
resource
;
HRESULT
hr
;
TRACE
(
"iface %p, guid %s.
\n
"
,
iface
,
debugstr_guid
(
guid
));
wined3d_mutex_lock
();
resource
=
wined3d_buffer_get_resource
(
buffer
->
wine
D3DVertexB
uffer
);
resource
=
wined3d_buffer_get_resource
(
buffer
->
wine
d3d_b
uffer
);
hr
=
wined3d_resource_free_private_data
(
resource
,
guid
);
wined3d_mutex_unlock
();
...
...
@@ -156,13 +155,13 @@ static HRESULT WINAPI d3d9_vertexbuffer_FreePrivateData(IDirect3DVertexBuffer9 *
static
DWORD
WINAPI
d3d9_vertexbuffer_SetPriority
(
IDirect3DVertexBuffer9
*
iface
,
DWORD
priority
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
DWORD
previous
;
TRACE
(
"iface %p, priority %u.
\n
"
,
iface
,
priority
);
wined3d_mutex_lock
();
previous
=
wined3d_buffer_set_priority
(
buffer
->
wine
D3DVertexB
uffer
,
priority
);
previous
=
wined3d_buffer_set_priority
(
buffer
->
wine
d3d_b
uffer
,
priority
);
wined3d_mutex_unlock
();
return
previous
;
...
...
@@ -170,13 +169,13 @@ static DWORD WINAPI d3d9_vertexbuffer_SetPriority(IDirect3DVertexBuffer9 *iface,
static
DWORD
WINAPI
d3d9_vertexbuffer_GetPriority
(
IDirect3DVertexBuffer9
*
iface
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
DWORD
priority
;
TRACE
(
"iface %p.
\n
"
,
iface
);
wined3d_mutex_lock
();
priority
=
wined3d_buffer_get_priority
(
buffer
->
wine
D3DVertexB
uffer
);
priority
=
wined3d_buffer_get_priority
(
buffer
->
wine
d3d_b
uffer
);
wined3d_mutex_unlock
();
return
priority
;
...
...
@@ -184,12 +183,12 @@ static DWORD WINAPI d3d9_vertexbuffer_GetPriority(IDirect3DVertexBuffer9 *iface)
static
void
WINAPI
d3d9_vertexbuffer_PreLoad
(
IDirect3DVertexBuffer9
*
iface
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
TRACE
(
"iface %p.
\n
"
,
iface
);
wined3d_mutex_lock
();
wined3d_buffer_preload
(
buffer
->
wine
D3DVertexB
uffer
);
wined3d_buffer_preload
(
buffer
->
wine
d3d_b
uffer
);
wined3d_mutex_unlock
();
}
...
...
@@ -203,14 +202,14 @@ static D3DRESOURCETYPE WINAPI d3d9_vertexbuffer_GetType(IDirect3DVertexBuffer9 *
static
HRESULT
WINAPI
d3d9_vertexbuffer_Lock
(
IDirect3DVertexBuffer9
*
iface
,
UINT
offset
,
UINT
size
,
void
**
data
,
DWORD
flags
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
HRESULT
hr
;
TRACE
(
"iface %p, offset %u, size %u, data %p, flags %#x.
\n
"
,
iface
,
offset
,
size
,
data
,
flags
);
wined3d_mutex_lock
();
hr
=
wined3d_buffer_map
(
buffer
->
wine
D3DVertexB
uffer
,
offset
,
size
,
(
BYTE
**
)
data
,
flags
);
hr
=
wined3d_buffer_map
(
buffer
->
wine
d3d_b
uffer
,
offset
,
size
,
(
BYTE
**
)
data
,
flags
);
wined3d_mutex_unlock
();
return
hr
;
...
...
@@ -218,12 +217,12 @@ static HRESULT WINAPI d3d9_vertexbuffer_Lock(IDirect3DVertexBuffer9 *iface, UINT
static
HRESULT
WINAPI
d3d9_vertexbuffer_Unlock
(
IDirect3DVertexBuffer9
*
iface
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
TRACE
(
"iface %p.
\n
"
,
iface
);
wined3d_mutex_lock
();
wined3d_buffer_unmap
(
buffer
->
wine
D3DVertexB
uffer
);
wined3d_buffer_unmap
(
buffer
->
wine
d3d_b
uffer
);
wined3d_mutex_unlock
();
return
D3D_OK
;
...
...
@@ -232,14 +231,14 @@ static HRESULT WINAPI d3d9_vertexbuffer_Unlock(IDirect3DVertexBuffer9 *iface)
static
HRESULT
WINAPI
d3d9_vertexbuffer_GetDesc
(
IDirect3DVertexBuffer9
*
iface
,
D3DVERTEXBUFFER_DESC
*
desc
)
{
IDirect3DVertexBuffer9Impl
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
d3d9_vertexbuffer
*
buffer
=
impl_from_IDirect3DVertexBuffer9
(
iface
);
struct
wined3d_resource_desc
wined3d_desc
;
struct
wined3d_resource
*
wined3d_resource
;
TRACE
(
"iface %p, desc %p.
\n
"
,
iface
,
desc
);
wined3d_mutex_lock
();
wined3d_resource
=
wined3d_buffer_get_resource
(
buffer
->
wine
D3DVertexB
uffer
);
wined3d_resource
=
wined3d_buffer_get_resource
(
buffer
->
wine
d3d_b
uffer
);
wined3d_resource_get_desc
(
wined3d_resource
,
&
wined3d_desc
);
wined3d_mutex_unlock
();
...
...
@@ -284,18 +283,18 @@ static const struct wined3d_parent_ops d3d9_vertexbuffer_wined3d_parent_ops =
d3d9_vertexbuffer_wined3d_object_destroyed
,
};
HRESULT
vertexbuffer_init
(
IDirect3DVertexBuffer9Impl
*
buffer
,
struct
d3d9_device
*
device
,
HRESULT
vertexbuffer_init
(
struct
d3d9_vertexbuffer
*
buffer
,
struct
d3d9_device
*
device
,
UINT
size
,
UINT
usage
,
DWORD
fvf
,
D3DPOOL
pool
)
{
HRESULT
hr
;
buffer
->
IDirect3DVertexBuffer9_iface
.
lpVtbl
=
&
d3d9_vertexbuffer_vtbl
;
buffer
->
ref
=
1
;
buffer
->
ref
count
=
1
;
buffer
->
fvf
=
fvf
;
wined3d_mutex_lock
();
hr
=
wined3d_buffer_create_vb
(
device
->
wined3d_device
,
size
,
usage
&
WINED3DUSAGE_MASK
,
(
enum
wined3d_pool
)
pool
,
buffer
,
&
d3d9_vertexbuffer_wined3d_parent_ops
,
&
buffer
->
wine
D3DVertexB
uffer
);
(
enum
wined3d_pool
)
pool
,
buffer
,
&
d3d9_vertexbuffer_wined3d_parent_ops
,
&
buffer
->
wine
d3d_b
uffer
);
wined3d_mutex_unlock
();
if
(
FAILED
(
hr
))
{
...
...
@@ -303,13 +302,13 @@ HRESULT vertexbuffer_init(IDirect3DVertexBuffer9Impl *buffer, struct d3d9_device
return
hr
;
}
buffer
->
parent
D
evice
=
&
device
->
IDirect3DDevice9Ex_iface
;
IDirect3DDevice9Ex_AddRef
(
buffer
->
parent
D
evice
);
buffer
->
parent
_d
evice
=
&
device
->
IDirect3DDevice9Ex_iface
;
IDirect3DDevice9Ex_AddRef
(
buffer
->
parent
_d
evice
);
return
D3D_OK
;
}
IDirect3DVertexBuffer9Impl
*
unsafe_impl_from_IDirect3DVertexBuffer9
(
IDirect3DVertexBuffer9
*
iface
)
struct
d3d9_vertexbuffer
*
unsafe_impl_from_IDirect3DVertexBuffer9
(
IDirect3DVertexBuffer9
*
iface
)
{
if
(
!
iface
)
return
NULL
;
...
...
dlls/d3d9/d3d9_private.h
View file @
503b1639
...
...
@@ -203,25 +203,18 @@ HRESULT surface_init(struct d3d9_surface *surface, struct d3d9_device *device,
DWORD
usage
,
D3DPOOL
pool
,
D3DMULTISAMPLE_TYPE
multisample_type
,
DWORD
multisample_quality
)
DECLSPEC_HIDDEN
;
struct
d3d9_surface
*
unsafe_impl_from_IDirect3DSurface9
(
IDirect3DSurface9
*
iface
)
DECLSPEC_HIDDEN
;
/* ---------------------- */
/* IDirect3DVertexBuffer9 */
/* ---------------------- */
/*****************************************************************************
* IDirect3DVertexBuffer9 implementation structure
*/
typedef
struct
IDirect3DVertexBuffer9Impl
struct
d3d9_vertexbuffer
{
IDirect3DVertexBuffer9
IDirect3DVertexBuffer9_iface
;
LONG
ref
;
struct
wined3d_buffer
*
wine
D3DVertexB
uffer
;
IDirect3DDevice9Ex
*
parent
D
evice
;
LONG
ref
count
;
struct
wined3d_buffer
*
wine
d3d_b
uffer
;
IDirect3DDevice9Ex
*
parent
_d
evice
;
DWORD
fvf
;
}
IDirect3DVertexBuffer9Impl
;
};
HRESULT
vertexbuffer_init
(
IDirect3DVertexBuffer9Impl
*
buffer
,
struct
d3d9_device
*
device
,
HRESULT
vertexbuffer_init
(
struct
d3d9_vertexbuffer
*
buffer
,
struct
d3d9_device
*
device
,
UINT
size
,
UINT
usage
,
DWORD
fvf
,
D3DPOOL
pool
)
DECLSPEC_HIDDEN
;
IDirect3DVertexBuffer9Impl
*
unsafe_impl_from_IDirect3DVertexBuffer9
(
IDirect3DVertexBuffer9
*
iface
)
DECLSPEC_HIDDEN
;
struct
d3d9_vertexbuffer
*
unsafe_impl_from_IDirect3DVertexBuffer9
(
IDirect3DVertexBuffer9
*
iface
)
DECLSPEC_HIDDEN
;
/* --------------------- */
/* IDirect3DIndexBuffer9 */
...
...
dlls/d3d9/device.c
View file @
503b1639
...
...
@@ -796,7 +796,7 @@ static HRESULT WINAPI d3d9_device_CreateVertexBuffer(IDirect3DDevice9Ex *iface,
HANDLE
*
shared_handle
)
{
struct
d3d9_device
*
device
=
impl_from_IDirect3DDevice9Ex
(
iface
);
IDirect3DVertexBuffer9Impl
*
object
;
struct
d3d9_vertexbuffer
*
object
;
HRESULT
hr
;
TRACE
(
"iface %p, size %u, usage %#x, fvf %#x, pool %#x, buffer %p, shared_handle %p.
\n
"
,
...
...
@@ -2018,7 +2018,7 @@ static HRESULT WINAPI d3d9_device_ProcessVertices(IDirect3DDevice9Ex *iface,
IDirect3DVertexDeclaration9
*
declaration
,
DWORD
flags
)
{
struct
d3d9_device
*
device
=
impl_from_IDirect3DDevice9Ex
(
iface
);
IDirect3DVertexBuffer9Impl
*
dst_impl
=
unsafe_impl_from_IDirect3DVertexBuffer9
(
dst_buffer
);
struct
d3d9_vertexbuffer
*
dst_impl
=
unsafe_impl_from_IDirect3DVertexBuffer9
(
dst_buffer
);
IDirect3DVertexDeclaration9Impl
*
decl_impl
=
unsafe_impl_from_IDirect3DVertexDeclaration9
(
declaration
);
HRESULT
hr
;
...
...
@@ -2027,7 +2027,7 @@ static HRESULT WINAPI d3d9_device_ProcessVertices(IDirect3DDevice9Ex *iface,
wined3d_mutex_lock
();
hr
=
wined3d_device_process_vertices
(
device
->
wined3d_device
,
src_start_idx
,
dst_idx
,
vertex_count
,
dst_impl
->
wine
D3DVertexB
uffer
,
decl_impl
?
decl_impl
->
wineD3DVertexDeclaration
:
NULL
,
dst_impl
->
wine
d3d_b
uffer
,
decl_impl
?
decl_impl
->
wineD3DVertexDeclaration
:
NULL
,
flags
,
dst_impl
->
fvf
);
wined3d_mutex_unlock
();
...
...
@@ -2418,7 +2418,7 @@ static HRESULT WINAPI d3d9_device_SetStreamSource(IDirect3DDevice9Ex *iface,
UINT
stream_idx
,
IDirect3DVertexBuffer9
*
buffer
,
UINT
offset
,
UINT
stride
)
{
struct
d3d9_device
*
device
=
impl_from_IDirect3DDevice9Ex
(
iface
);
IDirect3DVertexBuffer9Impl
*
buffer_impl
=
unsafe_impl_from_IDirect3DVertexBuffer9
(
buffer
);
struct
d3d9_vertexbuffer
*
buffer_impl
=
unsafe_impl_from_IDirect3DVertexBuffer9
(
buffer
);
HRESULT
hr
;
TRACE
(
"iface %p, stream_idx %u, buffer %p, offset %u, stride %u.
\n
"
,
...
...
@@ -2426,7 +2426,7 @@ static HRESULT WINAPI d3d9_device_SetStreamSource(IDirect3DDevice9Ex *iface,
wined3d_mutex_lock
();
hr
=
wined3d_device_set_stream_source
(
device
->
wined3d_device
,
stream_idx
,
buffer_impl
?
buffer_impl
->
wine
D3DVertexB
uffer
:
NULL
,
offset
,
stride
);
buffer_impl
?
buffer_impl
->
wine
d3d_b
uffer
:
NULL
,
offset
,
stride
);
wined3d_mutex_unlock
();
return
hr
;
...
...
@@ -2436,7 +2436,7 @@ static HRESULT WINAPI d3d9_device_GetStreamSource(IDirect3DDevice9Ex *iface,
UINT
stream_idx
,
IDirect3DVertexBuffer9
**
buffer
,
UINT
*
offset
,
UINT
*
stride
)
{
struct
d3d9_device
*
device
=
impl_from_IDirect3DDevice9Ex
(
iface
);
IDirect3DVertexBuffer9Impl
*
buffer_impl
;
struct
d3d9_vertexbuffer
*
buffer_impl
;
struct
wined3d_buffer
*
wined3d_buffer
;
HRESULT
hr
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment