image = | laplacianDoGDeblur2dImg (inImg,inStdDev) |
image = | laplacianDoGDeblur2dImg (inImg,inStdDev,inOptStdDevFactor,inOptSmoothingGaussianCoverage) |
2d image deblur algorithm using Laplacian kernels based on a difference of Gaussian approximation
Two dimensional image deblur algorithm based on an approximation of the Laplacian filtering. Hence, the algorithm needs the parameters of the Laplacian filter, at least the input standard deviation . The restored image
is computed as follows :
Where is the convolution operator,
is the Laplacian kernel and the Laplacian DoG 2d filtering algorithm is used to compute
.
The principle of the debluring algorithm is illustrated as described in the following figure in the 1d case :
The convolution of the blurred signal with the Laplacian kernel (in red) is added to the blurred signal itself (in black). The edge is enhanced in the resulting signal (in green).
The algorithm yields edge-enhanced images with ipsdk::imaproc::attr::InStdDev < 1.2, ipsdk::imaproc::attr::InOptStdDevFactor > 1.4 and an gaussian ratio > 0.7 (see ipsdk::imaproc::attr::InOptGradientGaussianCoverage).
Here is an example of a deblurring operation applied to two 8-bits different images:
(second image by Ru_dagon (Own work) [GFDL (http://www.gnu.org/copyLeft/fdl.html), CC-BY-SA-3.0 (http://creativecommons.org/licenses/by-sa/3.0/ ), via Wikimedia Commons])