Publishers of technology books, eBooks, and videos for creative people

Home > Articles > Digital Audio, Video > Adobe After Effects

Like this article? We recommend

Color Matching

Having examined the color-correction tools in depth, it's time for the bread-and-butter of compositing: matching foreground and background elements so that the scene appears to have been taken with the same basic light conditions.

Although it requires artistry to do well, this is a learnable skill with measurable objective results. The process obeys such strict rules that you can do it without an experienced eye for color. Assuming that the background (or whatever source element you're matching) has already been color-graded, you can satisfactorily complete a shot even on a monitor that is nowhere near correctly calibrated.

How is that possible?

As with so much visual effects work, the answer is derived by breaking down the problem correctly. In this case, the job of matching one image to another obeys rules that can be observed channel by channel, independent of the final, full-color result.

Of course, effective compositing isn't simply a question of making colors match; in many cases, that's only the first step. You must also obey rules you will understand from the careful observation of nature. And even if your colors are correctly matched, if you haven't interpreted your edges properly or pulled a good matte (or if such essential elements as lighting, camera view, or motion are mismatched), the composite won't succeed.

These same basic techniques will work for other situations in which your job is to match footage precisely—for example, color-correcting a sequence to match a hero shot (the one determined to have the right color juju), a process sometimes known as color timing.

The Fundamental Technique

Integration of a foreground element into a background scene often follows the same basic steps:

  1. Match overall contrast without regard to color, using Levels. When matching the black and white points, pay attention to atmospheric conditions.
  2. Study individual color channels and use Levels to match the contrast of each channel (as needed—not all images contain so fundamental a color imbalance).
  3. Match the color of the midtones (gamma), channel by channel, using Levels or Curves. This is sometimes known as gray matching and is easiest when an object in the background scene is known to be colorless gray (or something close).
  4. Evaluate the overall result for other factors influencing the integration of image elements—lighting direction, atmospheric conditions, perspective, grain or other ambient movement, and so on.

The overall approach, although not complicated or even particularly sexy, can take you to places your naked eye doesn't readily understand when looking at color. Yet, when you see the results, you realize that nature beats logic every time.

The sad truth is that even an experienced artist can be completely fooled by the context of the image. Figure 24 shows an example in which seeing is most definitely not believing. Therefore you shouldn't feel that working channel by channel is some kind of crutch. The results of your color adjustments undoubtedly will be challenged by other members of your production team, and when the time comes to review them channel by channel, it's pretty cool to be able to say you got it right.

Figure 24

Figure 24 There are no yellow dots in the top image and no blue dots in the center image. The four dots shown in the bottom image are identical to their counterparts in the other two images.

Ordinary Lighting

We begin with a simple example: inserting a 3D element lit with ordinary white lights into a daylight scene. As shown in Figure 25, the two elements are close enough in color range that a lazy or hurried compositor might be tempted to leave it as is.

Figure 25

Figure 25 An unadjusted foreground layer (the plane) over a day-lit background.

With only a few minutes of effort, you can make the plane look as though it truly belongs in the scene. Make sure that the Info palette is somewhere that you can see it. For now, choose Percent (0–100) in the Info palette's wing menu to have your values line up with the ones discussed here. (You can use whatever you want, of course, but this is what I'll use for discussion in this section.)

This particular scene is a good beginner-level example of the technique because it's full of elements that would appear monochromatic under white light (later we'll move on to scenes that aren't so straightforward). The background is dominated by colorless gray concrete, and the foreground element is a silver aircraft.

Begin by looking for suitable black and white points to use as references in the background and foreground. In this case, the shadow areas under the archways in the background, and underneath the wing of the foreground plane, are just what's needed for black points—they're not the very darkest elements in the scene, but they contain a similar mixture of reflected light and shadow cast onto similar surfaces, and you can expect them to match fairly closely. For highlights, you happily have the top of the bus shelter to use for a background white point, and the top silver areas of the plane's tail in the foreground are lit brightly enough to contain pure white pixels at this point.

Figure 26 shows the targeted shadow and highlight regions and their corresponding readings in the Info palette. The shadow levels in the foreground are lower (darker) than those in the background, while the background shadows contain slightly more red, giving the background warmth that's absent from the unadjusted foreground. The top of the plane and bus shelter each contain levels at 100%, or pure white, but the bus shelter has lower blue highlights, giving it a more yellow appearance.

Figure 26

Figure 26 The target highlight and shadow areas for the foreground and background are outlined in yellow; levels corresponding to each highlight (in percentage values, as set in the panel menu) are displayed in the adjacent Info palette.

To correct for these mismatches, apply Levels to the foreground and move the Output Black slider up to about 7.5%. This change raises the level of the blackest black in the image, lowering the contrast.

Having aligned contrast, it's time to balance color. Because the red levels in the background shadows are higher than blue or green, switch the Composition panel to the red channel by clicking the red marker at the bottom of the panel or using the Alt-1 (Mac: Option-1) shortcut, causing a thin red line to appear around the viewer. Now you can zoom in on an area that shows foreground and background shadows (see Figure 27).

Figure 27

Figure 27 Evaluate and match black and white levels, starting with RGB and then working on each color channel individually. In this case, the image is "green matched"; the RGB adjustment is all that's needed for the green channel (often the best channel to match, using RGB instead of its individual channel).

Black levels in the red channel are clearly still too low in the foreground, so raise them to match. Switch the Channel pop-up in Levels to Red, and raise Red Output Black slightly, to about 3.5%. You can move your cursor from foreground to background and look at the Info palette to check whether you have it right, but the great thing about this method is that your naked eye usually evaluates variations in luminance correctly without the numerical reference.

Now for the whites. Because the background highlights have slightly less blue in them, switch to the blue channel by clicking the blue marker at the bottom of the Composition panel or using Alt-3 (Mac: Option-3). Pull back slightly to where you can see the top of the bus shelter and the back of the plane. Switching Levels to the blue channel, lower the Blue Output White setting a few percentage points to match the lower blue reading in the background. Back in RGB mode—Alt-3 (Mac: Option-3) toggles back from blue to RGB—the highlights on the plane take on a more sunlit, yellow quality. It's subtle, but it seems right.

What about the midtones? In this case, they're taking care of themselves, because both the foreground and background are reasonably well balanced and these corrections are mild.

Figure 28 displays the result, with the same regions targeted previously, but with the levels corrected. To add an extra bit of realism, I also turned on motion blur, without yet bothering to match it precisely. The plane now looks more acceptably integrated into the scene.

Figure 28

Figure 28 This is a better match, particularly in the shadow areas; motion blur helps sell the color adjustment as well.

Work on this composite isn't done, either; in addition to matching the blur, you can add some sun glints on the plane as it passes, similar to those on the taxi. On the other hand, you can tell that the blur on the plane is too heavy for the pilot's absence from the cockpit to be noticeable, a good example of how an initial pass at a composite can save a lot of extra work.

Dramatic Lighting

Watch a contemporary feature film objectively for color, and you may be shocked at how rarely ordinary day-lit scenes such as the plane example occur. Dramatic media—not just films but television and theater—use color and light to create mood, to signify key characters and plot points, and more. Therefore, a scene dominated by a single color, such as Figure 29, is much more commonly found in dramatic films than it is in your everyday family snapshots. One of the main reasons that films take so long to shoot is that the cinematographer and lighting director require the time and resources to get the lighting the way it needs to be to create an image that is beautiful and serves the story.

Figure 29

Figure 29 This is the unembellished source lighting of this shot. (Image courtesy of Shuets Udono via Creative Commons license.)

The foreground element added in Figure 30 clearly doesn't belong in this scene; it doesn't even contain the scene's dominant color, and it's white-lit. That's fine; it will better demonstrate the effectiveness of this technique. Notice that both the foreground and the background elements have some areas that you can logically assume to be flat gray. The bridge has concrete footings for the steel girders along the edges of the road, while the can has areas of bare exposed aluminum.

Figure 30

Figure 30 Not only is it clear that the can doesn't belong in the color environment of the background; the mismatch is equally apparent on each color channel.

To play along with this game, you would apply Levels to the foreground layer.

Switch both your Composition view (Alt-1/Option-1) and the Channel pull-down in Levels to Red. The most challenging thing about this technique is remembering to keep both settings on the same color channel; using a four-up setup is probably worth the trouble.

Now, let's pretend that the red channel is a black-and-white photograph in which you're using the red channel of the Levels effect to match the foreground to the background.

Clearly, the foreground element is far too bright for the scene. Specifically, the darkest silver areas of the can are much brighter than the brightest areas of the concrete in the background. Therefore, adjust the gamma down (to the right) until it feels more like they inhabit the same world; in my example, I've adjusted Red Gamma way down to 0.67. Now cut down the red highlights a little; bring Red Output White down to about 92.5% or whatever looks right to you. The end result should look like a black-and-white photo whose elements match (see Figure 31, top image).

Figure 31

Figure 31 It's actually fun to pull off an extreme match like this channel by channel. The Levels settings used weren't really derived from the histogram, but by a mixture of looking for equivalent black/white/midpoints in the image, as well as just analyzing whether the result looks like a convincing black-and-white image on each channel.

Now move the Levels Channel and Composition view (Alt-2/Option-2) over to green. Green is the dominant color here, and its black contrast and brightness are much higher in the background. Therefore, raise Green Input Black to about 12.5% (for the contrast) and Green Gamma to something like 1.3 (Figure 31, middle). Better than copying my levels, try to find these on your own.

Finally, switch Levels and the Composition viewer (Alt-3/ Option-3) to the Blue channel. Whoa—there's almost no match here. The can is brighter and more washed out than the background. Again, the Input Blue Level must come up, to about 17.5%, but this time gamma has to come way down, ending up at about 0.45%. Now the can looks believably like it belongs there (see Figure 31, bottom).

It's strange to make all of these changes without ever looking at the result in full color. Go ahead and do that. Astoundingly, that can is now in range of looking like it belongs in that scene; defocus it slightly with a little fast blur, add a shadow, and you start to believe it. Make any final contrast adjustments on the Levels RGB Channel, and you have an impressive result that required no guesswork whatsoever (see Figure 32).

Figure 32

Figure 32 The result includes a subtle shadow that has also been color matched, as well as a final adjustment to the white contrast.

When There's No Clear Reference

The previous examples have contained fairly clear black, white, and gray values in the foreground and background elements. But life isn't always so simple.

Figure 33 shows a scene that lacks any obvious gray values to match; the lighting is so strong, it's hard to tell what color anything in the scene was originally, or whether there were any neutral black, white, or gray items in the scene.

Figure 33

Figure 33 What the heck is going on here? Again, the source image is as it was shot. Examine some of your favorite films, and you may find scenes lit this dramatically; the eye quickly becomes accustomed to strong shifts of color, but the color can also be used to strike a subconscious chord. (Image courtesy of Jorge L. Peschiera via Creative Commons license.)

The technique still works in this case, but it may require more in the way of trial-and-error or artist's intuition. Looking at each individual color channel, only green is even close to a plausible match right off the bat; the red channel contains blown-out whites, and the blue channel is so dark (and grainy) that it hardly exists.

Again, just try to get the brightness and contrast adjusted, working channel by channel, and you get an initial result something like that in Figure 34. Considering how subjective the adjustments are (by necessity) in this case, this isn't half bad, and fine adjustments to the RGB channel can bring it to where it needs to go.

Figure 34

Figure 34 This one requires as much intuition as logic, but adjusting it channel by channel still yields a striking result.

The ability to match color without seeing an image in full color is so powerful that it can seem almost magical the first few times you try it. Why, then, do so few artists work this way? I would have to say that laziness and ignorance are the main culprits. Switching channels seems like a pain, and few untrained artists clearly realize that color works like this.

Gamma Slamming

Maybe you've seen an old movie on television—the example I think of first is Return of the Jedi (before the digital re-release)—in which you see black rectangular garbage mattes dancing around the Emperor's head, inside the cloak, that you obviously shouldn't be seeing. Return of the Jedi was made prior to the digital age, and some of the optical composites worked fine on film; but when they went to video, subtleties in the black levels that weren't previously evident suddenly became glaringly obvious.

Don't let this happen to you! Now that you know how to match levels, put them to the test by slamming the gamma of the image. To do this, you need to make a couple of adjustment layers. I usually call one slam up and the other slam down, as in the examples. Be sure that both of these are guide layers so that they have no possibility of showing up in your final render.

To slam up, apply Curves with the gamma raised significantly (see Figure 35). This technique exposes any areas of the image that might have been too dark to distinguish on your monitor; if the blacks still match with the gamma slammed up, you're in good shape.

Figure 35

Figure 35 Slamming gamma is like shining a bright light on your scene. Your black and midtone levels should still match when viewed at these extremes.

Similarly, and somewhat less crucially, you can slam down by lowering the gamma and bringing the highlights more into the midrange (see Figure 36). All you're doing with these slams is stretching values that may be difficult for you to distinguish into a range that's easy for you to see.

Figure 36

Figure 36 If in doubt about the highlights in your footage, you can also slam the gamma downward. Here, the slam makes it clear that the highlight reflected in the can is not as bright or bloomed as the overhead lights, and a lack of grain in the foreground becomes apparent.

This method is useful anywhere that there's a danger of subtle discrepancies of contrast; you can use it to examine a color key, for example, or a more extreme change of scene lighting.

Peachpit Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from Peachpit and its family of brands. I can unsubscribe at any time.

Overview


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about Peachpit products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information


To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.

Surveys

Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites; develop new products and services; conduct educational research; and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.

Newsletters

If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email ask@peachpit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information


Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.

Security


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.

Children


This site is not directed to children under the age of 13.

Marketing


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information


If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.

Choice/Opt-out


Users can always make an informed choice as to whether they should proceed with certain services offered by Adobe Press. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.peachpit.com/u.aspx.

Sale of Personal Information


Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents


California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure


Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.

Links


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact


Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice


We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020