Bug 109255 - Improvement suggestions for the Image Restoration tool
Summary: Improvement suggestions for the Image Restoration tool
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Plugin-Editor-Restoration (show other bugs)
Version: 0.7.3
Platform: Gentoo Packages Linux
: NOR wishlist
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-18 13:39 UTC by Dik Takken
Modified: 2022-01-17 22:16 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 7.6.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dik Takken 2005-07-18 13:39:37 UTC
Version:           0.7.3 (using KDE KDE 3.4.1)
Installed from:    Gentoo Packages
OS:                Linux

Some suggestions:

* The preview generation should be restarted when the user selects a different area in the preview image. Currently, you need to stop it manually every time you move the 'viewfinder'.

* The 'Smoothness' slider is sometimes not released by the mouse. After adjusting the slider, releasing the mouse button and moving the mouse away from the slider, the slider is still 'attached' to the mouse. As soon as you hover the mouse pointer above the slider, the slider is adjusted without touching the mouse buttons.

* Maybe it would be possible to progressively update the part of the preview image while the preview is being generated. Currently, you need to wait for the whole preview image to be calculated before you can see if the settings are any good or not.

By the way, this plugin is *really* amazing. I own a cheap Canon Powershot A400, which has quite a bit of noise (which results in lots of compression artifacts) and the image restoration plugin does a very good job to remove all the garbage without blurring things. It takes about 30 minutes to do one photograph but it's worth it.. Thanks a lot!
Comment 1 caulier.gilles 2005-07-19 07:57:32 UTC
Point 1 : I will try to find a solution at 0.8.0 release.

Point 2 : I'm using KDoubleNumImput object witch no have a mouse release event to detect when user have released the widget. I hope this point will be fixed in KDE 3.4 or later. Actually, i use a QTimer (500ms) to simulate the release event. If you have a better and simple solution without to re-writte the KDoubleNumInput widget.

Point 3 :no, I cannot do it with CImg API.

All DigikamImagePlugins dialog have be re-designed 'à la PowerRetouche' (Com. photoshop plugins - http://www.powerretouche.com). Now the preview and the dialog can be resized :

http://digikam3rdparty.free.fr/digiKamImageEditorPluginRestoration.png

Note: On my computer (PIV-3.2Ghz-1Gb), photograph restoration take 520s on a 3Mpixels image (without optimisation and in debug mode). I recommand you to recompile digikamimageplugins with optimized compilation options !

Thanks for your feedback.

Gilles Caulier
Comment 2 caulier.gilles 2005-07-21 16:01:17 UTC
SVN commit 437302 by cgilles:

Blowup, Inpainting, Restoration digiKam plugins : 'details' settings must be always < 'gradient' setting.

Restoration plugin : Because computation can be long, a new 'Try' button is added to dialog. Filter computation are disabled if at any settings or preview focus changes. 'Try' button must used instead.

CCMAIL: digikam-devel@kde.org
CCBUG: 109255   


 M  +14 -1     blowup/imageeffect_blowup.cpp  
 M  +1 -0      blowup/imageeffect_blowup.h  
 M  +22 -5     common/dialogs/ctrlpaneldialog.cpp  
 M  +2 -1      common/dialogs/ctrlpaneldialog.h  
 M  +1 -1      common/dialogs/imageguidedialog.cpp  
 M  +13 -0     inpainting/imageeffect_inpainting.cpp  
 M  +1 -0      inpainting/imageeffect_inpainting.h  
 M  +19 -38    restoration/imageeffect_restoration.cpp  
 M  +1 -0      restoration/imageeffect_restoration.h  
Comment 3 caulier.gilles 2005-07-21 16:03:02 UTC
Point 1 is fixed by last commits. Point 2 is now obsolete. I close this file.

Gilles Caulier
Comment 4 Maximilian Hombsch 2005-11-10 13:33:40 UTC
Some cameras do have red and green color flakes along with noise. For example the Canon Power Shot G1.
Those color flakes are very large and thus cannot be eliminated y blurring or restoring the image as is.
I found out that the color flakes and the noise are separated very well with YCrCb-transformation: (TV-Signal)
The Luminance Channel only has fine noise and thus needs but little restoration, so sharpness can be preserved.
reddishness Cr and bluishness Cb contain the color flakes.
They are blurry anyways and can be blurred very strongly with but little effect on the Image: only some color fringes occur.

Thus, I propose the following restoration algorithm:
1.Generate a flow Matrix based on RGB Channels (for edges with no luminance difference, for example blue / red)
2.Transform the Image into YCrCb
3.Correct Y (Luminance) seperately with settings for fine noise
4.Correct both Cr and Cb (color information) with very much smoothing
(both with the flow matrix based on RGB)
5.Merge the Image and transform back to RGB
Comment 5 Dik Takken 2005-11-10 13:56:06 UTC
A similar approach works very well for digital video camera's as well. You can blur the chroma channel very agressively, while the image does not seem to loose any details or sharpness. Blurring chroma is also great for reducing compression artifacts.

Maybe I should request a special chroma-blur filter...