Deinterlacing

From Wikipedia, the free encyclopedia

Jump to: navigation, search

Deinterlacing is the process of converting interlaced video, like common analog television signals, into a non-interlaced form.

Contents

[edit] Background

Video and Film consist of a series of images played in rapid succession. Each of these images is known as a frame. Unlike a film frame, which is a single entity, a video frame is composed of multiple scan lines.

All mainstream analog television systems and many digital systems arrange scan lines of one frame into two fields. One field contains all even lines, another field contains all odd lines. The fields are then displayed in succession with a rate twice faster than the nominal frame rate. For instance, PAL and SECAM systems have rate of 25 frames/s or 50 fields/s, while the NTSC system delivers the rate of 30 frames/s or 60 fields/s. The process of producing half-resolution fields at double the frame rate is known as interlacing.

In footage shot by most television and video cameras (except more recent models which allow a non-interlaced mode), the two fields of a frame are taken at different times, which results in an effectively doubled time resolution as compared with non-interlaced footage, thus enhancing motion perception to the viewer. This remains one of the benefits of interlacing.

However its benefits can only be experienced if the display shows the individual fields in the same timely order they were shot in. At this time, only traditional CRT-based TV set are capable to do so. If correctly adjusted, they need not suffer from any interlacing artifacts, they even benefit from it.

Yet when the fields of the original footage are displayed in a different order than they were shot in (i.e. when two fields taken at different points in time are re-combined to a full frame displayed at once), visual defects called interlace artifacts or combing occur with moving objects in the image.

This is true for most modern LCD and plasma displays, because they are currently not able to work in interlaced mode. The problem only exists with SD television and interlaced HDTV, and there only with material shot with a tv or video camera, not with movies. Progressive HDTV video consists of full frames and does not exhibit interlace artifacts. Also computer displays don't suffer from it as their image isn't interlaced to begin with.

To combat interlace artifacts, all LCD and plasma consumer television sets have built-in circuitry that converts interlaced video into progressive video.

The process of converting interlaced video into progressive is called de-interlacing. If done poorly, de-interlacing can introduce image degradation.

[edit] Basic concept

In a typical CRT television, the interlaced display draws only half of the lines on the screen for each frame, alternately drawing the odd and even lines for each frame. This reduces flicker by taking advantage of the persistence of vision effect, producing a refresh rate of double the frame rate without the overhead of either transmitting each frame twice or holding it in a buffer so it can be redrawn.

When displaying video on a display that can support a high enough refresh rate such that flicker isn't perceivable, interlaced video can be deinterlaced for better viewing; likewise when a display cannot interlace but must draw the entire screen each time, the video must be deinterlaced before it can be displayed. All current displays except for CRT screens require deinterlacing. Though in principle there is no reason why LCD, DLP or Plasma displays should not display two fields sequentially, the requirement that half of the pixels remain black would result in a halving of brightness, even assuming that the response time of the technology could be made fast enough.

Deinterlacing requires the display to buffer one or more fields and recombine them into a single frame. In theory this would be as simple as capturing one field and combining it with the next field to be received, producing a single frame. However the originally recorded signal was produced as a series of fields, and any motion of the subjects during the short period between the fields is encoded into the display. When combined into a single frame, the slight differences between the two fields due to this motion results in a "tearing" effect where alternate lines are slightly displaced from each other.

Modern deinterlacing systems therefore buffer several fields and use techniques like edge detection in an attempt to find the motion between the fields. This is then used to interpolate the missing lines from the original field, reducing the "tearing" effects.[1]

[edit] Deinterlacing methods

There are various methods to deinterlace video, each producing different problems or artifacts of their own. Some methods are much cleaner in artifacts than other methods. All are indeed not equal.

Most de-interlacing techniques can be broken up into three different groups all using their own exact techniques. The first group are called Field Combination De-interlacers, because they take the even and odd fields and combine them into one image or frame which is then displayed. The second group are called Field Extension De-interlacers because each field (with only half the lines) is extended to the entire screen to make a frame. The third type use a combination of both and fall under the banner of Motion Compensation and a number of other names.

[edit] Field Combination Deinterlacing

  • Weaving is done by adding consecutive fields together. This is fine when the image hasn't changed between fields, but any change will result in artifacts known as "mouse teeth" or "tearing", when the pixels in one frame do not line up with the pixels in the other, forming a jagged edge. This technique retains full vertical resolution at the expense of half the temporal resolution.(Motion)
  • Blending is done by blending, or averaging consecutive fields to be displayed as one frame. The mouse teeth are avoided because both of the images are on top of each other. This instead leaves an artifact known as ghosting. The image loses vertical resolution and temporal resolution. This is often combined with a vertical resize so that the output has no numerical loss in vertical resolution. The problem with this is that there is a quality loss, because the image has been downsized then upsized. This loss in detail makes the image look softer. Blending also loses half the temporal resolution since two motion fields are combined into one frame.
  • Selective blending, or smart blending or motion adaptive blending, is a combination of weaving and blending. As areas that haven't changed from frame to frame don't need any processing, the frames are weaved and only the areas that need it are blended. This retains full vertical resolution, half the temporal resolution, and has fewer artifacts than weaving or blending because of the combination of them both.
  • Inverse Telecine: Telecine is used to convert a motion picture source at 24 frames per second to interlaced TV video in countries that use NTSC video system at 30 frames per second. Countries which use PAL at 25 frames per second do not use Telecine since motion picture sources are sped up 4% to achieve the needed 25 frames per second. If Telecine was used then it is possible to reverse the algorithm to obtain the original non-interlaced footage (which has a slower frame rate). In order for this to work, the exact telecine pattern must be known or guessed. Unlike most other deinterlacing methods, when it works, inverse telecine can perfectly recover the original progressive video stream.
  • Telecide-style algorithms: If the interlaced footage was generated from progressive frames at a slower frame rate (e.g. "cartoon pulldown"), then the exact original frames can be recovered by copying the missing field from a matching previous/next frame. In cases where there is no match (e.g. brief cartoon sequences with an elevated frame rate), then the filter falls back on another deinterlacing method such as blending or line-doubling. This means that the worst case for Telecide is occasional frames with ghosting or reduced resolution. By contrast, when more sophisticated motion-detection algorithms fail, they can introduce pixel artifacts that are unfaithful to the original material. For telecine video, decimation can be applied as a post-process to reduce the frame rate, and this combination is generally more robust than a simple inverse telecine (which fails when differently interlaced footage is spliced together).

[edit] Field Extension Deinterlacing

  • Half-sizing displays each interlaced frame on its own, resulting in a video with half the vertical resolution of the original, unscaled. While this method retains all vertical resolution and all temporal resolution it is understandably not used for regular viewing because of its false aspect ratio.
  • Line doubling takes the lines of each interlaced field (consisting of only even or odd lines) and doubles them, filling the entire frame. This results in the video having a frame rate identical to the field rate, but each frame having half the vertical resolution, or resolution equal to that of each field that the frame was made from. Line doubling prevents combing artifacts but causes a noticeable reduction in picture quality since each frame displayed is doubled and really only at the original half field resolution. This is noticeable mostly on stationary objects since they bob up and down. This technique is also called bob deinterlacing for this reason. Line doubling retains horizontal and temporal resolution at the expense of vertical resolution and bobbing artifacts on stationary and slower moving objects. A variant of this method discards one field out of each frame, halving temporal resolution.

[edit] Motion Compensation

The best deinterlacers combine all of the methods mentioned above, both field combination and frame extension. This technique is often called motion compensation. Deinterlacers that use this technique are often superior because they can use information from many fields, as opposed to just one or two. For example, if two fields had a person's head moving to the left, then if weaving was applied, mouse teeth would appear. If blending was applied, ghosting would appear. Selective blending would also create ghosting. Both of the frame extension methods would have no artifacts and would be the best selection for this motion section of the scene. Advanced motion compensation (ideally) would in addition see that the face in both fields is the same, just transposed, and would combine the face (i.e. through image stacking) to get full detail in both output frames. Doublers as above don't provide combined field resolution in this form. This technology would need to be combined with a scene change detection algorithm, otherwise it will attempt to find motion between two completely different scenes. In the areas that it cannot find a motion match, it could fall back on selective blending. If frame rate was to be preserved it could fall back on doubling.

The best de-interlacers, (In the case of NTSC) also determine whether video material source was from film by checking for a 3:2 pulldown Telecine sequence. They automatically do a reverse telecine instead of the above deinterlacing techniques in this case. This operation is more automatic on modern deinterlacers than it used to be.

[edit] Interlacing in HDTV

The European Broadcasting Union has argued against the use of interlaced video in production, recommending the use of 1080p/50 frame/s (frames per second) as a future production standard for easier conversion to other formats.[2]

Televisions and monitors are now more flexible at displaying different video formats than they were in the past. Most movies on Blu-ray discs have preserved the original non interlaced 24 frame/s motion film rate and allow output in this non-interlaced format directly to display devices, with no conversion necessary. At present (2008), Blu-ray does not support 1080p at 50frame/s, but does support 720p at 50frame/s and all interlaced formats.

Some 1080i HDV camcorders offer progressive mode with cinema-like frame rates of 24 or 25 frame/s, using techniques similar to the traditional telecine technique in NTSC countries and the 25 frame/s in PAL countries. Progressive frames are packaged within the interlaced signal and can be reproduced by standard consumer television equipment.

Deinterlacing is often called line doubling in many cases. There is confusion when this is referred to as interpolation, which uses spatial filtering to generate extra lines and hence reduce the visibility of pixelation on any type of display.[3] The terminology 'line doubler' is used more frequently in high end consumer electronics, while 'deinterlacing' is used more frequently in the computer and digital video arena. However, both are essentially the same thing in most cases.

[edit] Where deinterlacing is done

Deinterlacing can be done at various points in the chain from filming to watching. The stage at which it is done can affect the quality of the conversion, because the quality of the deinterlacer can vary.

  1. If it is done in the filming studios, it should be done very well. The people doing it are professionals, and have minimal time constraints. They should also have access to expensive and powerful deinterlacers.
  2. If it is done at the time of broadcasting, the quality of the deinterlace can vary. It should be organised by professionals, who have a reasonable budget and powerful processors. On the other hand, it needs to be done in real time, so the effort that the deinterlacer can put in is limited by time.
  3. If it is copied onto a computer and processed there, the quality can also vary immensely, yet (theoretically) a high quality level should be possible, because there are no restrictions on time and there are some very good, free, deinterlacers. However, many people who do this do not know much about deinterlacing, and when making a choice about which deinterlacer and settings to use, will make a random decision. This often causes poor results for video based content as many people are unaware that video has double the temporal resolution of film. To top it off, many codecs/players do not allow selecting deinterlacing method, but some do.[4]
  4. If done by an embedded electronic device, the quality varies depending on the overall quality of the device. High-quality electronic devices are in many cases defined by their deinterlacing ability.

[edit] See also

[edit] References

[edit] External links

Personal tools