function setup() end function update() end function draw() gaBackground(0.0,0.03) ofSetColor(255) for i=0,FFT_BANDS-1 do ofRect(i*(OUTPUT_W/FFT_BANDS),OUTPUT_H,OUTPUT_W/FFT_BANDS,-OUTPUT_H*gaGetBin(0,i)) end end
Returns the N bin from FFT analysis in specified audio input channel. Bins came from the Bark Scale, a psychoacoustical scale proposed by Eberhard Zwicker in 1961, which subdivision corresponds to the first 24 critical bands of hearing. If you are working with a sound card with two input channel, then you can use this function with 0 or 1 as specified channel.
«Float, The value of the specified BIN from FFT analysis over the specified channel. Normalized in 0.0 - 1.0 range