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
8173d3b0
Commit
8173d3b0
authored
Aug 16, 2023
by
Zhiyi Zhang
Committed by
Alexandre Julliard
Feb 06, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mf: Add a session_flush_nodes() helper.
Signed-off-by:
Zhiyi Zhang
<
zzhang@codeweavers.com
>
parent
a00b30bf
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
16 deletions
+14
-16
session.c
dlls/mf/session.c
+14
-16
No files found.
dlls/mf/session.c
View file @
8173d3b0
...
...
@@ -912,6 +912,19 @@ static HRESULT session_subscribe_sources(struct media_session *session)
return
hr
;
}
static
void
session_flush_nodes
(
struct
media_session
*
session
)
{
struct
topo_node
*
node
;
LIST_FOR_EACH_ENTRY
(
node
,
&
session
->
presentation
.
nodes
,
struct
topo_node
,
entry
)
{
if
(
node
->
type
==
MF_TOPOLOGY_OUTPUT_NODE
)
IMFStreamSink_Flush
(
node
->
object
.
sink_stream
);
else
if
(
node
->
type
==
MF_TOPOLOGY_TRANSFORM_NODE
)
IMFTransform_ProcessMessage
(
node
->
object
.
transform
,
MFT_MESSAGE_COMMAND_FLUSH
,
0
);
}
}
static
void
session_start
(
struct
media_session
*
session
,
const
GUID
*
time_format
,
const
PROPVARIANT
*
start_position
)
{
struct
media_source
*
source
;
...
...
@@ -2879,7 +2892,6 @@ static void session_set_source_object_state(struct media_session *session, IUnkn
struct
media_source
*
src
;
struct
media_sink
*
sink
;
enum
object_state
state
;
struct
topo_node
*
node
;
BOOL
changed
=
FALSE
;
DWORD
i
,
count
;
HRESULT
hr
;
...
...
@@ -2975,21 +2987,7 @@ static void session_set_source_object_state(struct media_session *session, IUnkn
if
(
!
session_is_source_nodes_state
(
session
,
OBJ_STATE_STOPPED
))
break
;
LIST_FOR_EACH_ENTRY
(
node
,
&
session
->
presentation
.
nodes
,
struct
topo_node
,
entry
)
{
switch
(
node
->
type
)
{
case
MF_TOPOLOGY_OUTPUT_NODE
:
IMFStreamSink_Flush
(
node
->
object
.
sink_stream
);
break
;
case
MF_TOPOLOGY_TRANSFORM_NODE
:
IMFTransform_ProcessMessage
(
node
->
object
.
transform
,
MFT_MESSAGE_COMMAND_FLUSH
,
0
);
break
;
default:
;
}
}
session_flush_nodes
(
session
);
session_set_caps
(
session
,
session
->
caps
&
~
MFSESSIONCAP_PAUSE
);
if
(
session
->
presentation
.
flags
&
SESSION_FLAG_FINALIZE_SINKS
)
...
...
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