1
0
Fork 0
mirror of synced 2025-03-07 03:53:26 +01:00

mf: Only preroll when starting from stopped state.

Stream sink such as evr can't be prerolled a second time, and when we are
restarting from a paused state, those stream sink will already be prerolled
so don't preroll them again. Otherwise we will be waiting for Prerolled
events that will never come.
This commit is contained in:
Yuxuan Shui 2024-02-07 15:38:26 +00:00 committed by Alexandre Julliard
parent 51b6a0fe12
commit 97d4c7fe3f

View file

@ -2979,7 +2979,7 @@ static void session_set_source_object_state(struct media_session *session, IUnkn
return;
}
if (session->presentation.flags & SESSION_FLAG_NEEDS_PREROLL)
if ((session->presentation.flags & SESSION_FLAG_NEEDS_PREROLL) && session_is_output_nodes_state(session, OBJ_STATE_STOPPED))
{
MFTIME preroll_time = 0;