2.8. 물체 선택 도구

그림 14.34. The Foreground Select tool in the Toolbox

The Foreground Select tool in the Toolbox

This tool lets you extract the foreground from the active layer or from a selection. With GIMP-2.10, selection refinement has been improved. After the selection is made, with its marching ants, you can copy-paste or click-and-drag it to another image used as background,and, inverting the selection, you can can make changes in background.

2.8.1. 도구 선택하기

물체 선택 도구는 다음 두 가지 방법을 통해 사용할 수 있습니다.:

  • by clicking on the tool icon in the Toolbox,

  • through ToolsSelection ToolsForeground Select in the image menu.

  • This tool has no shortcut, but you can set one using EditPreferencesInterfaceConfigure Keyboard ShortcutsToolsForeground Select

2.8.2. 사용법

Let us start with an object distinctly different from background, not needing to be refined.

  1. Roughly select the foreground you want to extract. When you select this tool, the mouse pointer goes with the lasso icon. It actually works like the Free Select tool. Select as little as possible from the background.

    When the mouse pointer comes over line beginning, a small yellow circle appears: release mouse button to close selection. While selecting, click-and-drag draws a fuzzy line, drag only draws a straight line.

    If the mouse pointer doesn't cover start point, double clicking closes selection with a straight line.

    The selection is closed.

    As soon you click to start drawing, a small window pops up:

    For the moment, only a little cross is active, allowing to quit: returns to the original image.

  2. Press Enter to create the mask:

    The mouse pointer goes now with the Paint-brush icon. The dark blue area (this color can be changed) is for background. The light blue area covers the zone you have selected, on which you will paint to extract foreground. It contains the foreground area and a small part of background. Outside the selected area, the dark blue area is named Unknown pixels area.

    Options in the small window become active:

    • A Preview mask checkbox that toggles displaying a preview of the foreground extraction status.

    • A Select button that will be used to create the extraction after marking the foreground.

  3. 물체를 따라 선 그리기 : 붓 도구를 이용하여 선택된 영역에 있는 물체를 따라 연속된 선을 그립니다. 붓의 크기는 옵션을 통해 조절할 수 있습니다. 선 색상은 아무런 관계가 없으나 가급적이면 선택하려는 물체와 같지 않은 색이 좋습니다. 그리고 배경부분을 선택하지 않도록 주의하세요.

    With this one-color object distinctly different from background, a few strokes are enough:

  4. Toggle preview to verify result.

    [참고] 참고

    This Preview mask is a mask: you can draw directly on it and see result immediately.

  5. Try Matting Levin engine that may improve result.

  6. When you are satisfied with result, click on Select button to get the selection of the foreground with its marching ants.

2.8.3. Options

그림 14.35. 물체 선택 도구 선택 사항

물체 선택 도구 선택 사항

Normally, tool options are displayed in a window attached under the Toolbox as soon as you activate a tool. If they are not, you can access them from the image menu bar through WindowsDockable WindowsTool Options which opens the option window of the selected tool.

Mode; Feather edges
[참고] 참고

모든 선택도구에 동일하게 적용되는 선택사항은 선택 도구 를 참조하세요. 여기서는 사각 선택 도구에만 적용되는 특수한 선택 사항에 대해 설명할 것입니다.

Draw mode

Draw foreground: to draw what will be foreground.

Draw background: to draw what will be background.

Draw unknown: to add to your selection pixels that are in background.

Stroke width

The size of the brush.

Preview mask

You can adapt the color of the preview to your image.

Engine

Work with Matting global(default) and improve result with Matting Levin.

Iterations

Default is 1. Repeating algorithm may improve result.

2.8.4. Refining Foreground Extraction

In most images, foreground is not distinctly different from background. Refining selection allows you now to extract these foregrounds. Procedure steps are the same as above, but, during drawing foreground, you will often toggle Preview, use Zoom (+ key), Draw background to delete unwanted background extraction areas. You can also work directly on Preview mask.

그림 14.36. Example for Draw background

Example for Draw background

On the left: drawing foreground ill-advisedly went over background area: a part of background will be included in foreground selection!

In middle: Draw background option is checked: draw on inclusion and unwanted pixels.

On the right: unwanted selected pixels in background are no longer in foreground selection.


그림 14.37. Example for Draw unknown

Example for Draw unknown

On the left: the selection left a small part of foreground unselected, in unknown pixels area.

On the right: with Draw unknown option checked, draw on unselected pixels. They are now selected.