view arrows/dsp/spec_bench2.m @ 61:eff6bddf82e3 tip

Finally implemented perceptual brightness thing.
author samer
date Sun, 11 Oct 2015 10:20:42 +0100
parents 672052bd81f8
children
line wrap: on
line source
% spec_bench2 - Arrow for doing spectral-based processing (no phase)
%
% spec_bench ::
%    N:natural ~'frame size',
%    M:natural ~'hop size'
%    arrow( {[dftbins(N),W]}, {[dftbins(N),W]}, S1), ~'arrow to process power spectra',
% -> arrow( {[N,W]}, {[N,W]}, pair(pair(empty,S1),empty)) ~'total arrow'.
%
% This splits a signal into magnitude and phase spectra (using Hanning analysis window),
% applies supplied arrows to the two branches, and then recombines them using an inverse
% DFT and overlap-and-add to compose the output signal.
function o=spec_bench(N,M,a)
	o=apowspec(hanning(N))*a*aspecsyn(N,M,@hanning);
end