[Libav-user] How can i suspend ffmpeg's file reading?

René J.V. Bertin rjvbertin at gmail.com
Fri Dec 7 11:32:15 CET 2012

Hello Jack

How do you launch ffmpeg and on what os? If you have a process id for it, you could sigstop/suspend it while you wait for data, but that too would of course halt the playing. I've never tried, but I suspect that it would however resume playing when you sigcont/release the process.
Alternatively, buffer your stream, measuring download speed and expected bitrate during playback, so that you can launch ffmpeg only when you have downloaded enough content to be reasonably sure that you won't catch up with the download head. This is more or less how QuickTime handles streaming playback, but it isn't failure proof against net congestion or other unforeseen events.


Quy Pham Sy <phamsyquybk at gmail.com> wrote:

>My ffmpeg-based player plays a mpeg-ts file that downloaded from a
>I want my player be able to play the video file
>even when it is being downloaded.
>There is no problem if the download speed is faster than reading speed,
>otherwise, it just stop playing.
>My question is that is there anyway to suspend ffmpeg file reading to
>for data available to proceed?
>Libav-user mailing list
>Libav-user at ffmpeg.org

More information about the Libav-user mailing list