In: Computer Science
MATLAB code:
using Laplacian mask enhance for image "ngc6543.jpg".
This will be done by locallapfilt
which will
approximate the algorithm by discretizing the intensity range into
a number of samples defined by the
'NumIntensityLevels
' parameter. This parameter is used
to balance speed and quality. The parameter is set to 100 here.
A = imread('ngc6543.jpg');
imshow(A)
%Using a sigma
value to process the details and an
alpha
value to increase the contrast, effectively
enhancing the local contrast of the image.
sigma = 0.2; alpha = 0.3;
%The value of sigma and alpha can be adjusted to apply various filters on the image
B = locallapfilt(A, sigma, alpha, 'NumIntensityLevels', 100);
imshow(B)
Applying the above enhancements to the image:
Results in:
Hope this helped. Please do upvote and if there are any queries please ask in comments section.