Matting (computer graphics)

from Wikipedia, the free encyclopedia

In computer graphics, matting is the separation of the foreground and background of an image for further use in the image composition .

approaches

When matting, it is assumed that the present image was created as a convex combination of foreground and background:

Here is for the foreground (Engl. Foreground ) and the background (Engl. Background ). The aim of the Matting, it is now, and to determine if is given. So it's an under-determined equation: there is too little information to solve the problem clearly.

Blue screen matting

This procedure is originally from the film . The object is filmed or photographed against a monochrome, usually blue, background. Then all pixels are selected that do not have this constant color.

This procedure assumes, however, that the foreground object is not transparent: a translucent item of clothing, for example, would shimmer blue in front of a blue screen, even if it was placed in a new background. This leads to an unnatural appearance, as can be seen in the early action films doing stunts in front of an artificial backdrop.

Difference Matting

Here, too, a familiar background is used, but it no longer has to be monochrome. Instead you film or photograph the scene twice: once with and once without a foreground object. If you now extract all the pixels of the image with foreground that differ from the image without foreground, you get the matt of the foreground object. However, there are similar problems as with blue screen matting. In particular, the idealized studio requirements are a shortcoming of both methods.

Natural image matting

If you want to extract the foreground of a natural image without additional restrictions, you need more complex algorithms. In most cases, the user has to roughly specify which image areas are definitely foreground or background. On the basis of this preselection, an attempt is then made to assign a value to the pixels of the unknown area . In addition, an attempt is made to determine the color of the foreground image (sometimes also the color of the background image). Matting is therefore more than just a blurred segmentation.

There are different approaches to this. One can try to determine the missing values ​​using statistical methods , e.g. B. as the mean of the nearby known pixels. Other approaches use stochastic theorems and still others use interpolation or differential equations .

See also