Eric0321 wrote: 
> It played after adding that argument.  I also changed the transcode
> setting back to native within the advanced LMS settings.

> If you don't mind, for my own curiosity, why does this work with that
> flag?  Thanks!!!! :cool:
This is long explanation and my understanding but it may have

MEPG-4 is a flexible but complex transport format so there are many ways
of laying out data in a file - an MPEG4 file is made up of data "atoms".
If a file is played by an application which has access to the file
(e.g. a PMP) then the application can jump anywhere in the file (e.g.
beginning , middle or end) without a problem.  A streaming player can
only play a file from beginning to end - it cannot jump to end of file
as file is streamed from first byte to last. 

AAC audio is organised in frames.  The start of each frame has to be
identified. In ADTS format (mainly used by HTTP AAC streams) this is
done by a special byte sequence at start of each frame.  In MPEG4
format, there is an index table with byte offset pointers for each
frame.  When ffmpeg is converting a file to create an MPEG-4 AAC file,
it builds the index table internally but outputs the audio data as it is
processed in the "mdat" atom. When all the input file is process, ffmpeg
then write the index table (and other data) at the end of the file in a
"moov" atom.  A file based player can play this file because it can
easily jump to end of file to the index, fetch the index and then find
the audio frames to be played.  A streaming player gets the audio first,
doesn't know where the frames begin and so halts.

The "-movflags faststart" option make ffmpeg do a second pass on
converted file and move the audio data to end of the file so that a
streaming player can gets and reads the index table first and then when
audio data arrives next, the streaming player knows where the frames

Other data such as embedded cover art could also be positioned at the
end and this may cause problems to a streaming player.

bpa's Profile:
View this thread:

unix mailing list

Reply via email to