by
18. February 2017

Please note: All tests are done with Avid Media Composer 8.8., After Effects 2017 v14.1.0.57 and Premiere 2017.0.2 v.11.0

Before we start, download this sheet I have created. It shows all the different combination of import and export options and their outcome. Feel free to share it wherever you want.

Alright, the first thing I want to talk about is something that comes up over and over again: Color spaces!

I keep on seeing issues with different color spaces all the time, in cheap internet videos as well as in huge on-air spots. Try and search the internet, and you will find very very old questions about this topic as well as at least three new ones every month.

So why is this so difficult?
In fact, it isn’t that difficult, but it sure is very confusing. In this article, I’ll try to explain how to work with different color spaces in Avid Media Composer and Adobe After Effects. But like every good story, let’s start at the beginning.

What are we dealing with?
Most of the time in our film and tv world, we have to handle two different color spaces: RGB and REC709 (there are a lot more color spaces, but I want to focus on what we really have to deal with day by day). To keep it simple, let’s say RGB is used by our computer monitors, while REC709 is used by TVs.

What’s the difference?
The main difference between RGB and REC709 is the range of colors and luminance they can represent. While RGB (or full range, or full swing) has a range from 0 -255 (0 is the deepest black, 255 is the brightest white), REC709 (or limited range, or studio swing) only represents a range from 16 – 235. The reason for this (please correct me if I’m wrong) lies in broadcast technology. The values below 16 are used for the transmission of  various signals, for example the “sync” or the “color burst” signal. Those signals are indispensable for the correct representation of interlaced color pictures on TVs.

The following chart shows an RGB / REC709 split.
You can see that the upper half of the chart below is RGB, the lower half is REC709. The best spots to see the difference are the white bar on the left and the black bar on the right.

 

The import

So the first aspect you have to look at is the import of your footage into Media Composer. And this is also the point where the first confusion might come up. Since version 8.3, Avid offers two different options regarding color space. Before 8.3., you had three options with a different naming. The renaming shows that there were a lot of confusion about those options.

  • Do not modify, treat as legal range (before 8.3.: Computer RGB 0-255, with dither option)
  • Scale from full range to legal range (before 8.3.: 601 SD or 709 HD (16-235)

With those options, you’re telling Avid what kind of footage you want to import.
If you want to leave your footage as it is, choose “Do not modify, treat as legal range”. If you want to import footage with a range of 0 – 255, but you want to have it converted to 16 – 235 right away, choose “Scale from full range to legal range”. Sounds easy, right? Let’s see what happens to our test chart:

Here is what happens if we import the test chart and choose “Do not modify, treat as legal range” (remember that the chart has a range from 0 – 255):

And here is the “Scale from full range to legal range” option:

You can see that the first picture has a range from 0 – 255, because nothing was modified form the original image. But the second picture now has a range from 16 – 235, because we told Avid that our source footage is 0 – 255, and we want it converted to 16 – 235. Everything’s fine so far.

What if our source footage is already legal range, 16 – 235?
With the “Do not modify, treat as legal range” option, nothing happens. The source file is not modified and keeps it’s range from 16 – 235.

But here comes the point where you can make a big mistake: If you import footage with a range from 16 – 235, and choose the “Scale from full range to legal range” option, this is what happens:

Our footage is compressed again, because we told Avid to scale it to legal range, even if it was legal range already. We’re ending up with a range from 30 – 218, and that doesn’t make any sense. Ever!

Basically, you’re always on the safe side when your import all of your footage with the “Do not modify, treat as legal range” option, as you can always scale a  0 – 255 range down to 16-235 in Avid, for example with the safe color effect. But if you want to have your footage in legal range straight away, you can convert your 0 – 255 footage to 16 – 235 right at the import by choosing the “Scale from full range to legal range”. Just make your sure you’re NEVER importing 16 – 235 footage with the “Scale from full range to legal range” option.

Tip: Whenever you’re not sure which range your source footage really has, bring it into Media Composer via AMA Link, because AMA doesn’t make any changes to the original source file. Unfortunately, there are some exceptions:

  • 1.: You can’t link to TIFF images or sequences
  • 2.: When you link files with animation codec (at least for uncompressed), Avid automatically applies a level conversion to the footage. You can see your unmodified footage by bypassing all conversions in the source settings. DNxHD or MXF files are not affected by this.

 

What about the export?

It’s baiscally the same, just more of it. If you’re exporting media from Avid Media Composer, you have a set of “Avid options”, and, depending on your codec, a set of “Codec options”. There are codecs with no extra codec options, like MXF, and some codecs with extra codec options, like DNxHD.
I’ve tested all the available options with 4 diferent codecs: DNxHD 185, Animation, MXF and TIFF Sequence. Let’s start with DNxHD. 

DNxHD 185

With DNxHD, we end up with 8 different combinations of export options. So the first thing we take a look at are the Avid options:

The first option is “Keep as legal range”, and the second option is “Scale from legal to full range”, just the other way around as for the import. And that’s because Avid always assumes that you are working in legal range! That’s why option 1 isn’t called “Do not modify”, because Avid assumes that it must be legal range.

The second options you have to take care of are the codec options. For DNxHD, they look like this:

Yes, you have the exact same options again! What? Why? Well, this seems to be exclusive to the DNxHD codec, and I really hope that Avid comes up with some better way of handling export settings for codecs with it’s own settings, because this is causing a lot of confusion.

I took the time to export the test chart as DNxHD 185 with all the different combinations of options, and here are the results (the exported files are brought back into Media Composer via the “Do not modify”and also linked)

Again, you can see all of the following results here on this sheet.

Source Footage: 0 – 255 | Avid option: Keep as legal range | Codec option: RGB

Correct range of 16 – 235

Source Footage: 0 – 255 | Avid option: Keep as legal range | Codec option: 709

Correct range of 0 – 255

Source Footage: 0 – 255 | Avid option: Scale from legal to full range | Codec option: RGB

Incorrect range of 16 – 235, Everything below 16 and above 235 is cut off (0, 4 and 12 = 16 | 255, 251 and 239 = 235)
Now this is the first combination of export options that will produce an incorrect range. You can see in the image that you’re losing information in the values from 0 – 12 and from 239 to 255. The lowest value is 16 and the highest value is 235.

Source Footage: 0 – 255 | Avid option: Scale from legal to full range | Codec option: RGB

Incorrect range of 0 – 255, Everything below 16 and above 235 is cut off (0, 4 and 12 = 0 | 255, 251 and 239 = 255)
This combination produces an incorrect range, where you’re losing information in the same values as before. The difference here is that you’re lowest value is 0 and the highest is 255.

Source Footage: 16 – 235 | Avid option: Keep as legal range | Codec option: RGB

Incorrect range of 30 – 218, Double compression (0 = 30 | 255 = 218)

This is kind of a special case, because this file has an incorrect range of 30 – 218, which is basically a double compression. The strange thing here is that the exact same file shows a correct range of 16 – 235 in After Effects. I don’t know exactly what’s causing that problem, but we’ll get back to that later.

Source Footage: 16 – 235 | Avid option: Keep as legal range | Codec option:709

Correct range of 16 – 235

Source Footage: 16 – 235 | Avid option: Scale from legal to full range | Codec option: RGB

Correct range of 16 – 235

Source Footage: 16 – 235 | Avid option: Scale from legal to full range | Codec option: 709

Correct range of 0 – 255

So, from our first exports we have already learned that there are in fact some correct and some incorrect combinations of options. Note that you cannot produce a correct range when you export footage with a range from 0 – 255 and choose to scale it from legal range to full range. Let’s check the other codecs.

 

Animation

For the Animation codec, we only have to deal with the Avid options. There are extra codec options, but none of them is about color spaces, so we can forget about those for this test. In total we have 4 different combinations with the Animation Codec:

Source Footage: 0 – 255 | Avid option: Keep as legal range

Correct range of 0 – 255

Source Footage: 0 – 255 | Avid option: Scale from legal to full range

Incorrect range of 0 – 255, Everything below 16 and above 235 is cut off (0, 4, 12 and 16  = 0 | 255, 251, 239 and 235 = 255)

Source Footage: 16 – 235 | Avid option: Keep as legal range

Correct range of 16 – 235

Source Footage: 16 – 235 | Avid option: Scale from legal to  full range

Correct range of 0 – 255

With the animation codec, everything turns out as expected. The only way to produce an incorrect range is, again, if you have 0 – 255 footage abd choose to scale from legal to full range.

 

MXF

The MXF Codec makes it even easier for us, because it doesn’t provide any options regarding color space at all. So we can only check what happens with our different source files:

Source Footage: 0 – 255

Correct range of 0 – 255

Source Footage: 16 – 235

Correct range of 16 – 235

The MXF codec turns out perfectly fine in Media Composer. What used to be 0 – 255 is still 0 – 255, and the same goes for 16 – 235. No changes to the range at all.

 

TIFF Sequence

When exporting a TIFF sequence, we only have the Avid options to choose from. So this gives us 4 different combinations in total:

Source Footage: 0 – 255 | Avid option: Keep as legal range

Correct range of 0 – 255

Source Footage: 0 – 255 | Avid option: Scale from legal to full range

Incorrect range of 0 – 255, Everything below 16 and above 235 is cut off (0, 4, 12 and 16  = 0 | 255, 251, 239 and 235 = 255)

Source Footage: 16 – 235 | Avid option: Keep as legal range

Correct range of 16 – 235

Source Footage: 16 – 235 | Avid option: Scale from legal to  full range

Correct range of 0 – 255

With TIFF, you get the exact same results as with the animation codec. Only one wrong outcome.

Alright, this is it for the export options. There are many other codecs, but I wanted to focus on some of the most used ones. After those tests, there’s at least one thing we can say for sure now:
You will ALWAYS get an incorrect range when you choose to scale 0 – 255 footage form legal to full range.
That makes sense, because you’re trying to covert an image to full range that already comes in full range, resulting in cut off blacks and whites.

 

From Avid to After Effects

What could go wrong, you think? Now, after this long read about all the different options and all the correct and incorrect outcomes, we know pretty much everything about it, right? Wrong! In fact, the more time I’ve spent on this article and on the testing, the more weird things were coming up. But don’t worry. Let’s just check what happens step by step.

So, we’ll begin with DNxHD. We simply import all the versions we have just exported into After Effects and check if there are any surprises (I’m testing it with no color space assigned in After Effects)

DNxHD:

Source Footage: 0 – 255 | Avid option: Keep as legal range | Codec option: RGB

Correct range of 0 – 255

Source Footage: 0 – 255 | Avid option: Keep as legal range | Codec option: 709

Here comes our first real surprise: While this file shows a correct range of 0 – 255 in Media Composer, it has an incorrect range of 0 – 255 in After Effects, with everything below 16 and above 235 being cut off.

I have enlarged the area with the black values. You can see that there is no separation between 0 and 16, it’s the same black level.:

At first, I couldn’t find any way to bring back the lost information in After Effects. Not with a curve adjustment, and also not with the color profile converter.

But as the exact same file is perfectly fine in Avid Media Composer, I knew that the information must be somewhere in the image. So I decided to check it in Adobe Premiere, and guess what: Premiere shows the file with an incorrect range of 0 – 255, but you can easily bring back the correct range by adjusting the curves. So i gave it one more shot, and switched my bit depth in  After Effects form 8bit to 32bit. And look at that: I could now bring back all the image to a correct range of 0 – 255.
For some reason  After Effects recognizes the file as a floating point 32bit file, even thought it clearly says it’s 8 bit in the project window.
You can even see that the black values are actually negative blacks, and the whites are superwhites. In my understanding, those values can usually only exist in floating point images.
And to make it even weirder: You can bring back the correct range by adjusting the levels and then switch to 32bit, but you can’t do the same thing in Premiere. There, only the curves adjustment works, but not the levels!

To have a better understanding how this affects your footage, check out those stills:

In the first still, you can see how the file looks when you import in into After Effects:

Notice how the bright parts in the white water are blown out.

Here’s the exact same picture, but this time I switched to 32bit and brought the levels down:

You can see how all the details (basically the range of bright greys and whites) are back in the image.

I have sent two bug reports regarding this issue to Adobe, but haven’t received an answer yet. To be fair, I’m not even sure if this is caused by After Effects or by Avid’s DNxHD settings. But the different behavior between After Effects and Premiere is still odd.
I’ll keep you updated. For now, let’s continue with the test:

Source Footage: 0 – 255 | Avid option: Scale from legal range to full range | Codec option: RGB

Incorrect range of 0 – 255, Everything below 16 and above 235 is cut off (0, 4, 12 and 16  = 0 | 255, 251, 239 and 235 = 255)

Source Footage: 0 – 255 | Avid option: Scale from legal range to full range | Codec option: 709

Incorrect range of 0 – 255, Everything below 16 and above 235 is cut off (0, 4, 12 and 16  = 0 | 255, 251, 239 and 235 = 255)

Source Footage: 16 – 235 | Avid option: Keep as legal range | Codec option:709

This file shows a correct range of 16 – 235 in Media Composer, but a correct range of 0 – 255 in After Effects. You can easily change the range to 16 – 235 by using the color profile converter in After Effects.

Source Footage: 16 – 235 | Avid option: Keep as legal range | Codec option:709

This file shows an incorrect range of 30 – 218 in Media Composer, but a correct range of 16 – 235 in After Effects. As mentioned before, I can’t exactly tell you why this is happening. My guess is this: The exported DNxHD files from Avid have the color space “HDTV (REC709) YCbCr” assigned to them, with no way to change it in the interpret footage settings. I think that might be the reason for this strange behavior.I would highly appreciate if someone who reads this can clear it up in the comments.

Source Footage: 16 – 235 | Avid option: Scale from legal to full range | Codec option: RGB

Correct range of 0 – 255

Source Footage: 16 – 235 | Avid option: Scale from legal to full range | Codec option: 709

This file show the exact same behavior as the “Source Footage: 0 – 255 | Avid option: Keep as legal range | Codec option: 709” above. Follow the same procedure and switch to 32bit, and you can restore the correct range.

From 8 exported versions from Media Composer, we end up with only 3 working perfectly fine in After Effects. Two more version show an incorrect range but can be restored to a correct range. One version shows a wrong range in Media Composer, but a correct range in After Effects. The other two versions simply have an incorrect range with no way to restore a correct one. I wouldn’t say that this makes exchanging DNxHD from Media Composer to After Effects completely unusable, but you have to take extra care if you do so.

 

Animation:

Source Footage: 0 – 255 | Avid option: Keep as legal range

Correct range of 0 – 255 in Media Composer and After Effects

Source Footage: 0 – 255 | Avid option: Scale from legal to full range

Correct range of 0 – 255 in Media Composer and After Effects

Source Footage: 16 – 235 | Avid option: Keep as legal range

Correct range of 16 – 235 in Media Composer and After Effects

Source Footage: 16 – 235 | Avid option: Scale from legal to  full range

Correct range of 0 – 255 in Media Composer and After Effects

With the Animation codec, there are no changes between Media Composer and After Effects. What used to be a correct range stays correct, only one version is incorrect.

 

MXF

Source Footage: 0 – 255

What used to be a correct range of 0 – 255 in Media Composer, is now an incorrect range from 0 – 255 in After Effects. We can see the same phenomenon here as with the DNxHD files. The only way to bring back the correct range is by switching to 32bit in After Effects and adjust the curves / levels. We can also see negative blacks and superwhites as well as the assigned color space again.

Source Footage: 16 – 235

What used to be a correct range of 16 – 235 in Media Composer, is now a correct range from 0 – 255 in After Effects.

Unfortunately, we can see the same issue as with DNxHD in one of the MXF files.

 

TIFF

Source Footage: 16 – 235 | Avid option: Keep as legal range

Correct range of 16 – 235 in Media Composer and After Effects

Source Footage: 16 – 235 | Avid option: Scale from legal to  full range

Correct range of 0 – 255 in Media Composer and After Effects

Source Footage: 0 – 255 | Avid option: Keep as lageal range

Correct range of 0 – 255 in Media Composer and After Effects

Again, for TIFF goes the same as for Animation. No changes in the range and no changes between Media Composer and After Effects.

 

Conclusion:

Let me try to sum this up: 
From all the tested formats, your best choice at the moment would be either Quicktime Animation or a TIFF sequence.
To me, it’s deeply unsatisfying that two of the most popular and common codes, MXF and DNxHD, show very unexpected behaviors. You can still work with them, but makes sure to double check your workflow.

I hope this could clear up a little bit of confusion and I could make the daily work a tiny bit easier for some editors and designers.

What are your experiences with color spaces? Do you have any additional tips? Please share them in the comments.

Share on FacebookShare on LinkedInShare on Google+Email this to someone
4 Comments
  1. Sebastian 19. February 2017 Reply

    Nice - I still have to work through but looks really thoroughly tested! Thanks :-) I remember our discussion on the Acid Coulour Profile compensation on various screens. Seems like this going to complicate it even more?

    I met a guy who became a huge fan of the ACES colour space...maybe worth looking into it.
    https://www.slashcam.de/news/single/ACES-ist-fertig---mehr-Farbe-geht-nicht----11981.html

    Cheers
    S.

  2. Dennis 19. February 2017 Reply

    Yes, I remember that, too. Now you see how long it took me to make an actual post out of all the information about color spaces.
    The display color space in Avid doesn't change anything on the footage. It's basically a simulation of what the footage would look like if it's converted into a different color space. But yes, that's another source of error. If your monitor doesn't show your final image in REC709 and you also don't assign that color space in Avid, you will very likely go for too low black and too high white values. A REC709 image with a range from 16 - 235 would show a range of 0 - 255 when the display color space "REC709 [full range]" is assigned. Because this how your 16 - 235 image would look on a TV screen.

    I didn't read too much about ACES but I'll take a look at it. Thanks for the link.

  3. Bas 24. April 2017 Reply

    Hey Dennis,

    Thanks for this very thorough examination of color spaces!
    I've read before that AMA linking your files is the safest way of knowing that no color space modifications are done, but I found that linking full range graphic files (I created a test-PNG with half of the picture RGB 0,0,0 and the other half 16,16,16) actually DOES transform my colors!
    In its Source Settings>Color Encoding the Source color space is read correctly as [full range], but automatically a transformation is added to it (Levels scaling [full range to video levels]).

    Only when bypassing this transformation the correct color values are shown.

    Also, I would always have my source and program monitor Display Color Space set on "REC709 [full range]" no matter what the situation, as the "REC709" shows pure black (0,0,0) as 16,16,16 which no one ever wants ever, for ever in the history of the universe ever.

    Anyways, these are my two cents!

    • Dennis 5. May 2017 Reply

      Hi Bas and thanks for your reply.
      If I remember it correctly, the AMA transformations depend on your Avid version. I think (but I'm not totally sure), up to version 8.4. does not apply any transformations automatically. Maybe someone can check that on his or her system. As I said, the automatic transformation also happens with the Animation codec.

      For the monitor settings, I used to have it just like you said. After a while, I changed my source monitor back to "project", to have a better side by side comparison.

Leave a Reply

*