Repairing images with Resynthesizer and G'MIC
|
First Steps
Once installed, the tool appears in Filters | Enhance | Heal selection , as well as under Filters | Map | Resynthesize . The tool is very easy to access thanks to multiple menu entries.
To remove areas from an image, make a selection and then call Heal selection . Depending on the distribution and installation, you see one of the two dialogs in Figure 4. The parameters are largely self-explanatory. If you see the second version of the dialog, you can experiment with Filling order , which refers to the order of filling, and Sample from , which you use to define the origin of the material.
If you are not getting the results you want, you can do two things: either recall the function with Ctrl+F and check to see what has changed or change the selection. Sometimes it helps to move the selection somewhat or modify its size to achieve better results.
The Heal selection filter can also restore corners of images that are often be lost when "stitching" a panorama together. It occurs because information is missing in the relevant areas. Figure 5 illustrates the problem. The panorama does not have individual images that can provide information about the corners. Even so, Resynthesizer can compute these relatively well.
G'MIC Inpaint
You can also use G'MIC plugins [5] to tackle problems associated with the removal of image areas. However, the corresponding filters are still not well documented.
Because G'MIC is pre-compiled, you can install it in a jiffy. The software comes in two versions: a standalone program that runs on the command line, even without Gimp, and a Gimp plugin, which you save to the plugin directory, as you did the Resynthesizer tool. Numerous distributions also offer suitable packages with names like gmic for the standalone program and gimp-gmic for the plugin version.
Ubuntu users can install the plugin with:
sudo apt install gimp-gmic
"Inpainting" is largely a restoration procedure that seamlessly covers selected areas with other areas [6]. In certain respects, the methods applied are similar to those of the Resysnthesizer tool. However, in practice, the use and the results are different for each tool. G'MIC currently offers no fewer than five versions of the procedure under Filters | G'MIC | Repair :
- Inpaint [holes] closes transparent areas.
- Inpaint [morphological] uses a mask to designate the area.
- Inpaint [patch-base]> uses small stitches for the procedure.
- Inpaint [multi-scale] combines procedures 2 and 3.
- Inpaint [transport-diffusion] , the most recent version, diffuses material in the masked region.
Each of these methods has distinct advantages and disadvantages. The example shown in Figure 6 illustrates the performance capability of Inpaint [holes] . This filter closes the gap in the checkered flower completely after a few repetitions. The result is so good that the outcome is very difficult to distinguish from the original.
At times, you need to get creative. In this example, the filter was applied experimentally with default settings. It did not completely cover the hole. The newly created layer was blended into the original layer via Layer | Merge Down and the layer was used again. Increased values for Tolerance and Maximal area then closed the rest of the hole.
Another method that has barely been documented but that achieves surprisingly good results (Figure 7) uses Inpaint [patch-based] . This method works directly on the image to be restored and lets you mark the areas that need editing with color (Mask color ). The filter replaces the marked areas immediately with small insert pieces from the environment that the plugin selects in such a way that the structure is maintained.
« Previous 1 2 3 Next »
Buy this article as PDF
Pages: 5
(incl. VAT)