Audio Reactivity 🌀 Bulka

Audio Reactivity

Hydra can make visuals that react to sound in real time through FFT analysis.

The a object: audio analysis

Property/MethodDescription
a.fft[n]The value of a frequency band (0-1)
a.show()Show the FFT visualization
a.hide()Hide the visualization
a.setBins(n)Set the number of frequency bands
a.setSmooth(n)Set the smoothing (0-1)
a.setScale(n)Set the sensitivity
a.setCutoff(n)Set the noise threshold

A basic example


Different frequencies, different parameters


Modulating with loudness


A pulsing kaleidoscope


Reactive noise


Feedback with audio


Strudel patterns in Hydra

The H() function lets you use Strudel patterns as Hydra inputs:


feedStrudel: visualizing the pattern


Audio reactivity tips

Good settings

a.setBins(4)       // Enough for bass/mid/high
a.setSmooth(0.8)   // Smooth transitions
a.setScale(8)      // Good sensitivity
a.setCutoff(0.1)   // Cut off the noise

Frequency bands

IndexFrequenciesUse
a.fft[0]Lows (bass)Pulsing, scale
a.fft[1]Low midsRotation
a.fft[2]High midsColor, brightness
a.fft[3]HighsFine details

Avoid chaos

// Bad: too much reactivity
osc(() => a.fft[0] * 100).out()

// Better: moderate values with a base
osc(() => a.fft[0] * 30 + 10).out()