I’ve been working with images in the frequency domain (by taking the DFT or FFT of an image) and I know that convolution in the space domain is multiplication in the frequency.
So my question is, if I wanted to apply a specific kernel (lets say a 9×9 smoothing kernel) in the space domain, I would just convolve the whole image by the 9×9 filter. Now, if I wanted to do the same thing in the frequency domain, do I take the FFT of both the image and the kernel? Then how/what do I multiply? After I have that new set of data (image multiplied by kernel), I just reverse the direction of the FFT and that should give me the same result as the kernel convolved with the image in the space domain, right?
Thanks for any help!
IIRC, manage to have your FFT’d image and kernel (both FFT’d) of the same dimensions, then multiply pixel-by-pixel both FFT’d images, then inverse FFT the result.
Take care of what happens to the borders of your image (see FFT theory).