MATLAB: Phase of an Image

fast fourier transform

Can anyon helpme in finding thenphase of this image

Best Answer

No, not unless you can get the original gray scale image. You can't do it from a pseudocolored image. If you have the gray scale image, do this
  1. subtract the mean: grayImage = double(grayImage) - mean2(grayImage);
  2. take the fft2: FT = fft2(grayImage)
Something like:
grayImage = imread('cameraman.tif');
subplot(2, 2, 1);
imshow(grayImage, []);
title('Original Image', 'FontSize', 20);
grayImage = double(grayImage) - mean2(grayImage);
% Take the FFT.
FT = fft2(grayImage);
% Display the phase image.
subplot(2, 2, 2);
imagImage = imag(FT);
imshow(log(imagImage), [])
title('Imaginary part of FT Image', 'FontSize', 20);
% Display the magnitude image.
subplot(2, 2, 3);
realImage = real(FT);
imshow(log(realImage), [])
title('Real Part of FT Image', 'FontSize', 20);