I\'m experimenting with KISSFFT in C++ after being discouraged to use FFTPACK to process 2D arrays.
I wrote an element-wise multiplication
The problem was the order in which width and height were used in shape. This variable is later passed to kiss_fftnd_alloc() as an argument and height must be defined first:
const int numDim = 2;
int shape[numDim] = { height, width };
After making this change inside fft2d() and ifft2d() the application displayed the correct results.