FFT(f2)
FFT(f3)
100
100
分析:与2中的频谱图比较可得,f3的频谱也顺时旋转了90度。 (三)、任意图像的频谱显示
1.读入图像lena_gray.tif,计算该图像的频谱,并将频谱原点移到中心位置显示。 lena=imread('d:\test_images\lena_gray.tif','tif'); S=log(abs(fft2(lena)));
subplot(1,2,1);mesh(S);title('orign'); fc=log(abs(fftshift(fft2(lena))));
subplot(1,2,2);mesh(fc);title('move to center');
结果: