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
baa97389
Commit
baa97389
authored
Apr 21, 2021
by
Nikolay Sivov
Committed by
Alexandre Julliard
Apr 21, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mfplay: Create video output branches.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
78c35d34
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
player.c
dlls/mfplay/player.c
+9
-9
No files found.
dlls/mfplay/player.c
View file @
baa97389
...
...
@@ -1043,29 +1043,23 @@ static HRESULT media_item_create_sink_node(IUnknown *sink, IMFTopologyNode **nod
static
HRESULT
media_item_create_topology
(
struct
media_player
*
player
,
struct
media_item
*
item
,
IMFTopology
**
out
)
{
IMFTopologyNode
*
src_node
,
*
sink_node
;
BOOL
selected
,
video_added
=
FALSE
;
IMFStreamDescriptor
*
sd
;
IMFTopology
*
topology
;
unsigned
int
idx
;
IUnknown
*
sink
;
BOOL
selected
;
HRESULT
hr
;
GUID
major
;
if
(
FAILED
(
hr
=
MFCreateTopology
(
&
topology
)))
return
hr
;
/* Use first stream if none selected. */
if
(
player
->
output_window
)
{
FIXME
(
"Video streams are not handled.
\n
"
);
}
/* Set up branches for all selected streams. */
idx
=
0
;
while
(
SUCCEEDED
(
IMFPresentationDescriptor_GetStreamDescriptorByIndex
(
item
->
pd
,
idx
++
,
&
selected
,
&
sd
)))
{
if
(
!
selected
)
if
(
!
selected
||
FAILED
(
media_item_get_stream_type
(
sd
,
&
major
))
)
{
IMFStreamDescriptor_Release
(
sd
);
continue
;
...
...
@@ -1077,11 +1071,17 @@ static HRESULT media_item_create_topology(struct media_player *player, struct me
{
/* User sink is attached as-is. */
}
else
if
(
SUCCEEDED
(
media_item_get_stream_type
(
sd
,
&
major
))
&&
IsEqualGUID
(
&
major
,
&
MFMediaType_Audio
))
else
if
(
IsEqualGUID
(
&
major
,
&
MFMediaType_Audio
))
{
if
(
FAILED
(
hr
=
MFCreateAudioRendererActivate
((
IMFActivate
**
)
&
sink
)))
WARN
(
"Failed to create SAR activation object, hr %#x.
\n
"
,
hr
);
}
else
if
(
IsEqualGUID
(
&
major
,
&
MFMediaType_Video
)
&&
player
->
output_window
&&
!
video_added
)
{
if
(
FAILED
(
hr
=
MFCreateVideoRendererActivate
(
player
->
output_window
,
(
IMFActivate
**
)
&
sink
)))
WARN
(
"Failed to create EVR activation object, hr %#x.
\n
"
,
hr
);
video_added
=
SUCCEEDED
(
hr
);
}
if
(
sink
)
{
...
...
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