3D visualization of audio files (currently .wav only).
Computes FFT on windows of .wav chunks to define vertex heights on 3D triangle mesh, with customizable color map and other options. X axis is time; y axis is frequency.
Hobby project for:
- familiarization w/ audio formats (buffering, channels, underruns)
- exploration of 3D visualization options
python terrain.py -f data/audio_file.wav
- audio_filename: filepath of .wav file to play (and plot)
- cmap: matplotlib colormap to use for plotting (options)
- cmap_agger: method to use to reduce a set of three vertices (defining a face) into a single value (by default, np.mean)
- refresh_ms: time between each plot refresh, in milliseconds
- ignore_threshold: rounds down to zero for any values below threshold (crude 'denoising')
- other parameters defined in terrain.py
- Baseline 3D mesh code from Audio-Spectrum-Analyzer-in-Python: heavily refactored for efficiency and modified to accept .wav files and allow customization/parameters