# Image Enhancement Techniques with Matlab code

Updated on February 14, 2011

## Image Enhancement techniques that we will be looking at with matlab code:

1. Image Negative
2. Gray level slicing with and without background
3. Bitplane Slicing with 3 and 7 bits
4. Image Darkening or Lighting
5. Thresholding

## Matlab Code

### % Bit Plane Slicing for plane no.7for i = 201:300 for j = 201:400 if bitget(rp(i,j,1),7)==1 rp(i,j,1) = 255; else rp(i,j,1) = 0; end if bitget(rp(i,j,2),7)==1 rp(i,j,2) = 255; else rp(i,j,2) = 0; end if bitget(rp(i,j,3),7)==1 rp(i,j,3) = 255; else rp(i,j,3) = 0; end endendimshow(rp);

The above enhancement techniques have been used on a part of image and the whole image. Please check the image above and the corresponding matrix with it. For any difficulties kindly leave your comment.

## Popular

164

12

• ### C Program Code for Addition of Two Polynomials using Arrays

22

0 of 8192 characters used

• mtabe

2 years ago

i need codes for counting bacteria saikimu@live.com

• Rincy

2 years ago

how the threshold value of the image will be chosen

• sakshi

4 years ago

sir above code is not running error at line 12 darkening

• Archana Kumari

4 years ago

My project topic is "PDE-based enhancement of color images in RGB space" can u send me code for this in matlab. If u can pls mail me at

archana.kumari1503@gmail.com

• Nikhil Xavier

4 years ago

This code is user friendly but not executed .I have tried,,

4 years ago

sir i need the code for image inhachment please send me the code

thakns

my e-mail id is anshuldv001@gmail.com

• gfdd

4 years ago

Explain Bit-level slicing as applied on images. Which process of analog-to-digital conversion does it coincide with? Explain how can we perform bit level slicing using Bitwise AND operation. Also write a

Matlab program to demonstrate the same.

• RESHMI VP

4 years ago

respected sir,

i would like to get opencv or matlab code as part by part or fully for my project titled an inpainting assisted stegnographic scheme using histogram shifting. pls do sent to my mail id reshmivp88@gmail.com

• priti

4 years ago

My project topic is "PDE-based enhancement of color images in RGB space" can u send me code for this in matlab. If u can pls mail me at preeti.cool03@gmail.com.

• senthilbabu.D

5 years ago

Respected Sir,

i need the code for cotrast enhancement using wavelets. if u can, pls mail me. senthilbabu.d@gmail.om

• kevin g

5 years ago

kool ireng

• Narayan

5 years ago

Sir I need code for iris detection.........plz mail me at shri.07@gmail.com

• ashwini

5 years ago

sir i need d code for mri segmentation of osteoarthritic knees

• Vijay

5 years ago

Hello Sir,

I need command used for image enhancement using FFT kindly help me out with this. I will be very thankful to you.

pLease mail me the command on vjy.rwt@gmail.com

• Saranyan

5 years ago

Thanks Rithesh.... Its working

• rahul anand

5 years ago

can i get the image enhancemnet coding using GPCM

• SANTOSH KUMAR MEHTA

5 years ago

This code is user friendly but not executed .I have tried.

• angela

6 years ago

i hav tried grylevel slicing but it hides the other processes running on???

• Ahasan Habib

6 years ago

This code is well.

But I need a source code for Image resolution enhancement using Inter-subband Correlation in Wavelet Domain.

I will be grateful to u ,if u send that code.Pls send it.

• ng

6 years ago

thank u for sharing ...

• roshan

6 years ago

thank you

• supriya

6 years ago

i tried to exicute this prog, but i couldnt do it giving so many errors

• AUTHOR

riteshkothari1990

6 years ago

press f5 and it should work....

• Njoud

6 years ago

hi , i m trying to use matlab to make bit plane slicing , i copy the code but my question is how to show the result ?

working