[libav-api] Moov Atom
mark.kenna at sureviewsystems.com
Mon Mar 21 17:42:45 CET 2011
On 21/03/2011 14:31, Luca Barbato wrote:
> On 03/21/2011 03:07 PM, Mark Kenna wrote:
>> On 18/03/2011 17:45, Ronald S. Bultje wrote:
>>> On Fri, Mar 18, 2011 at 12:52 PM, Mark Kenna
>>> <mark.kenna at sureviewsystems.com> wrote:
>>>> Can someone tell me if FFMpeg can position the MOOV atom of a MP4
>>>> at the beginning of the file? I am trying to stream MP4 to
>>>> Silverlight as
>>>> it's being generated but it won't play because the MOOV atom is only
>>>> on av_write_trailer.
>>> qt-faststart moves it from back to front after writing the file has
>>> completed. The mov/mp4 muxer cannot write it at front itself. It could
>>> probably be modified to do that but it wouldn't work very well because
>>> the size of the atom can vary wildly and you'd need to reserve space
>>> at the front of the file to write it there at all. Reserving too much
>>> = waste of space, reserving too little, well, you can probably imagine
>>> yourself it wouldn't work at all.
>> I have a question which stems from the above explanation, how is MP4
>> supposed to be used a transport stream container for a potentially
>> endless stream if the MOOV atom is required and you have to specify the
>> length (which would be unknown). Surely someone has streamed H264 using
>> in MP4 with FFMpeg?
> No work had been done on this purpose so far, if there is really the
> need we could try to add this as muxer option to add a crafted moov with
> a time long enough.
> Probably we could add a generic segmentation option to provide segmented
> mpegts, mkv and mp4 for specific purposes.
This may be wandering slightly off topic but... If I were to use an
MPEG2 transport stream holding H264 video instead of MP4, that would
overcome the MOOV atom problem right? I would then face the problem of
not knowing how to play the stream in real time. Are there any web-based
technologies that you can pass real-time video data to directly and will
play it in real time?
I have looked at flash/silverlight based players but they all want to
use the standard protocols.
Thanks for your guidance,
More information about the libav-api