What do Julie Andrews and Piero Angela have in common? The fact of having appeared in imaginary worlds, created by designers. How? Thanks to an effect called chroma key, which allows you to delete the background. Let’s see how to make it happen in Kdenlive.
Since the beginning of the cinema, the directors have tried to create extraordinary environments in which to insert the actors. For example, make them walk inside a painting. Shooting the video with an actor pretending to be in a particular world was not difficult. The problem was to make the background disappear and replace it with a drawn one. The solution initially found for black and white films was rather ingenious: it was enough to shoot the subject on a black background, as dark as possible (which is not difficult to do considering that you always worked with very closed aperture). As we know, in fact, in negative films the black color appears transparent. This means that a black background would not have been seen automatically, and the film could have been superimposed on another containing the hand-drawn background. The advent of color complicated things a little, but the basic technique remained similar: just think of Julie Andrews dancing in a painting with Dick Van Dyke and penguins in the film Mary Poppins. Today, with digital editing and VFX, things have changed: the cameras work directly in the positive, and each color is recorded as such, therefore the background always appears in the movies. But it is possible to let the computer understand which part of the movie should be kept and which part is hidden. The trick that is used is the following: the actor is played in a monochromatic environment, usually blue or bright green in order to have a good contrast with the actor himself. Then the computer is asked to make the background color transparent: this is how Piero Angela was able to climb the vocal cords and walk in the lungs in the television broadcast “The wonderful machine”, dedicated to the human body, or float in a spaceship in “Journey into the cosmos”. Of course there is a problem: the actor must not wear clothes of the same color as the background, otherwise he would end up disappearing. This can also be a desired thing: to make an actor’s arm disappear, just cover it with a colored cloth as the background. In this article we offer you a very simple example: an actor juggles with his own head. We will use the chroma key to make the background disappear and replace it with a uniform white tint, as is done in some advertisements or in any case when you want to focus the audience on the actor. We could also have used the chroma key to make the head disappear (putting on a green hood) or the neck (with a sort of green scarf) but we preferred to use rotoscoping so we didn’t have to make two different movies, one of the headless body and one of the bodyless head, which would have been difficult to synchronize and overlap. In fact, one can think of the chroma key (or “Blue screen”, as Kdenlive calls it for a translation error) as a sort of automatic rotoscoping. In fact, the result is the same: both are used to make part of the film transparent. The fact is that rotoscoping is extremely precise, and allows you to get exactly what we want. The chroma key, on the other hand, is very fast: it takes a few seconds to perform a good chroma key, but the precision is often not excellent. You can find the example video at the following address: http://www.youtube.com/watch?v=3O7KmqT-01E
Reduce errors
As we mentioned, the chroma key by definition is not a very precise method. In fact, even in the most professional chroma keys you can always notice some pixels out of place, observing every single frame. The question is very complicated with regards to hair: not having a clean outline, they risk giving a bad result. We recommend using the three light system to illuminate the subject (a diffuse ambient light, one placed in front of the side for the subject, and a back light to detach the subject from the background): normally it makes things simpler. Kdenlive’s chroma key works pretty well, and for most things it’s fine, but if you want something more refined you can use Blender’s compositor. This is especially recommended if you want to use a resolution higher than 1080 vertical dots.
One clip, two tracks
We will use the same video clip twice


Every shade of green
We use multiple color keys until all the shades of the background are canceled




Let’s put our heads up
The chroma key must also be applied to the head track, together with the rotoscope




A good juggler
We use the composite transition keyframes to make the actor’s head fly



