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
7f7844a7
Commit
7f7844a7
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_device_SetPrivateDataInterface().
parent
c9fd72d8
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
16 deletions
+24
-16
device.c
dlls/d3d10core/device.c
+10
-2
device.c
dlls/d3d10core/tests/device.c
+14
-14
No files found.
dlls/d3d10core/device.c
View file @
7f7844a7
...
...
@@ -1301,9 +1301,17 @@ static HRESULT STDMETHODCALLTYPE d3d10_device_SetPrivateData(ID3D10Device1 *ifac
static
HRESULT
STDMETHODCALLTYPE
d3d10_device_SetPrivateDataInterface
(
ID3D10Device1
*
iface
,
REFGUID
guid
,
const
IUnknown
*
data
)
{
FIXME
(
"iface %p, guid %s, data %p stub!
\n
"
,
iface
,
debugstr_guid
(
guid
),
data
);
IDXGIDevice
*
dxgi_device
;
HRESULT
hr
;
return
E_NOTIMPL
;
TRACE
(
"iface %p, guid %s, data %p.
\n
"
,
iface
,
debugstr_guid
(
guid
),
data
);
if
(
FAILED
(
hr
=
ID3D10Device1_QueryInterface
(
iface
,
&
IID_IDXGIDevice
,
(
void
**
)
&
dxgi_device
)))
return
hr
;
hr
=
IDXGIDevice_SetPrivateDataInterface
(
dxgi_device
,
guid
,
data
);
IDXGIDevice_Release
(
dxgi_device
);
return
hr
;
}
static
void
STDMETHODCALLTYPE
d3d10_device_ClearState
(
ID3D10Device1
*
iface
)
...
...
dlls/d3d10core/tests/device.c
View file @
7f7844a7
...
...
@@ -2551,14 +2551,14 @@ static void test_private_data(void)
hr
=
ID3D10Device_SetPrivateData
(
device
,
&
test_guid
,
0
,
NULL
);
ok
(
hr
==
S_FALSE
,
"Got unexpected hr %#x.
\n
"
,
hr
);
hr
=
ID3D10Device_SetPrivateDataInterface
(
device
,
&
test_guid
,
NULL
);
todo_wine
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
hr
=
ID3D10Device_SetPrivateData
(
device
,
&
test_guid
,
~
0u
,
NULL
);
todo_wine
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
hr
=
ID3D10Device_SetPrivateData
(
device
,
&
test_guid
,
~
0u
,
NULL
);
ok
(
hr
==
S_FALSE
,
"Got unexpected hr %#x.
\n
"
,
hr
);
hr
=
ID3D10Device_SetPrivateDataInterface
(
device
,
&
test_guid
,
NULL
);
todo_wine
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
size
=
sizeof
(
ptr
)
*
2
;
ptr
=
(
IUnknown
*
)
0xdeadbeef
;
hr
=
ID3D10Device_GetPrivateData
(
device
,
&
test_guid
,
&
size
,
&
ptr
);
...
...
@@ -2571,33 +2571,33 @@ static void test_private_data(void)
size
=
sizeof
(
ptr
)
*
2
;
ptr
=
(
IUnknown
*
)
0xdeadbeef
;
hr
=
IDXGIDevice_GetPrivateData
(
dxgi_device
,
&
test_guid
,
&
size
,
&
ptr
);
todo_wine
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
todo_wine
ok
(
!
ptr
,
"Got unexpected pointer %p.
\n
"
,
ptr
);
todo_wine
ok
(
size
==
sizeof
(
IUnknown
*
),
"Got unexpected size %u.
\n
"
,
size
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ok
(
!
ptr
,
"Got unexpected pointer %p.
\n
"
,
ptr
);
ok
(
size
==
sizeof
(
IUnknown
*
),
"Got unexpected size %u.
\n
"
,
size
);
IDXGIDevice_Release
(
dxgi_device
);
refcount
=
get_refcount
((
IUnknown
*
)
test_object
);
hr
=
ID3D10Device_SetPrivateDataInterface
(
device
,
&
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
);
expected_refcount
=
refcount
+
1
;
refcount
=
get_refcount
((
IUnknown
*
)
test_object
);
todo_wine
ok
(
refcount
==
expected_refcount
,
"Got unexpected refcount %u, expected %u.
\n
"
,
refcount
,
expected_refcount
);
ok
(
refcount
==
expected_refcount
,
"Got unexpected refcount %u, expected %u.
\n
"
,
refcount
,
expected_refcount
);
hr
=
ID3D10Device_SetPrivateDataInterface
(
device
,
&
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
);
refcount
=
get_refcount
((
IUnknown
*
)
test_object
);
todo_wine
ok
(
refcount
==
expected_refcount
,
"Got unexpected refcount %u, expected %u.
\n
"
,
refcount
,
expected_refcount
);
ok
(
refcount
==
expected_refcount
,
"Got unexpected refcount %u, expected %u.
\n
"
,
refcount
,
expected_refcount
);
hr
=
ID3D10Device_SetPrivateDataInterface
(
device
,
&
test_guid
,
NULL
);
todo_wine
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
--
expected_refcount
;
refcount
=
get_refcount
((
IUnknown
*
)
test_object
);
ok
(
refcount
==
expected_refcount
,
"Got unexpected refcount %u, expected %u.
\n
"
,
refcount
,
expected_refcount
);
hr
=
ID3D10Device_SetPrivateDataInterface
(
device
,
&
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
);
size
=
sizeof
(
data
);
hr
=
ID3D10Device_SetPrivateData
(
device
,
&
test_guid
,
size
,
data
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
...
...
@@ -2610,7 +2610,7 @@ static void test_private_data(void)
hr
=
ID3D10Device_SetPrivateDataInterface
(
device
,
&
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
);
++
expected_refcount
;
size
=
2
*
sizeof
(
ptr
);
ptr
=
NULL
;
...
...
@@ -2634,7 +2634,7 @@ static void test_private_data(void)
todo_wine
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
todo_wine
ok
(
size
==
sizeof
(
device
),
"Got unexpected size %u.
\n
"
,
size
);
refcount
=
get_refcount
((
IUnknown
*
)
test_object
);
todo_wine
ok
(
refcount
==
expected_refcount
,
"Got unexpected refcount %u, expected %u.
\n
"
,
refcount
,
expected_refcount
);
ok
(
refcount
==
expected_refcount
,
"Got unexpected refcount %u, expected %u.
\n
"
,
refcount
,
expected_refcount
);
size
=
1
;
hr
=
ID3D10Device_GetPrivateData
(
device
,
&
test_guid
,
&
size
,
&
ptr
);
...
...
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