Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
21da7be6
Commit
21da7be6
authored
Feb 23, 2015
by
Henri Verbeet
Committed by
Alexandre Julliard
Feb 24, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d10core: Implement d3d10_texture2d_SetPrivateDataInterface().
parent
c2e6a7d0
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
28 additions
and
6 deletions
+28
-6
d3d10core_private.h
dlls/d3d10core/d3d10core_private.h
+2
-0
device.c
dlls/d3d10core/tests/device.c
+3
-4
texture.c
dlls/d3d10core/texture.c
+14
-2
utils.c
dlls/d3d10core/utils.c
+9
-0
No files found.
dlls/d3d10core/d3d10core_private.h
View file @
21da7be6
...
...
@@ -68,6 +68,8 @@ DWORD wined3d_map_flags_from_d3d10_map_type(D3D10_MAP map_type) DECLSPEC_HIDDEN;
HRESULT
d3d10_set_private_data
(
struct
wined3d_private_store
*
store
,
REFGUID
guid
,
UINT
data_size
,
const
void
*
data
)
DECLSPEC_HIDDEN
;
HRESULT
d3d10_set_private_data_interface
(
struct
wined3d_private_store
*
store
,
REFGUID
guid
,
const
IUnknown
*
object
)
DECLSPEC_HIDDEN
;
static
inline
void
read_dword
(
const
char
**
ptr
,
DWORD
*
d
)
{
...
...
dlls/d3d10core/tests/device.c
View file @
21da7be6
...
...
@@ -2672,13 +2672,12 @@ static void test_private_data(void)
ok
(
ptr
==
(
IUnknown
*
)
0xdeadbeef
,
"Got unexpected pointer %p.
\n
"
,
ptr
);
hr
=
ID3D10Texture2D_SetPrivateDataInterface
(
texture
,
&
test_guid
,
(
IUnknown
*
)
test_object
);
todo_wine
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ptr
=
NULL
;
size
=
sizeof
(
ptr
);
hr
=
IDXGISurface_GetPrivateData
(
surface
,
&
test_guid
,
&
size
,
&
ptr
);
todo_wine
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
todo_wine
ok
(
ptr
==
(
IUnknown
*
)
test_object
,
"Got unexpected ptr %p, expected %p.
\n
"
,
ptr
,
test_object
);
if
(
ptr
)
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ok
(
ptr
==
(
IUnknown
*
)
test_object
,
"Got unexpected ptr %p, expected %p.
\n
"
,
ptr
,
test_object
);
IUnknown_Release
(
ptr
);
IDXGISurface_Release
(
surface
);
...
...
dlls/d3d10core/texture.c
View file @
21da7be6
...
...
@@ -149,9 +149,21 @@ static HRESULT STDMETHODCALLTYPE d3d10_texture2d_SetPrivateData(ID3D10Texture2D
static
HRESULT
STDMETHODCALLTYPE
d3d10_texture2d_SetPrivateDataInterface
(
ID3D10Texture2D
*
iface
,
REFGUID
guid
,
const
IUnknown
*
data
)
{
FIXME
(
"iface %p, guid %s, data %p stub!
\n
"
,
iface
,
debugstr_guid
(
guid
),
data
);
struct
d3d10_texture2d
*
texture
=
impl_from_ID3D10Texture2D
(
iface
);
IDXGISurface
*
dxgi_surface
;
HRESULT
hr
;
return
E_NOTIMPL
;
TRACE
(
"iface %p, guid %s, data %p.
\n
"
,
iface
,
debugstr_guid
(
guid
),
data
);
if
(
texture
->
dxgi_surface
&&
SUCCEEDED
(
IUnknown_QueryInterface
(
texture
->
dxgi_surface
,
&
IID_IDXGISurface
,
(
void
**
)
&
dxgi_surface
)))
{
hr
=
IDXGISurface_SetPrivateDataInterface
(
dxgi_surface
,
guid
,
data
);
IDXGISurface_Release
(
dxgi_surface
);
return
hr
;
}
return
d3d10_set_private_data_interface
(
&
texture
->
private_store
,
guid
,
data
);
}
/* ID3D10Resource methods */
...
...
dlls/d3d10core/utils.c
View file @
21da7be6
...
...
@@ -428,6 +428,15 @@ HRESULT d3d10_set_private_data(struct wined3d_private_store *store,
return
wined3d_private_store_set_private_data
(
store
,
guid
,
data
,
data_size
,
0
);
}
HRESULT
d3d10_set_private_data_interface
(
struct
wined3d_private_store
*
store
,
REFGUID
guid
,
const
IUnknown
*
object
)
{
if
(
!
object
)
return
d3d10_set_private_data
(
store
,
guid
,
sizeof
(
object
),
&
object
);
return
wined3d_private_store_set_private_data
(
store
,
guid
,
object
,
sizeof
(
object
),
WINED3DSPD_IUNKNOWN
);
}
void
skip_dword_unknown
(
const
char
**
ptr
,
unsigned
int
count
)
{
unsigned
int
i
;
...
...
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