Hello, Im trying to encode ...Hello, Im trying to encode videos to high quality and bandwidth friendly mp4 video (h.264) , the point is also to make them pseudo-streamable with the lighttpd h.264 module.
I'm using ffmpeg command:
ffmpeg -i start.avi -s 640:352 -acodec libfaac -ab 32k -ac 1 -vcodec libx264 -aspect 16:9 -vpre hq -crf 22 -threads 0 end.mp4The video is a mythbusters episode
After that, I tried doing the whole moov atom moving with MP4Box
MP4Box
MP4Box -inter 500 final.mp4
Then I added the player to a website and tried to play it, the video took around 1 30 seconds to even start to play, however after it started to play the video played fine with no stuttering, however, these 30 seconds are misleading. Can anyone help?
Thanks!



From the MP4box documentation here: http://gpac.sourceforge.net/doc_mp4box.php
As of version 0.2.4, MP4Box always stores the file with 0.5 second interleaving and meta-data at the begining, making it suitable for HTTP streaming.
-inter Duration : interleaves media data in chunks of desired duration (in seconds). This is usefull to optimize the file for HTTP/FTP streaming or reducing disk access. All meta data are placed first in the file, allowing a player to start playback while downloading the content. By default MP4Box always stores files with half a second interleaving and performs drift checking between tracks while interleaving. Specifying a 0 interleaving time will result in the file being stored without interleaving, with all meta-data placed at beginning of the file.
So, use:
MP4Box end.mp4