Skip navigation
Currently Being Moderated

Color Shifts when rendering to H.264 Blu-ray

Dec 22, 2010 12:05 PM

Since upgrading to After Effects CS5 I am seeing the following:

 

Whenever I render out a video file using the "H.264 Blu-ray" Output Module option, the resulting m4v video has a different color appearance than the After Effects composition from which it was rendered. The rendered file appears to have a yellow cast to it, especially evident in red highlights. This appearance is seen within After Effects (after importing the file and dropping it in a composition) as well as in VLC media player. In addition, a blu-ray disc created using the m4v file also has the yellow appearance when viewed on an HDTV. In other words, the color shift is consistant in various players as well as within After Effects itself.

 

Here is the bug report I submitted:

 

******BUG******
Concise problem statement:
Steps to reproduce bug:
1. Create a project with HDTV (Rec. 709) color space, 8 bit.
2. Import a 1920x1080 video file (any kind).
3. Render out to H.264 Blu-ray (using project color space).
4. Import the resulting m4v file and compare it to the original video.
Results: The color has been shifted; has a yellow cast to it.
Expected results: the color should appear the same for the rendered file as the original.

 
Replies
  • Currently Being Moderated
    Dec 28, 2010 11:06 PM   in reply to FrankinMD

    This is a user-to-user forum. If Adobe employees answer questions here, they are doing so on their free time. Also, virtually all of the Adobe employees are on a holiday break right now.  If you want a guaranteed immediate answer from an Adobe employee, you can contact Technical Support:

    http://www.adobe.com/support/contact/

     
    |
    Mark as:
  • Currently Being Moderated
    Dec 29, 2010 6:36 AM   in reply to FrankinMD

    For the record, I never render H.264 from After Effects. Actually, I very rarely render any sort of compression with AE. I render a lossless file then use a different program (Adobe Media Encoder) to encode the final file. After Effects, because of the way it works frame by frame to render, can't do multipass compression. Multipass compression gets better-looking files at smaller file sizes.

     

    My suggested workflow would be to render uncompressed out of AE and compress using some other software.

     
    |
    Mark as:
  • Currently Being Moderated
    Jan 19, 2011 2:48 PM   in reply to FrankinMD

    FrankinMD wrote:

     

    I'm still trying to get an answer to this question.

     

    Well, here's my answer: it's time for Plan B.

     

    The reason: AE renders one frame at a time, making it incapable of multipass encoding.  In a long-gop codec like H.264, multipass encoding can greatly improve image quality.  I'm with Szalam on this score -- if I were doing serious work, I'd never consider rendering in H.264.  What if you need a quick 'n dirty, small-size file to show your progress to a client?  It'll do.

     

    Furthermore, H.264 is a DELIVERY codec; a final-use codec.  It won't withstand re-rendering without losing image quality.  What if you suddenly learn you need a copy of your AE render in.... oh, say, ProRes 422?  If all you have is an H.264 file, you'll have to live with the hit in image quality.  So again, I'm with Szalam in rendering in a lossless or uncompressed codec, and THEN compressing for delivery.

     

    I can't answer your question about H.264 color directly, but I know that a couple of other AE & H.264 shortcomings make it a less-than-ideal codec choice when rendering For The Ages.

     
    |
    Mark as:
  • Currently Being Moderated
    Jan 19, 2011 4:26 PM   in reply to FrankinMD

    I can assure you this isn't a widespread problem as I've rendered a  fair amount of h.264 directly out of AE and haven't noticed it. Nor have I heard anything from our testing department.

     

    I would still like to know what is happening with the H.264 color in  After Effects, and I have the feeling some people are using AE to encode  to it and don't realize what it is doing to their color. It would be  nice if it were a known, rather than a hidden, issue (if it is an  issue).

     

    Well, it really depends how you've configured ae for rendering, what OS version and platform you are on, and if you are using Color Management or not. If you don't have color management enabled, after effects assumes you are working in Rec709 RGB full swing and does a conversion to Rec709 YCrCb 16-235 and then compresses there. We use the transfer functions as defined in the h.264 specification in this case. Different players make different assumptions about converting from Rec709 into display, generally doing nothing.

     

    It's a whole different can of worms If you have color management enabled. For instance if you've color profiled your monitor, color correct in AE with CM on, render to h.264, and they play that in a non-color managed workflow, you may see some color shifting. That's because your monitor is shifted and AE was correcting for it in our comp window, but the h.264 player isn't correcting for the fact that your display isn't Rec709.

     

    --chris

    After Effects Engineering Manager

     
    |
    Mark as:
  • Currently Being Moderated
    Jan 19, 2011 7:38 PM   in reply to FrankinMD

    Just an addition to your conversation.

     

    I have been rendering video to h264 for awhile from many different software packages. ffmpeg / quicktime pro / ae / etc. I've always noticed the color was a little less saturated in the final render. Particularly annoying when I had to overlay video over a still image and the two didn't match in color.

     

    When I use AE, I never export directly from it. Do you not use Adobe Media Encoder? You can open up an After Effects project up in it, choose your sequences, and have way more control over compression settings. You can also queue up many different profiles for the same item. Crucial when you need to troubleshoot / try different encode settings.

     
    |
    Mark as:
  • Currently Being Moderated
    Jan 20, 2011 1:18 PM   in reply to FrankinMD

    FrankinMD wrote:

    When rendering For The Ages, it's hard to pick something that will be one size fits all, since you don't always know what frame size (for example) you will want your delivery format to be, so even a lossless AVI might need to be rendered again before encoding.

     

    True.  but you lose no image quality when you convert that lossless AVI to something else; you only lose what you choose to throw away by encoding to a different codec and size.

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 14, 2012 10:01 AM   in reply to FrankinMD

    Hi Frankin,

     

    Did you solved the problem in the meanwhile (yellow tint on export) ?

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 14, 2012 12:37 PM   in reply to FrankinMD

    Damn, could you say with third party software you use ? It would help me a lot

    I will use the same workflow than.

     
    |
    Mark as:
  • A.I.1
    36 posts
    Feb 20, 2012
    Currently Being Moderated
    Apr 14, 2012 11:33 PM   in reply to FrankinMD

    I did a test converting to H.264/Blu-ray (default settings) in AE CS5.5.

    colour-test-solids.png

    The coloured solids at the top are original, and the ones on the bottom are H264 Blu-ray compressed (from within AE CS5.5), imported back in to the AE5.5 composition.  Colour management is off.

     

    White/Greyscale turned out the same (ie. blocks that were RGB 255,255,255 stayed like that.  Same for blocks 128,128,128 and 200,200,200).

     

    The red was originally 200,0,0.  After conversion to H264 Blu-ray, the red block is 218, 19, 0 (according to AE CS5.5's Info Panel)

    The green was originally 0,200,0.  After conversion to H264 Blu-ray, green was 0,170,0.

    The blue was originally 0,0,200.  After conversion to H264 Blu-ray, blue was 0,12,210.

     

    No motion for the blocks shown.

     

    Render settings

    quality best

    format h.264 blu-ray

    channels RGB

    depth: millions of colors

    colour: premultiplied (matted)

    mainconcept h.264 20.00 Mbps

    default options (high, 4.1, vbr1, 20 target bitrate, max 24 bitrate)

     

    AE CS5.5.  Windows 7.  Project settings: 8 bits per colour channel.

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 15, 2012 12:08 AM   in reply to A.I.1

    I just did a test myself.

     

    Mac Book Pro, OS X Lion, After Effects CS 5.5 (10.5.0.253)

     

    Project Settings:

     

    Screen Shot 2012-04-15 at 4.57.42 PM.png

     

     

    Rendered using the H.264 for BluRay Output Module, then reimported file, laid one on top of other, masked the upper half out, so upper area of pic is native content, lower half is H.264 file.  You can see where the mask occurs by looking at the blue lines to left and right of the comp.

     

    There is no difference in any of the colours - they all match up perfectly.

     

    Screen Shot 2012-04-15 at 4.53.09 PM.png

     

    Overlaying one image over the other in Difference mode demonstrates how little the files differ: a little edging due to compression artifacts, but basically no difference in the file colours whatsover.  There are occasional variances of just one or two RGB points in any of the colour channels, but these can probably be explained by compression/banding issues.

     

    Screen Shot 2012-04-15 at 5.04.28 PM.png

     

     

    Are you certain you have all colour management turned off in After Effects?

     
    |
    Mark as:
  • A.I.1
    36 posts
    Feb 20, 2012
    Currently Being Moderated
    Apr 15, 2012 1:36 AM   in reply to Andrew Yoole

    Andrew Yoole wrote:

     

    Are you certain you have all colour management turned off in After Effects?

    It says it's off in Project Settings.  In Preferences->Previews there's 3 options for it (none of which say off - ie. they say Faster / more Accurate except ram preview / More Accurate).  Anyway it seems to give the same RGB values with each option of preview (ie. the red, green & blue coloured solids still show a different value after H264 Blu-ray compression.  I also tried turning OpenGL off for previews and it gave the results shown above too.  In the Output Module it also says colour management is off.  Exporting as uncompressed AVI instead of H264 Blu-ray gives identical RGB values as the source.

    project-settings.jpg

    output-settings.jpg

     
    |
    Mark as:
  • A.I.1
    36 posts
    Feb 20, 2012
    Currently Being Moderated
    Apr 15, 2012 2:39 AM   in reply to Andrew Yoole

    Andrew Yoole wrote:

     

    I just did a test myself.

     

    Mac Book Pro, OS X Lion, After Effects CS 5.5 (10.5.0.253)

    Could it be anything to do with Mac vs PC?

    Outputting as .MOV with the H264 option gives a much closer colour match (only around 1 out on the RGB values in the middle of the blocks) than the "H264 Blu-ray" option (which creates a .M4V file) on this PC anyway.

     

    So (on this PC, rendering from with AE CS5.5)

    1) .MOV with H264 option gives almost the same colours as the source (only around 1 out on RGB values - on the middle of the coloured blocks anyway - not at the edges)

    2) AVI uncompressed gives identical colours to the source

    3) H264 option (.MP4) gives inaccurate results (a lot worse than 1)

    4) H264 Blu-ray (.M4V) option gives inaccurate results (a lot worse than 1)

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 15, 2012 3:30 AM   in reply to FrankinMD

    Because HDTV standard is 709 and ths SDTV  is 601. so the color in the monitor will have different feeling.

    But if u use TV to watch the Effect will be the same.

    TV have an Y-cb-cr to RGB  Translate table. when HD mode . tv will switch convert table to 709.

    when signal change to SD mode . TV will auto switch to  601 table. so it will looks same.

    But monitor did't have this function . so u will find the color shift.

    if u  try to make it without shift in monitor. when u use TV to watch ur produce . u will find a lot of different

     
    |
    Mark as:
  • Currently Being Moderated
    Oct 22, 2012 12:47 PM   in reply to FrankinMD

    I know I am resurecting an old thread but I have also had a lot of mind-blowing problems with output module's h264 color shift in AE 5.5...I believe I have pinpointed the reason and would like if someone could confirm or tell me I'm a fool...contrary to Adobe's claims, the h264 module does not seem to apply rec709 matrix to HD -size input video but rather rec601...since it also does not embed flags, players rely on the file's video size, which is 1920x1080, to determine which matrix to apply, and of course, they mistakingly apply the rec709, when it's actually rec601...those who encode to h264 SD, logically, don't see the problem because rec601 is the correct matrix for SD anyway...

     

    media encoder also doesn't embed flags, but applies the rec709 matrix correctly...

     

    hope the discussion picks back up...:-)

     

    cheers...

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 19, 2012 12:32 AM   in reply to mytbit

    mytbit is correct.  I've been mystified by this same problem for the past year on my pc.  But I'm able to render the same files to h264 in Premiere without the color shift.  Because 90 percent of my work takes place in After Effects I would really love for adobe to correct this bug. 

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 23, 2012 3:29 AM   in reply to stats1979

    Answer I've found is to either render to h264 from Premiere.  Or to render h264 in the Quicktime module. 

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 23, 2012 8:52 AM   in reply to FrankinMD

    When you are rendering out of Premiere Pro you are using the Adobe Media Encoder. Until Adobe changes the render cue you cannot do multi pass rendering in AE's Render Cue. You can render After Effects compositions directly in the Adobe Media Encoder (same as Premiere Pro) and therefore the results will be identical. You should never render MPEG formats like H.264 without using multi pass encoding so trying to call this a bug when it's a function of AE's current rendering engine to render a frame at a time is incorrect semantics. It is a feature that needs to be implemented, not a bug...

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 23, 2012 8:53 AM   in reply to FrankinMD

    ... obviously this bug is inconvenient for anyone who would prefer the speed and simplicity of rendering straight from After Effects.

     

    Because of the nature of waht After Effects does best --  i.e. render frame by frame -- it can't do multipass rendering, which can significantly lower H.264 file sizes, and it may even improve image quality.

     

    If you want, you can use Adobe Media encoder to make an h.264 of a specific comp.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 23, 2012 10:13 AM   in reply to Rick Gerard

    You are wrong, sir.  This is in fact a bug.  Read mytbit's comment above.  The h264 module is rendering in the wrong color matrix.  This has been verified by a private comment sent to me by one of Adobe's programmers. 

     

    One of the most frustrating aspects of this forum is the non-stop excuse making of the fan-boys (nee, fan-men) even when Adobe has admitted there is an issue. 

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 23, 2012 10:28 AM   in reply to stats1979

    Maybe it is a bug technically but if you really get to the core problem it is that MPEG formats should not even be available in the Render Cue until the render cue is capable of multi pass rendering. No professional would ever deliver any MPEG format that was not rendered using multi pass encoding. The quality just isn't there and that's the Codec's fault. It is Adobe's fault for allowing their AE to give you the option to use something that cannot produce acceptable results because of the nature of the codec's architechure.

     

    And I'm not a fanboy. Nobody is as hard on AE's development team as I am. I just have realistic expectations and I know how to use the tools of my trade without exceeting their limitations. This goes from Cameras to tripods to cranes to HMI's to generators to software. I've been making movies for 40 years and have never had an accident on the set or failed to deliver my part of the project.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 23, 2012 10:34 AM   in reply to Rick Gerard

    Uh, huh.  Good for you.  But you were wrong.  Just admit you were wrong.  No need to give me your world view, or career resume.  Shish.

     

    And actually one pass h264 looks pretty good coming out of the quicktime module. 

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (1)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points