Creating a Chroma Key in Final Cut Pro X

In “Under 5 Minutes” Steve Martin shows you how to use the automatic options in Final Cut Pro’s Keyer to make a chroma key composite using a green screen.

Learn to analyze the matte and improve the key by sampling sections of the background on a “badly lit” green screen, and then refine the key by blending the edges of the matte.

Welcome to Final Cut Pro X in under 5 minutes. I’m Steve from rippletraining.com. In this episode, I’m going to show you how to use the automatic options built into Final Cut Pro’s keyer to get great results from your green-screened subjects.
It’s the season for wearing silly costumes, and my son Andy found this inflatable suit that makes him look like a…giant grape.
Here he’s doing some of his dub-step moves in front of a 1010 chromakey green painted wall. If you’d like to know what paint I use, there’s a link in the description section below.
I connected an audition clip containing some images of a vineyard to be used as the background. Before you apply a keyer effect, you should remove any area in the frame that won’t be part of the final composite to make it easier for the keyer to evaluate the image and give you a good key right out of the box.
Here, we see part of the set at the right and left edges of the frame. I’ll press Shift-C to call up the crop tool, then crop out the unwanted pixels. If your subject moves, make sure to scrub over your clip to ensure the cropping won’t be cutting off some of your subject.
For the next step, I’ll park the playhead over the greenscreen clip and open the Effects Browser. I’ll locate the Keyer in the Keying category then skim over the thumbnail to see a preview. Instantly, we can see some problems with the lighting in the scene. The dark spot indicates an area where the light was too close to the wall. You can also see this hot-spot by skimming over the clip.
I’ll apply the effect by dragging it onto the clip. The keyer begins its work of knocking out most of the green pixels, giving us a very rough composite. In the Inspector, reveal the Keyer controls. Be default, Final Cut Pro applies an automatic keyer by choosing the best range of green pixels from which to create the key.
With the strength slider at 100, full automatic keying is applied, and with the strength slider set at 0, no keying is applied. In my experience, leaving this slider at 100% is the best starting place to begin making improvements to the key.
The first place to begin when evaluating your key is the matte view. The matte view is helpful because it shows you which pixels are opaque, which ones are transparent, and which ones are semi-transparent.
The white areas are the opaque pixel, the areas where no background shows through. The black areas are the transparent pixels, the areas where the background completely shows through, and the gray areas are where some of the background shows through.
To achieve a good key you want as much of your subject in white, as much of your background in black, and the edges surrounding your subject in gray to create a smooth transition between the subject and the background. But right now there is too much gray in the background and it needs to be removed.
To refine the key, click the Sample color button, then drag out a box over the area of gray pixels. Instantly, the area becomes black. This is what you want the key to look like, a black and white cut-out of your subject.
Even though the key looks good on a single frame, it’s a good idea to skim over the entire clip because if you’re lighting changes, you’ll need to drag out more samples.
To view the composite, click the composite button. The key look pretty good, but Andy could use some more blending around the edges to bring out the detail in his hair.
I’ll switch back to the matte view.
To see the detail in your matte, you’ll want to zoom in and re-adjust the image in the viewer.
Click the Edges button, then click and drag across the matte boundary. You’ll see detail begin to return to the edges. You can adjust the middle handle to create more or less softening around the edges. If you drag too far, you’ll be adding too much transparency to the core matte. Just drag enough until you see some of the hair detail return, then back it off.
Additionally, you can move the start and end points of the edges control to achieve different variations in your edge transitions. You can also add more than one edges option to your matte so you can have one smoothing for hair and another for hands and fingers for example.
If you like the edge detail, but find there are still too many gray pixels in your matte, you can use the fill holes slider to knock out the transparency while maintaining the soft edges you worked hard to achieve.
Let’s take a look at the composite.
That looks great.
One other feature that I use to improve the key is Light Wrap. Using this slider, the transparent edge pixels are blended with the background pixels to achieve a more organic key. Notice when I drag the amount slider, the edges are picking up the green foliage in the background image.
Earlier I mentioned that I use an Audition clip for various backgrounds. Now you’ll see why. Playing the clip back, then pressing control-option-left arrow let’s me cycle through each background to try out each one with the dub-stepping grape.
If you’re interested in learning more about keying, checkout our Compositing in Final Cut Pro X tutorial on our website.