4.8. Sharpen (Unsharp Mask)

4.8.1. Wirkungsweise

Abbildung 17.43. Anwendungsbeispiel für das Filter »Schärfen«

Anwendungsbeispiel für das Filter »Schärfen«

Originalbild

Anwendungsbeispiel für das Filter »Schärfen«

Filter »Schärfen« angewandt


Out-of-focus photographs and most digitized images often need a sharpness correction. This is due to the digitizing process that has to divide a color continuum in points with slightly different colors. Elements smaller than the sampling frequency will be averaged into a uniform color. So sharp borders will be rendered a little blurred. The same phenomenon appears when printing color dots on paper.

The Sharpen filter (previously called Unsharp Mask) sharpens edges of the elements without increasing noise or blemish.

[Tipp] Tipp

Some imaging devices like digital cameras or scanners offer to sharpen the created images for you. We strongly recommend you disable this means of sharpening and use GIMP filters instead. This way you regain the full control over the sharpening of your images.

To prevent color distortion while sharpening, you can Decompose your image to HSV and work only on Value. Go to ColorsComponentsDecompose…. Make sure the Decompose to Layers box is checked. Choose HSV and click OK. You will get a new gray-level image with three layers, one for Hue, one for Saturation, and one for Value. (Close the original image so you won't get confused). Select the Value layer and apply your sharpening to it. When you are done, with that same layer selected, reverse the process by using Compose. Go to ColorsComponentsCompose…. Again choose HSV and click OK. You will get back your original image except that it will have been sharpened in the Value component.

4.8.2. Activating the Filter

This filter is found in the main menu under FiltersEnhanceSharpen (Unsharp Mask)….

4.8.3. Eigenschaften

Abbildung 17.44. Eigenschaften für das Filter »Schärfen«

Eigenschaften für das Filter »Schärfen«

Presets, Input Type, Clipping, Blending Options, Preview, Split view
[Anmerkung] Anmerkung

These options are described in Abschnitt 2, „Gemeinsame Funktionsmerkmale“.

Radius

The slider and input boxes (0.0-1500.0) allow you to set how many pixels on either side of an edge will be affected by sharpening. It is better to always sharpen an image at its final resolution.

Menge

This slider and input boxes (0.0-300.0) allow you to set the strength of sharpening.

Schwellwert

This slider and input boxes (0.0-1.0) allow you to set the minimum difference in pixel values that indicates an edge where sharpen must be applied. So you can protect areas of smooth tonal transition from sharpening, and avoid creation of blemishes in face, sky or water surface.

4.8.4. Wie funktioniert die »Unscharfe Maskierung«?

Eine unscharfe Maske zu verwenden, um ein Bild zu schärfen, erscheint zunächst sehr widersprüchlich. Daher folgt hier eine kurze Erklärung:

Stellen Sie sich ein Bild vor, welches an einer Stelle einen starken Kontrast aufweist. Die Helligkeitskurve der Pixel auf einer gedachten Linie durch diese Stelle zeigt einen steilen Anstieg. Die Kurve hat eine Stufenform (blau), wenn der Kontrast perfekt scharf ist, und ist S-förmig, falls der Kontrast unscharf ist (gelb).

Now, we have an original image with some blur (black curve) we want to sharpen. We apply some more blur: the intensity variation will be more gradual (green curve).

Let us subtract the difference between blurredness intensity (green curve) and the intensity of the original image (black curve) to the intensity of the original image (black curve). We get the red curve, which is more abrupt: contrast and sharpness are increased. QED.

Unsharp mask was first used in silver photography. The photographer first creates a copy of the original negative by contact, on a film, placing a thin glass plate between both; that will produce a blurred copy because of light diffusion. Then both films are placed in a photo enlarger, to reproduce them on paper. The dark areas of the positive blurred film, opposed to the clear areas of the original negative will prevent light to go through and so will be subtracted from the light going through the original film.

In der digitalen Bildbearbeitung, beispielsweise in GIMP, werden folgende Schritte ausgeführt:

  1. Öffnen Sie das Bild und duplizieren Sie es mittels BildDuplizieren

  2. Duplizieren Sie die zu schärfende Ebene in der Kopie des Bildes mittels EbeneEbene duplizieren und wenden Sie das Filter FilterWeichzeichnenGaußscher Weichzeichner mit der Methode»IIR« und einem Radius von 5,0 an.

  3. Ändern Sie den Modus der oberen Ebene in der Kopie des Bildes auf »Subtrahieren«. Führen Sie im Kontextmenü der Ebene die Funktion »Nach unten vereinen« aus.

  4. Ziehen Sie nun die entstandene Ebene in das Originalbild, wo es als neue Ebene eingefügt wird.

  5. Ändern Sie den Modus dieser Ebene auf »Addition«.

Voilà, das Bild ist geschärft. All diese einzelnen Schritte führt das Filter »Unscharf Maskieren« automatisch für Sie aus.

Am Beginn der Kurve können Sie eine Vertiefung erkennen. Wenn die Weichzeichnung sehr wirksam ist, kann diese Vertiefung sehr tief sein. Das Ergebnis der Subtraktion kann negativ sein und eine Farbverfälschung entlang der Kante verursachen, oder einen schwarzen Ring um einen Stern auf einem hellen, nebligen Hintergrund (Schwarze-Augen-Effekt).

Abbildung 17.45. Farbverfälschung durch Überschärfen (Schwarze-Augen-Effekt)

Farbverfälschung durch Überschärfen (Schwarze-Augen-Effekt)