Chroma Key

A Chroma Key control is available for some video inputs. When enabled it allows the removal of backdrops etc based on color (chroma) values.

Adjustment

To adjust the chroma keyer:

  1. Make sure that the color value of the chroma key color matches the actual green screen color as well as possible. This is done by observing the transparency of the green and changing the color. Remember to also try to change the hue (slider to the right).

  2. Experiment with adjusting the tolerance. The tolerance is in HSV (hue, saturation, value). It is recommended to have more tolerance in hue and saturation than in value.

  3. Change Threshold: Cut to remove the edge of the things you want to be visible. The cut threshold controls how close to the green screen things will be fully transparent.

  4. Change the Threshold: Blend to set the end of the blending region. There is a region from the fully transparent parts of the image to where the things are fully opaque, adjust the blend threshold to give things a smooth nice edge.

  5. Experiment with Color Correction and Threshold: Color to remove green fringes from the parts of the image that are to be kept. Color correction subtracts the key color from the parts of the image that are kept. The color threshold controls how far into the image this is done.

Theory

The difference between the chroma key color and the color of each pixel in the target texture is calculated. This distance is weighted based on a threshold value, which weights how much of the hue, saturation and value should be used in the filtering. (The threshold value can only be specified in HSV color space.)

Example 1. Threshold Values and Their Effects
A threshold of [1.0, 0.0, 0.0] will only filter on hue (color tone). A threshold of [0.0, 1.0, 0.0] will only filter on saturation (intensity of color). A threshold of [0.0, 0.0, 1.0] will only filter on value (lightness of pixel / black and white intensity level).

The weighted distance from texture pixel to chroma key color is used to apply filtering depending on which region it is in:

  • Below Cut: The pixel is completely transparent

  • Between Cut and Blend: The pixel is blended from transparent to opaque

  • Below Color: The chroma key color is subtracted from the pixel

  • Above Color and Blend: The pixel is not changed

The Color Correction parameter determines how much of the chroma key color is to be removed from each pixel.