图像处理-FFT
来源:互联网 发布:龙猫 知乎 编辑:程序博客网 时间:2024/06/04 01:14
im = im2double( rgb2gray( imread('3.png')));% “im” should be a gray-scale floating point image
[imh, imw] = size(im);
fftsize = 1024; % should be order of 2 (for speed) and include padding
im_fft = fft2(im, fftsize, fftsize); % 1) fft im with padding
hs = 30; % filter half-size
fil = fspecial('gaussian', hs*2+1, 10);
fil_fft = fft2(fil, fftsize, fftsize); % 2) fft fil, pad to same size as image
im_fil_fft = im_fft .* fil_fft; % 3) multiply fft images
im_fil = ifft2(im_fil_fft); % 4) inverse fft2
im_fil = im_fil(1+hs:size(im,1)+hs, 1+hs:size(im, 2)+hs); % 5) remove padding
subplot(1,2,1)
imshow(im)
subplot(1,2,2)
imshow(im_fil)
figure(2)
subplot(1,2,1)
imagesc((abs(fftshift(fil_fft))))
subplot(1,2,2)
[imh, imw] = size(im);
fftsize = 1024; % should be order of 2 (for speed) and include padding
im_fft = fft2(im, fftsize, fftsize); % 1) fft im with padding
hs = 30; % filter half-size
fil = fspecial('gaussian', hs*2+1, 10);
fil_fft = fft2(fil, fftsize, fftsize); % 2) fft fil, pad to same size as image
im_fil_fft = im_fft .* fil_fft; % 3) multiply fft images
im_fil = ifft2(im_fil_fft); % 4) inverse fft2
im_fil = im_fil(1+hs:size(im,1)+hs, 1+hs:size(im, 2)+hs); % 5) remove padding
subplot(1,2,1)
imshow(im)
subplot(1,2,2)
imshow(im_fil)
figure(2)
subplot(1,2,1)
imagesc((abs(fftshift(fil_fft))))
subplot(1,2,2)
imagesc(log(abs(fftshift(im_fft)))), axis image, colormap jet
0 0
- 图像处理-FFT
- FPGA图像处理项目(三)--二维FFT
- FFT在图像处理中的简单应用
- 图像FFT
- FPGA图像处理项目(一)--FIFO与FFT
- FPGA图像处理项目(二)--FIFO FFT RAM
- FPGA图像处理项目(四)--二维FFT RapidIO
- 关于DCT与FFT区别(为什么图像处理和音频处理都使用DCT而不用FFT)
- 对图像进行FFT
- matlab 图像fft
- 图像处理中的数学原理详解22——快速傅立叶变换算法FFT
- Python图像处理库PIL中快速傅里叶变换FFT的实现(一)
- Python图像处理库PIL中快速傅里叶变换FFT的实现(一)
- 图像处理与模式识别作业二:快速傅立叶变换FFT与离散余弦变换DCT
- ITK学习笔记:图像FFT
- 离散FFT和图像二维FFT变换的java实现
- 数字信号处理--7.3--FFT算法
- 处理FFT横坐标问题MATLAB
- 蓝桥杯第五届决赛 神奇6位数
- ModBus Slave和ModBus Poll工具软件的使用
- retrofit 使用介绍(快速了解和集成retrofit)
- RxSwift
- VMWare 12 pro CentOS6.5
- 图像处理-FFT
- 应用程序和驱动中使用I2C的流程
- 面试题总结5
- java 上传图片 并压缩图片大小
- Aujaker
- 【直播技术探讨第二章】视频的采集(音频穿插,待续)
- 反射模块理解
- 线程安全及Python中的GIL
- 设计模式