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
97136a87
Commit
97136a87
authored
Sep 18, 2020
by
Nikolay Sivov
Committed by
Alexandre Julliard
Sep 18, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dxva2: Return some static render target formats.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
e6a42874
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
40 additions
and
3 deletions
+40
-3
main.c
dlls/dxva2/main.c
+17
-1
Makefile.in
dlls/dxva2/tests/Makefile.in
+1
-1
dxva2.c
dlls/dxva2/tests/dxva2.c
+22
-1
No files found.
dlls/dxva2/main.c
View file @
97136a87
...
...
@@ -195,7 +195,23 @@ static HRESULT WINAPI device_manager_processor_service_GetVideoProcessorRenderTa
IDirectXVideoProcessorService
*
iface
,
REFGUID
deviceguid
,
const
DXVA2_VideoDesc
*
video_desc
,
UINT
*
count
,
D3DFORMAT
**
formats
)
{
FIXME
(
"%p, %s, %p, %p, %p.
\n
"
,
iface
,
debugstr_guid
(
deviceguid
),
video_desc
,
count
,
formats
);
TRACE
(
"%p, %s, %p, %p, %p.
\n
"
,
iface
,
debugstr_guid
(
deviceguid
),
video_desc
,
count
,
formats
);
if
(
IsEqualGUID
(
deviceguid
,
&
DXVA2_VideoProcSoftwareDevice
))
{
/* FIXME: filter some input formats */
if
(
!
(
*
formats
=
CoTaskMemAlloc
(
2
*
sizeof
(
**
formats
))))
return
E_OUTOFMEMORY
;
*
count
=
2
;
(
*
formats
)[
0
]
=
D3DFMT_X8R8G8B8
;
(
*
formats
)[
1
]
=
D3DFMT_A8R8G8B8
;
return
S_OK
;
}
else
FIXME
(
"Unsupported device %s.
\n
"
,
debugstr_guid
(
deviceguid
));
return
E_NOTIMPL
;
}
...
...
dlls/dxva2/tests/Makefile.in
View file @
97136a87
TESTDLL
=
dxva2.dll
IMPORTS
=
dxva2 user32 d3d9
IMPORTS
=
dxva2 user32 d3d9
ole32
C_SRCS
=
\
dxva2.c
dlls/dxva2/tests/dxva2.c
View file @
97136a87
...
...
@@ -82,13 +82,16 @@ static void test_device_manager(void)
IDirectXVideoProcessorService
*
processor_service
;
IDirectXVideoAccelerationService
*
accel_service
;
IDirect3DDevice9
*
device
,
*
device2
,
*
device3
;
IDirectXVideoProcessorService
*
proc_service
;
IDirect3DDeviceManager9
*
manager
;
IDirect3DSurface9
*
surfaces
[
2
];
DXVA2_VideoDesc
video_desc
;
int
refcount
,
refcount2
;
HANDLE
handle
,
handle1
;
D3DFORMAT
*
formats
;
UINT
token
,
count
;
IDirect3D9
*
d3d
;
HWND
window
;
UINT
token
;
HRESULT
hr
;
RECT
rect
;
...
...
@@ -297,6 +300,24 @@ static void test_device_manager(void)
IDirectXVideoAccelerationService_Release
(
accel_service
);
/* RT formats. */
hr
=
DXVA2CreateVideoService
(
device
,
&
IID_IDirectXVideoProcessorService
,
(
void
**
)
&
proc_service
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
memset
(
&
video_desc
,
0
,
sizeof
(
video_desc
));
video_desc
.
SampleWidth
=
64
;
video_desc
.
SampleHeight
=
64
;
video_desc
.
Format
=
D3DFMT_A8R8G8B8
;
count
=
0
;
hr
=
IDirectXVideoProcessorService_GetVideoProcessorRenderTargets
(
proc_service
,
&
DXVA2_VideoProcSoftwareDevice
,
&
video_desc
,
&
count
,
&
formats
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
ok
(
count
,
"Unexpected format count %u.
\n
"
,
count
);
CoTaskMemFree
(
formats
);
IDirectXVideoProcessorService_Release
(
proc_service
);
hr
=
IDirect3DDeviceManager9_OpenDeviceHandle
(
manager
,
&
handle
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
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