How the green screen works: the chroma keying technique and why green is used

The green screenliterally “green screen”, is a tool used to replace the background of a video thanks to a technique called chroma keying: We shoot a video with a green background and then tell the computer to replace the green pixels with another image or another video. The technique was first used in 1940 with the film The Thief of Baghdad, which won the Oscar for special effects.

How to use the green screen

The scene must be shot using a sheet of only one color very compact and uniform. The aim is to identify the subject well and to make the subsequent activity in which it is “detached” from the background easy.

The most important thing is to create coherence between the recorded video and the one that will be applied as a background. The interaction between the two images must make the viewer perceive that there is no difference between the two scenes, that it is not a collage but that the subject and background are in the same place at the same time. Lighting plays a fundamental role in this.


From green screen to postproduction

After recording, you need to choose a program to edit the video. The chosen software works with a algorithm.
The first thing it does is convert images from RGB to HSB.

Our computer images are displayed with the color system RGB (Red, Green, Blue). This model is additive because each color is given by the addition of a certain amount of red, green and blue. To use the green screen we need to convert the video from the RGB system to that HSB (Hue Saturation Brightness). Also in this case it is an additive model where the various letters indicate hue (H), saturation (S) and brightness (B). What we need to make chroma keying work is the Hthat is, the color tone.


Once this conversion is done, we can command the software to remove the green, making the difference in absolute value between the channel H of the pixels of the image (i.e. their shade) and the chromatic key sought, i.e. the green that we set as the “color to remove”. Let’s set a certain tolerance, so that the software also takes the slightly brighter and slightly darker areas and let’s get started.

We told the computer that we want to erase the green color. Now that we have the images cut out, all we have to do is apply another background, which can be a static image but also a video.

Why is the green screen green?

Actually the concept of chroma keying It would work with every color. In fact, initially the green screen was not green but blueso much so that we talked about blue screen. The blue was chosen because it complemented the pink color of human skin, which therefore had to peel off well. With the advent of digital cameras it was decided to switch to green because sensors in contemporary equipment are more sensitive to this tint. Additionally, green was chosen because it is a color that is not easily found in the characters’ skin tone or hair. The choice therefore depends on the fact that by using a green screen you do not risk accidentally eliminating essential elements or parts of the characters that are being retouched.

For this reason some television programs have a dress code That prohibits wearing green. If a green screen was used to shoot some scenes and someone had a green t-shirt, an effect similar to that of the invisibility cloak would be created: the person’s chest would disappear from the image and in its place there would be the image of the fake background. Sometimes this effect is intentional: for example, to make something inanimate move without being seen, there are people who are entirely covered in green so that their image disappears in post-production, giving the illusion of movement for the ‘inanimate object.


The advantages of green screen

We want to shoot a video with a backdrop of New York City at night, but we have no way to go there to actually shoot it? In a recording studio the green cloth can become anything we want. Thanks to this technique they can be added special effects, backgrounds and details that are difficult to find in reality. In fact, green screen is absolutely essential in science fiction films. An example? All the special effects in The Matrix. A great advantage for those who work in cinema is that the use of green screen reduces travel and business costs. With this technique you can also create videos in places not accessible to the public, for example the White House.

Green screen is also used in live programs. A clear example is that of forecast. The map with the disturbances is actually projected onto a green screen and is added to the recording only in post-production!