JS-Fourier-Image-Analysis icon indicating copy to clipboard operation
JS-Fourier-Image-Analysis copied to clipboard

This is a 1D transform, not 2D

Open photopea opened this issue 5 years ago • 0 comments

I have a strong suspicion, that this is an implementation of a 1D fourier transform, not 2D. Meaning, instead of computing a 2D transform of NxN values, it computes a 1D transform of a "linear array" of NxN values.

The 1D transform of an image (as "row-by-row") looks very similar to a 2D transform. Of course, it is invertable, meaning, that the inverse will give you back the original array, even if it was an image.

This library gives exactly the same results, as this code of 1D transform: https://code.soundsoftware.ac.uk/projects/js-dsp-test/repository/entry/fft/nayuki-obj/fft.js

photopea avatar Aug 22 '19 13:08 photopea