2D FFT/IFFT implementation with FFTW.
Currently I have an image loaded in using SFML and have decomposed it into its magnitude and phase components with fftw_plan_dft_2d
.
This went okay and I've checked my magnitude image against known working software and the results are correct. (Forward FFT)
I've checked that the ifft is working by directly performing an inverse 2D FFT straight out of the forward FFT (Inverse FFT) using the real and imaginary output from the first FFT (there are problems with that as well somewhere, but that's for another day)
I'm more interested in the way I should recombine the magnitude and phase to form the real and complex parts in order to perform the IFFT.
Google returns a lot of MATLAB stuff, which I do not understand at all, thus doesn't really help.
Side note: Math is not my strong suit. Which is why I think I'm struggling a bit. Please explain like I'm a 10 year old if possible!