[vlc-devel] [PATCH 2/8] sout_mux/core: handle drain

Rémi Denis-Courmont remi at remlab.net
Mon Jan 29 19:33:08 CET 2018

Le maanantaina 29. tammikuuta 2018, 19.25.50 EET Thomas Guillem a écrit :
> Like for decoder_t, a drain is requested when sending/writing a NULL block.
> Muxers should drain themselves when they receive the last pf_delstream
> callback (call the new sout_MuxIsDrained() helper to know when it happens).

I do not agree there. If it is possible to add and remove ES's dynamically, it 
should be possible to remove all of them, then add new ones. This is neither 
sufficient nor necessary a condition to drain the muxer.

Muxers should "drain" up to the PCR, regardless of any ES or even the whole 
stream ending. Of course, that requires passing the PCR (or its translation) 
to the stream outputs and muxers.


More information about the vlc-devel mailing list