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
6548fc43
Commit
6548fc43
authored
Jun 18, 2020
by
Nikolay Sivov
Committed by
Alexandre Julliard
Jun 18, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
evr: Add IMFVideoMixerControl2 stub for the mixer.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
68374e43
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
129 additions
and
0 deletions
+129
-0
mixer.c
dlls/evr/mixer.c
+87
-0
evr.c
dlls/evr/tests/evr.c
+4
-0
evr.idl
include/evr.idl
+38
-0
No files found.
dlls/evr/mixer.c
View file @
6548fc43
...
@@ -41,6 +41,7 @@ struct video_mixer
...
@@ -41,6 +41,7 @@ struct video_mixer
IMFTransform
IMFTransform_iface
;
IMFTransform
IMFTransform_iface
;
IMFVideoDeviceID
IMFVideoDeviceID_iface
;
IMFVideoDeviceID
IMFVideoDeviceID_iface
;
IMFTopologyServiceLookupClient
IMFTopologyServiceLookupClient_iface
;
IMFTopologyServiceLookupClient
IMFTopologyServiceLookupClient_iface
;
IMFVideoMixerControl2
IMFVideoMixerControl2_iface
;
LONG
refcount
;
LONG
refcount
;
struct
input_stream
inputs
[
MAX_MIXER_INPUT_STREAMS
];
struct
input_stream
inputs
[
MAX_MIXER_INPUT_STREAMS
];
...
@@ -64,6 +65,11 @@ static struct video_mixer *impl_from_IMFTopologyServiceLookupClient(IMFTopologyS
...
@@ -64,6 +65,11 @@ static struct video_mixer *impl_from_IMFTopologyServiceLookupClient(IMFTopologyS
return
CONTAINING_RECORD
(
iface
,
struct
video_mixer
,
IMFTopologyServiceLookupClient_iface
);
return
CONTAINING_RECORD
(
iface
,
struct
video_mixer
,
IMFTopologyServiceLookupClient_iface
);
}
}
static
struct
video_mixer
*
impl_from_IMFVideoMixerControl2
(
IMFVideoMixerControl2
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
struct
video_mixer
,
IMFVideoMixerControl2_iface
);
}
static
int
video_mixer_compare_input_id
(
const
void
*
a
,
const
void
*
b
)
static
int
video_mixer_compare_input_id
(
const
void
*
a
,
const
void
*
b
)
{
{
const
unsigned
int
*
key
=
a
;
const
unsigned
int
*
key
=
a
;
...
@@ -104,6 +110,11 @@ static HRESULT WINAPI video_mixer_transform_QueryInterface(IMFTransform *iface,
...
@@ -104,6 +110,11 @@ static HRESULT WINAPI video_mixer_transform_QueryInterface(IMFTransform *iface,
{
{
*
obj
=
&
mixer
->
IMFTopologyServiceLookupClient_iface
;
*
obj
=
&
mixer
->
IMFTopologyServiceLookupClient_iface
;
}
}
else
if
(
IsEqualIID
(
riid
,
&
IID_IMFVideoMixerControl2
)
||
IsEqualIID
(
riid
,
&
IID_IMFVideoMixerControl
))
{
*
obj
=
&
mixer
->
IMFVideoMixerControl2_iface
;
}
else
else
{
{
WARN
(
"Unsupported interface %s.
\n
"
,
debugstr_guid
(
riid
));
WARN
(
"Unsupported interface %s.
\n
"
,
debugstr_guid
(
riid
));
...
@@ -564,6 +575,81 @@ static const IMFTopologyServiceLookupClientVtbl video_mixer_service_client_vtbl
...
@@ -564,6 +575,81 @@ static const IMFTopologyServiceLookupClientVtbl video_mixer_service_client_vtbl
video_mixer_service_client_ReleaseServicePointers
,
video_mixer_service_client_ReleaseServicePointers
,
};
};
static
HRESULT
WINAPI
video_mixer_control_QueryInterface
(
IMFVideoMixerControl2
*
iface
,
REFIID
riid
,
void
**
obj
)
{
struct
video_mixer
*
mixer
=
impl_from_IMFVideoMixerControl2
(
iface
);
return
IMFTransform_QueryInterface
(
&
mixer
->
IMFTransform_iface
,
riid
,
obj
);
}
static
ULONG
WINAPI
video_mixer_control_AddRef
(
IMFVideoMixerControl2
*
iface
)
{
struct
video_mixer
*
mixer
=
impl_from_IMFVideoMixerControl2
(
iface
);
return
IMFTransform_AddRef
(
&
mixer
->
IMFTransform_iface
);
}
static
ULONG
WINAPI
video_mixer_control_Release
(
IMFVideoMixerControl2
*
iface
)
{
struct
video_mixer
*
mixer
=
impl_from_IMFVideoMixerControl2
(
iface
);
return
IMFTransform_Release
(
&
mixer
->
IMFTransform_iface
);
}
static
HRESULT
WINAPI
video_mixer_control_SetStreamZOrder
(
IMFVideoMixerControl2
*
iface
,
DWORD
stream_id
,
DWORD
zorder
)
{
FIXME
(
"%p, %u, %u.
\n
"
,
iface
,
stream_id
,
zorder
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
video_mixer_control_GetStreamZOrder
(
IMFVideoMixerControl2
*
iface
,
DWORD
stream_id
,
DWORD
*
zorder
)
{
FIXME
(
"%p, %u, %p.
\n
"
,
iface
,
stream_id
,
zorder
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
video_mixer_control_SetStreamOutputRect
(
IMFVideoMixerControl2
*
iface
,
DWORD
stream_id
,
const
MFVideoNormalizedRect
*
rect
)
{
FIXME
(
"%p, %u, %p.
\n
"
,
iface
,
stream_id
,
rect
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
video_mixer_control_GetStreamOutputRect
(
IMFVideoMixerControl2
*
iface
,
DWORD
stream_id
,
MFVideoNormalizedRect
*
rect
)
{
FIXME
(
"%p, %u, %p.
\n
"
,
iface
,
stream_id
,
rect
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
video_mixer_control_SetMixingPrefs
(
IMFVideoMixerControl2
*
iface
,
DWORD
flags
)
{
FIXME
(
"%p, %#x.
\n
"
,
iface
,
flags
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
video_mixer_control_GetMixingPrefs
(
IMFVideoMixerControl2
*
iface
,
DWORD
*
flags
)
{
FIXME
(
"%p, %p.
\n
"
,
iface
,
flags
);
return
E_NOTIMPL
;
}
static
const
IMFVideoMixerControl2Vtbl
video_mixer_control_vtbl
=
{
video_mixer_control_QueryInterface
,
video_mixer_control_AddRef
,
video_mixer_control_Release
,
video_mixer_control_SetStreamZOrder
,
video_mixer_control_GetStreamZOrder
,
video_mixer_control_SetStreamOutputRect
,
video_mixer_control_GetStreamOutputRect
,
video_mixer_control_SetMixingPrefs
,
video_mixer_control_GetMixingPrefs
,
};
HRESULT
WINAPI
MFCreateVideoMixer
(
IUnknown
*
owner
,
REFIID
riid_device
,
REFIID
riid
,
void
**
obj
)
HRESULT
WINAPI
MFCreateVideoMixer
(
IUnknown
*
owner
,
REFIID
riid_device
,
REFIID
riid
,
void
**
obj
)
{
{
TRACE
(
"%p, %s, %s, %p.
\n
"
,
owner
,
debugstr_guid
(
riid_device
),
debugstr_guid
(
riid
),
obj
);
TRACE
(
"%p, %s, %s, %p.
\n
"
,
owner
,
debugstr_guid
(
riid_device
),
debugstr_guid
(
riid
),
obj
);
...
@@ -589,6 +675,7 @@ HRESULT evr_mixer_create(IUnknown *outer, void **out)
...
@@ -589,6 +675,7 @@ HRESULT evr_mixer_create(IUnknown *outer, void **out)
object
->
IMFTransform_iface
.
lpVtbl
=
&
video_mixer_transform_vtbl
;
object
->
IMFTransform_iface
.
lpVtbl
=
&
video_mixer_transform_vtbl
;
object
->
IMFVideoDeviceID_iface
.
lpVtbl
=
&
video_mixer_device_id_vtbl
;
object
->
IMFVideoDeviceID_iface
.
lpVtbl
=
&
video_mixer_device_id_vtbl
;
object
->
IMFTopologyServiceLookupClient_iface
.
lpVtbl
=
&
video_mixer_service_client_vtbl
;
object
->
IMFTopologyServiceLookupClient_iface
.
lpVtbl
=
&
video_mixer_service_client_vtbl
;
object
->
IMFVideoMixerControl2_iface
.
lpVtbl
=
&
video_mixer_control_vtbl
;
object
->
refcount
=
1
;
object
->
refcount
=
1
;
object
->
input_count
=
1
;
object
->
input_count
=
1
;
video_mixer_init_input
(
&
object
->
inputs
[
0
]);
video_mixer_init_input
(
&
object
->
inputs
[
0
]);
...
...
dlls/evr/tests/evr.c
View file @
6548fc43
...
@@ -362,6 +362,10 @@ static void test_default_mixer(void)
...
@@ -362,6 +362,10 @@ static void test_default_mixer(void)
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
IUnknown_Release
(
unk
);
IUnknown_Release
(
unk
);
hr
=
IMFTransform_QueryInterface
(
transform
,
&
IID_IMFVideoMixerControl
,
(
void
**
)
&
unk
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
IUnknown_Release
(
unk
);
hr
=
IMFTransform_QueryInterface
(
transform
,
&
IID_IMFVideoDeviceID
,
(
void
**
)
&
deviceid
);
hr
=
IMFTransform_QueryInterface
(
transform
,
&
IID_IMFVideoDeviceID
,
(
void
**
)
&
deviceid
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
...
...
include/evr.idl
View file @
6548fc43
...
@@ -160,4 +160,42 @@ interface IMFVideoDeviceID : IUnknown
...
@@ -160,4 +160,42 @@ interface IMFVideoDeviceID : IUnknown
)
;
)
;
}
}
[
object
,
uuid
(
a5c6c53f
-
c202
-
4
aa5
-
9695
-
175b
a8c508a5
)
]
interface
IMFVideoMixerControl
:
IUnknown
{
HRESULT
SetStreamZOrder
(
[
in
]
DWORD
stream_id
,
[
in
]
DWORD
zorder
)
;
HRESULT
GetStreamZOrder
(
[
in
]
DWORD
stream_id
,
[
out
]
DWORD
*
zorder
)
;
HRESULT
SetStreamOutputRect
(
[
in
]
DWORD
stream_id
,
[
in
]
const
MFVideoNormalizedRect
*
rect
)
;
HRESULT
GetStreamOutputRect
(
[
in
]
DWORD
stream_id
,
[
out
]
MFVideoNormalizedRect
*
rect
)
;
}
[
object
,
uuid
(
8459616d-966
e
-
4930
-
b658
-
54
fa7e5a16d3
)
]
interface
IMFVideoMixerControl2
:
IMFVideoMixerControl
{
HRESULT
SetMixingPrefs
(
[
in
]
DWORD
flags
)
;
HRESULT
GetMixingPrefs
(
[
out
]
DWORD
*
flags
)
;
}
cpp_quote
(
"HRESULT WINAPI MFCreateVideoMixer(IUnknown *owner, REFIID riid_device, REFIID riid, void **obj);"
)
cpp_quote
(
"HRESULT WINAPI MFCreateVideoMixer(IUnknown *owner, REFIID riid_device, REFIID riid, void **obj);"
)
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