https://github.com/someoneserge/vizfft
An imgui+webassembly demo visualizing the fft of a plane wave
https://github.com/someoneserge/vizfft
eigen3 emscripten fft2 imgui nix webassembly-demo webgl
Last synced: about 2 months ago
JSON representation
An imgui+webassembly demo visualizing the fft of a plane wave
- Host: GitHub
- URL: https://github.com/someoneserge/vizfft
- Owner: SomeoneSerge
- License: mit
- Created: 2022-09-19T15:49:48.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2023-02-23T19:56:18.000Z (over 3 years ago)
- Last Synced: 2025-03-29T03:14:23.398Z (about 1 year ago)
- Topics: eigen3, emscripten, fft2, imgui, nix, webassembly-demo, webgl
- Language: C++
- Homepage: https://someoneserge.github.io/vizfft/
- Size: 48.8 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# vizfft
An imgui+webGL toy, visualizing FFT of [plane waves](https://en.wikipedia.org/wiki/Plane_wave).
## Dependencies
0. Get https://nixos.org/download.html (`$ sh <(curl -L https://nixos.org/nix/install) --daemon`)
1. 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
```console
cmake -B build -S . -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DBUILD_EMSCRIPTEN=OFF
cmake --build build/
```
## Build WebGL
```console
cmake -B build -S . -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
cmake --build build/
npx http-server build/ -c-1
```
## Roadmap
- [x] [init](https://github.com/SomeoneSerge/vizfft/commit/483365f50b3272b0e3931fbc8886836cdb192c18):
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
- [x] [build](https://github.com/SomeoneSerge/vizfft/commit/58c3c47fda0d9b67f48dde7ff9b0f5fb1973bd9b) github-pages on a push to master
- [x] [patch](https://github.com/SomeoneSerge/vizfft/commit/c382d41238fe010f74c9f0096b4cbf952bd41366) the negative DeltaTime issue in firefox
- [x] [switch](https://github.com/SomeoneSerge/vizfft/commit/cf8b8e41959b455af689b21abc03365c7cccf309) 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