Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Compression Techniques Compressor: .mp4 file H264/AAC optimized both for RTMP and HTTP streaming ?

  • Compressor: .mp4 file H264/AAC optimized both for RTMP and HTTP streaming ?

    Posted by Paul Sellis on March 4, 2012 at 9:47 pm

    Hi,

    I am streaming movies from Amazon Web Service CloudFront.
    I use JW Player so I use RTMP streaming and when platform doesn’t support it (smartphones) it fallbacks to HTTP streaming.
    I encode movies with Apple Compressor in .mp4 and H264/AAC

    For now it’s OK with RTMP (PC web browsers) but it’s slow to start on my iPhone with HTTP streaming…
    I supposed that it was because there is no “fast start” on Compressor for the .mp4 presets.

    I tried a bad workaround: create a preset to encode a .mov file with fast start and change extension to .mp4 in Compressor a .mp4 the Compressor settings.
    It worked in HTTP streaming but not at all for RTMP (the file is not read at all)

    So is there a way to encode with Compressor to encode a .mp4 file H264/AAC optimized both for RTMP and HTTP streaming ?

    Thanks for your help
    Paul

    Craig Seeman replied 14 years, 2 months ago 4 Members · 18 Replies
  • 18 Replies
  • Paul Sellis

    March 6, 2012 at 11:11 pm

    [Paul Sellis] “I use JW Player so I use RTMP streaming and when platform doesn’t support it (smartphones) it fallbacks to HTTP streaming.”
    Oops… I should have said “… it fallback to HTML5”

    So my title of this post should be: “Compressor: .mp4 file H264/AAC optimized both for RTMP and HTML5 ?”

  • Andrew Stuckey

    March 7, 2012 at 1:38 am

    Hi Paul,

    I’m not entirely sure my advice will prepare video for both RTMP and HTML5, but at least test it out. At the very least you will no doubt get some improvements in picture quality.

    I can highly recommend using the x264 codec for H264/mp4 format video rather than Apple’s default H264 codec found in QT and Compressor. I’ve recently switched and seen far superior results.

    https://www003.upp.so-net.ne.jp/mycometg3/

    While it can be plugged into QT and Compressor, I’ve seen much better results when using x264 in third part software such as Handbrake and MPEG Streamclip. Mind you they seem to be a heck of a lot faster than Compressor too. So faster and better = good. 😀

    Handbrake (which uses x264 by default) has the option “Web Optimized”. When this is ticked
    the header of the MP4 file is rearranged to optimize it for streaming across the web.

    I’m not sure of the same option in MPEG Streamclip, but I’m sure it would have one.

    I’d suggest running a small test file through handbrake and see how it goes.

  • Paul Sellis

    March 7, 2012 at 1:47 pm

    Thanks for your answer Andrew

    I tried Handbrake but I saw that resulted file would be a .m4v instead of a .mp4
    I am pretty sure that manually changing file extension after encoding would break compatibility at least with RTMP…
    🙁

    Am I wrong ?

  • Craig Seeman

    March 7, 2012 at 3:46 pm

    Compressor 4 supports H.264 .mp4. Compressor 3 does not. It’s not clear which version you’re using.

    You can not change .mov to .mp4. The metadata is different and can cause issue with some systems.

    .m4v and .mp4 have the same metadata. You can change .m4v to .mp4.

    .mp4 does not need “fast start” since the moov atom is placed at the front where it’s needed, as part of the metadata.

  • Craig Seeman

    March 7, 2012 at 3:48 pm

    [Andrew Stuckey] “I can highly recommend using the x264 codec for H264/mp4 format video rather than Apple’s default H264 codec found in QT and Compressor. I’ve recently switched and seen far superior results.”

    Yes, x264 is leagues ahead of Apple’s H.264 codec. Apple is probably one of the least efficient H.264 codecs available. Both x264 and MainConcept (Episode, Squeeze, etc) will deliver better quality at lower bit rates.

  • Craig Seeman

    March 7, 2012 at 3:49 pm

    [Paul Sellis] “I am pretty sure that manually changing file extension after encoding would break compatibility at least with RTMP…
    🙁

    Am I wrong ?”

    m4v and mp4 have the same metadata. You can change the extension. You can’t do this with mov though.

  • Jason Brown

    March 7, 2012 at 4:41 pm

    How does this compare to the Matrox h264 encoder? Does it use it’s own, or apples codec?

  • Craig Seeman

    March 7, 2012 at 4:43 pm

    Matrox CompressHD and MXO2 MAX uses it’s own encoder. It’s blazing fast, has much deeper professional controls, looks excellent. I’d use it over Apple’s for all of the above reasons.

  • Paul Sellis

    March 7, 2012 at 5:54 pm

    I use Compressor 4

    I’ll try to change .m4v to .mp4 and see if there is any improvement with Handbrake encoded file

    ON Amazon CloudFront, I don’t have noticeable delay when played with RTMP. It’s only when played on smartphone with HTML5 (I tested on iPhone)…

  • Craig Seeman

    March 7, 2012 at 6:16 pm

    Compressor 4 creates H.264 .mp4. There’s no reason to change the extension. The .mp4 templates can be duplicated and modified unlike the .m4v for iOS devices. Look under the HTTP Live Streaming presets.

Page 1 of 2

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy