<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
p, li { white-space: pre-wrap; }
</style></head><body style=" font-family:'Noto Sans'; font-size:10pt; font-weight:400; font-style:normal;">
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">Hello,</p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">This is Kdenlive list, not FFmpeg one :-\</p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">A quick search on internet :</p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">https://video.stackexchange.com/questions/12905/repeat-loop-input-video-with-ffmpeg</p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">"The <span style=" font-family:'Hack';">-loop</span> option is specific to the <a href="https://ffmpeg.org/ffmpeg-formats.html#image2-1"><span style=" text-decoration: underline; color:#508ed8;">image file demuxer</span></a> and <a href="https://ffmpeg.org/ffmpeg-formats.html#gif-2"><span style=" text-decoration: underline; color:#508ed8;">gif muxer"</span></a></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">stream_loop seems to be a read option, not an output flag...</p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">So it doesn't seem to fit your need :(</p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">Good luck, let us know if you find a solution...</p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">Vincent</p>
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; "> </p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">Le jeudi 11 janvier 2018, 17:19:38 CET Vikram Parmar a écrit :<br /></p>
<p style=" margin-top:12px; margin-bottom:0px; margin-left:40px; margin-right:40px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">Hi,<br /><br />Is it possible to add some custom atom in the header of a video file?<br /><br />I need to add the term "loop" in the header of MP4 files before the "moov" atom.<br /><br />More information can be found here :<br /><br /><a href="https://stackoverflow.com/questions/44893316/whatsapp-video-as-gif-sharing-on-android-programatically"><span style=" text-decoration: underline; color:#508ed8;">https://stackoverflow.com/questions/44893316/whatsapp-video-as-gif-sharing-on-android-programatically</span></a><br /><br />Note: Just opening the video file using any text editor shows the file header and atoms.<br /><br />I do not want to edit the headers via too much calculations, as the answer suggests. Is there a simple FFMPEG command to add the atom "loop" to any MP4 files?<br /><br />Use Case :-<br /><br />WhatsApp does a smart thing. Their animated GIFs are actually MP4 files (which contain this atom "loop"), and the MP4 files which it wants to treat as videos in their UI, they do not add that "loop" atom<br /><br />I tried loads of -loop and stream loop commands.. Nothing is adding the atom "loop" to my mp4 files<br /><br />My current command for converting a GIF to MP4 is as follows :<br /><br /></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:46px; margin-right:40px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;">ffmpeg -i giphy9.gif -c:v libx264 -c:a aac -pix_fmt yuv420p -movflags +faststart  giphy9_loop.mp4<br /></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;"><br />I wish to add some parameter to the above command (or maybe run a separate command) so that the output mp4 file has that "loop" atom in the header. <br /><br />Please help!</p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:40px; margin-right:40px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;"><br /></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; -qt-user-state:0;"><br /><br /></p></body></html>