[FFmpeg-user] YouTube streaming of a static image...

James Darnley james.darnley at gmail.com
Sat Feb 10 01:50:29 EET 2018


On 2018-02-09 16:20, Carl Eugen Hoyos wrote:
> 2018-02-09 16:09 GMT+01:00 Paul B Mahol <onemda at gmail.com>:
>> On 2/9/18, Carl Eugen Hoyos <ceffmpeg at gmail.com> wrote:
>>> 2018-02-08 14:17 GMT+01:00 Gyan Doshi <gyandoshi at gmail.com>:
>>>
>>>> The (input) option for this is -stream_loop.
>>>
>>> If the input is an image (as in this case), "-loop 1" is the better option,
>>> as you wrote in your mail, "stream_loop" is a hack and sometimes
>>> has issues.
>>> (May need -shortest)
>>
>> You should really use loop filter as it will decode image only once.
> 
> That sounds like a much better solution, thanks!

I'm not so sure.  The original message has this paragraph:
> This image usually don't change but from times to times it might change
> and of course the stream must refresh/update it...

The image should be opened, decoded, and closed for every frame so that
changes will be seen in the output stream.

An optimised solution might check for changes in file modify time or
watch for changes with a platform specific feature.  I don't think
either of these are present in ffmpeg.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 603 bytes
Desc: OpenPGP digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-user/attachments/20180210/f3af2a0c/attachment.sig>


More information about the ffmpeg-user mailing list