- Foward and inverse fast fourier transform
- Can do FFT on an image of any resolution (depends on the configuration, restrictions listed below)
- Can load/save images of .jpg and .png format
- Will work with R, RG, RGB and RGBA images
- Power spectrum generation
- CLI interface
- Runs on optimized GPU Compute shaders
OpenGLFFT -input "path_to_image" [-real "path_to_image"] [-imaginary "path_to_image"] [-spectrum "path_to_image"] [-inverse "path_to_image"]
-inputpath to the image you want to do FFT on-realpath where the real component will be saved (optional)-imaginarypath where the imaginary component will be saved (optional)-spectrumpath where the power spectrum will be saved (optional)-inversepath where IFFT will be saved (optional)
All input and output images must have either .jpg or .png extension
All of the restrictions are tied to following configurations:
WORKGROUP_SIZE_Xthis must be power of two and not bigger thanN / 2(where in this caseNwould bemax(roundUpToPoT(width), roundUpToPoT(height)))SHARED_BUFFER_SIZEsize of the shared buffer's. This affects the maximum resoultion of an image you can do FFT onPIXEL_BUFFER_SIZElocal array that stores pixel data. This cannot be smaller thanN / 2 / WORKGROUP_SIZE_X
All of these defines are in FFT2D.comp (in this configuration the shader code is located here)
- GLFW
- GLAD (included)
- stbi_image (included)
- stbi_image_write (included)
