This shifts cyclically shifts an image or other 2D matrix by an arbitrary number of pixels (which can be fractional). I haven't tested it much but the code is very short so it should be easy enough to adapt.
Usage:
y = FourierShift(x, [delta_x delta_y])
x is the input matrix. y is the output. delta_x and _y are the shift amounts in each dimension.
It takes about 1s to run for a 1024x1024 image on my PC. There are faster ways to shift images, but probably not any simpler sub-pixel methods.
引用格式
Tim (2024). 2D Fourier shift (https://www.mathworks.com/matlabcentral/fileexchange/23440-2d-fourier-shift), MATLAB Central File Exchange. 检索来源 .
MATLAB 版本兼容性
创建方式
R2008a
兼容任何版本
平台兼容性
Windows macOS Linux类别
- Image Processing and Computer Vision > Image Processing Toolbox > Image Filtering and Enhancement > Image Filtering >
在 Help Center 和 MATLAB Answers 中查找有关 Image Filtering 的更多信息
标签
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!