Posts

Showing posts with the label Image Processing

Alpha Blending Matlab Code

Image
Ibg=imread('E:\IP\codes\flower.jpg'); Ifg=imread('E:\IP\codes\beetle.jpg'); if length(size(Ibg))==3         Ibg=rgb2gray(Ibg); end if length(size(Ifg))==3         Ifg=rgb2gray(Ifg); end alpha = 0.2; [row,col] = size(Ibg); I = zeros(row,col); I = uint8(I); for i = 1:row     for j = 1:col         I(i,j) = alpha * Ibg(i,j) + (1 - alpha) * Ifg(i,j);     end end subplot(1,3,1); imshow(Ibg); subplot(1,3,2); imshow(Ifg); subplot(1,3,3); imshow(I);

Auto Contrast Matlab Code

Image
I=imread('E:\IP\imgs\lena.jpg'); amin = 0; amax = 255; if length(size(I))==3         I=rgb2gray(I); end alow = min(min(I)); ahigh = max(max(I)); [r,c] = size(I); J = zeros(r,c); for m=1:r     for n=1:c         a = I(m,n);         a1 = amin +((a - alow) * ((amax - amin) / (ahigh - alow)));         J(m,n) = a1;     end end J = uint8(J); subplot(1,2,1); imshow(I); subplot(1,2,2); imshow(J);

Filters

Difference between Point Operation and Filters         Filters generally used   more than one pixel from the source image for computing each new pixel values. The capability of Point operation is limited. For example, In Point operation can't blur or sharpen an image.        

Definitions

Digital Image Processing: Manipulate a digitalized image using a computer. Digital Image Editing: Manipulation of digital images using an existing software application such as Adobe Photoshop or Corel Paint Pixel: The smallest addressable unit of an image. Histogram: Frequency distribution of image intensities.