Chromashift filters

1. Preface

Sometimes the capture of vhs-recordings can have chromashifts. This means that one or more colors are shifted in a direction (vertical or horizontal). Take a look at the following clip:

If you look at the trousers and jackets of the girls, you see that the blue has shifted some pixels to the right. Likewise the green (of the gras) has shifted some pixels to the right. Luckely, there are VirtualDub and AviSynth plugins which can do something about this. For VirtualDub "flaXen VHS Filter" can be used, and for AviSynth the plugin "ChromaShift" is available. In both plugins the chrominance can be adjusted. The process of shifting should be done before any smoothing.

2. Some theory

A PAL signal uses YUV. There is one component that represent brightness (Y or luminance) and two other components that represent color (UV or chrominance). The chrominance consist of two components:

U = Cb = blue difference sample: increasing U => pixels turns from green into blue

V = Cr = red difference sample: increasing V => pixels turns from green into red

A NTSC signal uses YIQ. Also here there is one component that represents birghtness (Y or luminance) and two other components that represent color (IQ or chrominance). The IQ plane is just a rotation of the UV plane (of 33 degrees).

There is horizontal and vertical chromashifting. They are both caused by your video recorder or camcorder, but they have different causes:

Color Bleed (horizontal chromashifts) is the effect seen on video tapes where strong colors seem to spread out from their correct places and "bleed" into adjacent areas. This is especially noticeable on strong reds but normally occurs on all colors equally, being simply more obvious on reds and to a lesser extent on blues.

VHS stores luma with 3.0 MHz bandwidth, and the chroma is stored with about 0.6 MHz, so there are about 240 lines of luma you can store and 40 lines of chroma. In other words the colorness is strongly reduced. This causes bright colours to spread, but providing they stay in the correct position they can still look sharp. However very often video recorders do not reproduce the color in exactly the correct position, but cause it to shift left or right a bit.

Color Droop (vertical chromashifts) is the effect seen on video tapes where colors seem to drop below their correct places and "droop" into adjacent areas, leaving the top of strongly coloured areas often colourless and non-coloured areas below strongly coloured ones tinted at the top. This is especially noticeable on strong reds but normally occurs on all colours equally, being simply more obvious on reds and to a lesser extent on blues.

One problem is that the PAL and SECAM color decoders use delay lines for optimum color accuracy with the inevitable effect of some small colour droop (theoretically one half of a TV line). Another problems is that  many video recorders use delay lines in an attempt to improve performance and reduce color noise, but again with the same effect. Both uses of delay lines are a deliberate compromise to give you the best overall quality and individually these effects are usually acceptable but when combined, e.g. by several generations of copying, the color droop becomes very obvious and annoying. In fact even single generation copies of broadcast material can show noticeable color droop!

References:
Color bleed: About color bleeding.
Color droop: About color drooping.
Leopold's Home Video Formats Page: About horizontal/vertical luminance and chrominance resolutions of various video formats.
Video Color Resolution: Semitechnical Explanation of I and Q versus U and V.
Charles Poyton's ColorFAQ: ColorFAQ including the conversion formulas between IQ and UV (page 17).

3.1 Virtualdub usage

Get "flaXen VHS Filter 1.0". The blue and green must be shifted to the left. We lowered both the "Chroma I" and the "Chroma Y" values (make sure that the NEGative checkbox is checked).

The result is as follows:

Proceed with the VirtualDub post processing guide.

3.2 AviSynth v2.0x / AviSynth v2.5x / GordianKnot Usage

Get the ChromaShift plugin. Using this plugin the "U" and "V" values can be adjusted separately, but also together using the "C" value. The corresponding line for the script becomes:

ConvertToYUY2()  # plugin requires YUY2
ChromaShift(C=-6)

or what is exactly the same:

ConvertToYUY2()  # plugin requires YUY2
ChromaShift(U=-6, V=-6)

The results are pretty much identical as when using the "flaXen VHS Filter".

Have a look at the following clip:

This one is messed up very much. Green is shifted to the left, while blue and red are shifted to the right. The Chromashift plugin can only shift the two luma components separately, but not all three components. To my knowledge there is no plugin which can correct this clip.

Proceed with the AviSynth post processing guide.


Back to VirtualDub postprocessing: <BACK>

Back to AviSynth postprocessing: <BACK>

Back to the Index: <HOME>


Last edited on: 09/07/2003 | First release: n/a | Author: Wilbert | Content by doom9.org