Skip to content

SomeoneSerge/vizfft

Repository files navigation

vizfft

An imgui+webGL toy, visualizing FFT of plane waves.

Dependencies

  1. Get https://nixos.org/download.html ($ sh <(curl -L https://nixos.org/nix/install) --daemon)
  2. Get https://direnv.net/
  3. Get https://github.com/nix-community/home-manager/ with programs.direnv.enable = true and programs.direnv.nix-direnv.enable = true
  4. echo use nix > .envrc
  5. direnv allow

Build native

cmake -B build -S . -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DBUILD_EMSCRIPTEN=OFF
cmake --build build/

Build WebGL

cmake -B build -S . -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
cmake --build build/
npx http-server build/ -c-1

Roadmap

  • init: a bunch of copy-paste to bootstrap the cmake, glfw, imgui, and emscripten trivia; raii headers in their current form can obviously only be included once, or they won't link correctly
  • build github-pages on a push to master
  • patch the negative DeltaTime issue in firefox
  • switch from GLFW to SDL just to feel the difference between the APIs
  • fft in a separate thread, on a frequency lower than the framerate
  • switching between glfw/sdl via policies?
  • a shader to visualize the implicit periodic extensions of the image
  • an option to visualize an implicitly zero-padded signal
  • 1d signal