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
732338ab
Commit
732338ab
authored
Jun 17, 2011
by
Henri Verbeet
Committed by
Alexandre Julliard
Jun 20, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d9: Implement IDirect3DCubeTexture9 private data handling on top of wined3d_resource.
parent
4debdd6a
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
3 deletions
+18
-3
cubetexture.c
dlls/d3d9/cubetexture.c
+9
-3
texture.c
dlls/wined3d/texture.c
+7
-0
wined3d.spec
dlls/wined3d/wined3d.spec
+1
-0
wined3d.h
include/wine/wined3d.h
+1
-0
No files found.
dlls/d3d9/cubetexture.c
View file @
732338ab
...
@@ -112,13 +112,15 @@ static HRESULT WINAPI IDirect3DCubeTexture9Impl_SetPrivateData(IDirect3DCubeText
...
@@ -112,13 +112,15 @@ static HRESULT WINAPI IDirect3DCubeTexture9Impl_SetPrivateData(IDirect3DCubeText
REFGUID
refguid
,
const
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
REFGUID
refguid
,
const
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
{
IDirect3DCubeTexture9Impl
*
This
=
impl_from_IDirect3DCubeTexture9
(
iface
);
IDirect3DCubeTexture9Impl
*
This
=
impl_from_IDirect3DCubeTexture9
(
iface
);
struct
wined3d_resource
*
resource
;
HRESULT
hr
;
HRESULT
hr
;
TRACE
(
"iface %p, guid %s, data %p, data_size %u, flags %#x.
\n
"
,
TRACE
(
"iface %p, guid %s, data %p, data_size %u, flags %#x.
\n
"
,
iface
,
debugstr_guid
(
refguid
),
pData
,
SizeOfData
,
Flags
);
iface
,
debugstr_guid
(
refguid
),
pData
,
SizeOfData
,
Flags
);
wined3d_mutex_lock
();
wined3d_mutex_lock
();
hr
=
wined3d_texture_set_private_data
(
This
->
wined3d_texture
,
refguid
,
pData
,
SizeOfData
,
Flags
);
resource
=
wined3d_texture_get_resource
(
This
->
wined3d_texture
);
hr
=
wined3d_resource_set_private_data
(
resource
,
refguid
,
pData
,
SizeOfData
,
Flags
);
wined3d_mutex_unlock
();
wined3d_mutex_unlock
();
return
hr
;
return
hr
;
...
@@ -128,13 +130,15 @@ static HRESULT WINAPI IDirect3DCubeTexture9Impl_GetPrivateData(IDirect3DCubeText
...
@@ -128,13 +130,15 @@ static HRESULT WINAPI IDirect3DCubeTexture9Impl_GetPrivateData(IDirect3DCubeText
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
{
IDirect3DCubeTexture9Impl
*
This
=
impl_from_IDirect3DCubeTexture9
(
iface
);
IDirect3DCubeTexture9Impl
*
This
=
impl_from_IDirect3DCubeTexture9
(
iface
);
struct
wined3d_resource
*
resource
;
HRESULT
hr
;
HRESULT
hr
;
TRACE
(
"iface %p, guid %s, data %p, data_size %p.
\n
"
,
TRACE
(
"iface %p, guid %s, data %p, data_size %p.
\n
"
,
iface
,
debugstr_guid
(
refguid
),
pData
,
pSizeOfData
);
iface
,
debugstr_guid
(
refguid
),
pData
,
pSizeOfData
);
wined3d_mutex_lock
();
wined3d_mutex_lock
();
hr
=
wined3d_texture_get_private_data
(
This
->
wined3d_texture
,
refguid
,
pData
,
pSizeOfData
);
resource
=
wined3d_texture_get_resource
(
This
->
wined3d_texture
);
hr
=
wined3d_resource_get_private_data
(
resource
,
refguid
,
pData
,
pSizeOfData
);
wined3d_mutex_unlock
();
wined3d_mutex_unlock
();
return
hr
;
return
hr
;
...
@@ -144,12 +148,14 @@ static HRESULT WINAPI IDirect3DCubeTexture9Impl_FreePrivateData(IDirect3DCubeTex
...
@@ -144,12 +148,14 @@ static HRESULT WINAPI IDirect3DCubeTexture9Impl_FreePrivateData(IDirect3DCubeTex
REFGUID
refguid
)
REFGUID
refguid
)
{
{
IDirect3DCubeTexture9Impl
*
This
=
impl_from_IDirect3DCubeTexture9
(
iface
);
IDirect3DCubeTexture9Impl
*
This
=
impl_from_IDirect3DCubeTexture9
(
iface
);
struct
wined3d_resource
*
resource
;
HRESULT
hr
;
HRESULT
hr
;
TRACE
(
"iface %p, guid %s.
\n
"
,
iface
,
debugstr_guid
(
refguid
));
TRACE
(
"iface %p, guid %s.
\n
"
,
iface
,
debugstr_guid
(
refguid
));
wined3d_mutex_lock
();
wined3d_mutex_lock
();
hr
=
wined3d_texture_free_private_data
(
This
->
wined3d_texture
,
refguid
);
resource
=
wined3d_texture_get_resource
(
This
->
wined3d_texture
);
hr
=
wined3d_resource_free_private_data
(
resource
,
refguid
);
wined3d_mutex_unlock
();
wined3d_mutex_unlock
();
return
hr
;
return
hr
;
...
...
dlls/wined3d/texture.c
View file @
732338ab
...
@@ -450,6 +450,13 @@ ULONG CDECL wined3d_texture_decref(struct wined3d_texture *texture)
...
@@ -450,6 +450,13 @@ ULONG CDECL wined3d_texture_decref(struct wined3d_texture *texture)
return
refcount
;
return
refcount
;
}
}
struct
wined3d_resource
*
CDECL
wined3d_texture_get_resource
(
struct
wined3d_texture
*
texture
)
{
TRACE
(
"texture %p.
\n
"
,
texture
);
return
&
texture
->
resource
;
}
HRESULT
CDECL
wined3d_texture_set_private_data
(
struct
wined3d_texture
*
texture
,
HRESULT
CDECL
wined3d_texture_set_private_data
(
struct
wined3d_texture
*
texture
,
REFGUID
guid
,
const
void
*
data
,
DWORD
data_size
,
DWORD
flags
)
REFGUID
guid
,
const
void
*
data
,
DWORD
data_size
,
DWORD
flags
)
{
{
...
...
dlls/wined3d/wined3d.spec
View file @
732338ab
...
@@ -267,6 +267,7 @@
...
@@ -267,6 +267,7 @@
@ cdecl wined3d_texture_get_parent(ptr)
@ cdecl wined3d_texture_get_parent(ptr)
@ cdecl wined3d_texture_get_priority(ptr)
@ cdecl wined3d_texture_get_priority(ptr)
@ cdecl wined3d_texture_get_private_data(ptr ptr ptr ptr)
@ cdecl wined3d_texture_get_private_data(ptr ptr ptr ptr)
@ cdecl wined3d_texture_get_resource(ptr)
@ cdecl wined3d_texture_get_sub_resource(ptr long)
@ cdecl wined3d_texture_get_sub_resource(ptr long)
@ cdecl wined3d_texture_incref(ptr)
@ cdecl wined3d_texture_incref(ptr)
@ cdecl wined3d_texture_preload(ptr)
@ cdecl wined3d_texture_preload(ptr)
...
...
include/wine/wined3d.h
View file @
732338ab
...
@@ -2504,6 +2504,7 @@ void * __cdecl wined3d_texture_get_parent(const struct wined3d_texture *texture)
...
@@ -2504,6 +2504,7 @@ void * __cdecl wined3d_texture_get_parent(const struct wined3d_texture *texture)
DWORD
__cdecl
wined3d_texture_get_priority
(
const
struct
wined3d_texture
*
texture
);
DWORD
__cdecl
wined3d_texture_get_priority
(
const
struct
wined3d_texture
*
texture
);
HRESULT
__cdecl
wined3d_texture_get_private_data
(
const
struct
wined3d_texture
*
texture
,
HRESULT
__cdecl
wined3d_texture_get_private_data
(
const
struct
wined3d_texture
*
texture
,
REFGUID
guid
,
void
*
data
,
DWORD
*
data_size
);
REFGUID
guid
,
void
*
data
,
DWORD
*
data_size
);
struct
wined3d_resource
*
__cdecl
wined3d_texture_get_resource
(
struct
wined3d_texture
*
texture
);
struct
wined3d_resource
*
__cdecl
wined3d_texture_get_sub_resource
(
struct
wined3d_texture
*
texture
,
struct
wined3d_resource
*
__cdecl
wined3d_texture_get_sub_resource
(
struct
wined3d_texture
*
texture
,
UINT
sub_resource_idx
);
UINT
sub_resource_idx
);
ULONG
__cdecl
wined3d_texture_incref
(
struct
wined3d_texture
*
texture
);
ULONG
__cdecl
wined3d_texture_incref
(
struct
wined3d_texture
*
texture
);
...
...
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