How to subtract background from an image?

Matlab- Saving an image?

  • I wanted to know what is the difference between imshow(I2, []) and imshow(I2) I checked out your post on Background Illumination and the image is dark when using only imshow(I2) while the image is great when using imshow(I2, []) The problem I am facing now is that I want to use the good image and perform histeq on it .... But when using I3=(I2,[]) -----Error I3=histeq(I2,[])---Error... How to pass on the good image to another variable so that I can perform other operations on it... Can you please help me... I am new to matlab.... Thanks a lot... The code I am using: I = imread('image.jpg'); backApprox = blkproc(I,[16,16 ],'mean(x(:))'); backApprox = (backApprox)/255; % Convert image to double. figure, surf(backApprox); set(gca,'ydir','reverse'); % Reverse the y-axis. backApprox256 = imresize(backApprox, [64 512], 'bicubic'); figure, imshow(backApprox256) % Show resized background image. I = im2double(I); % Convert I to storage class of double. I2 = I - backApprox256; % Subtract the background from I. I2 = max(min(I2,1),0); % Clip the pixel values to the valid range. figure, imshow(I2,[]);-Good Image figure, imshow(I2);-Dark Image

  • Answer:

    b=a[:,:]

ashvin a at Yahoo! Answers Visit the source

Was this solution helpful to you?

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.