- Visual Media Processing Using Matlab Beginner's Guide
- George Siogkas
- 237字
- 2021-08-06 16:37:55
Contrasting enhancement using imadjust
A more gentle method for contrast enhancement is using imadjust
. In its default form, this function maps pixel values in the original image to new, altered values while ensuring that only a small percentage (1 percent) of the values are saturated at low and high intensities of the original image. This results in a smoother transformation that mostly enhances useful details. We can see the result of applying this method if we add some more lines to our previous script:
img = imread('my_image.bmp'); img_eq = histeq(img); img_adj = imadjust(img); subplot(2,3,1),imshow(img),title('Original Image'); subplot(2,3,2),imshow(img_eq),title('Equalized Image'); subplot(2,3,3),imshow(img_adj),title('Adjusted Intensity Image'); subplot(2,3,4),imhist(img,64),title('Original Image Histogram'); subplot(2,3,5),imhist(img_eq,64),title('Equalized Image Histogram'); subplot(2,3,6),imhist(img_adj,64),title('Adjusted Image Histogram');
If we save this script as HisteqVsImadjust.m
and execute it, we get the following screenshot:

It is obvious just by looking at the histograms, that imadjust
stretches the histogram of the image, while histeq
spreads it almost evenly. This is why the result of imadjust
looks more natural.
In case we want more control over the final result, we can either tweak the methods used by defining more inputs that adjust the settings. For instance, we can provide a target histogram in histeq
or a set of lower and higher limits for values that we want to clip in imadjust
. You can play with these settings by using Help to see how the two functions can be used with extra inputs and then experiment with different input values.
- 電腦軟硬件維修大全(實(shí)例精華版)
- micro:bit魔法修煉之Mpython初體驗(yàn)
- 筆記本電腦維修實(shí)踐教程
- 基于Proteus仿真的51單片機(jī)應(yīng)用
- 單片機(jī)技術(shù)及應(yīng)用
- Spring Cloud微服務(wù)和分布式系統(tǒng)實(shí)踐
- Istio服務(wù)網(wǎng)格技術(shù)解析與實(shí)踐
- 圖解計算機(jī)組裝與維護(hù)
- Wireframing Essentials
- Mastering Machine Learning on AWS
- 微服務(wù)實(shí)戰(zhàn)
- Instant Website Touch Integration
- 創(chuàng)客電子:Arduino和Raspberry Pi智能制作項(xiàng)目精選
- 計算機(jī)組裝與維護(hù)
- Practical Artificial Intelligence and Blockchain