extra/genspecsines.m File Reference

Go to the source code of this file.

Functions

location of peak (zero-based indexing)
 
loc<=1||loc >=hN-1 continue ()
 
main lobe (real value) bins to read lmag
 
spectrum bins to fill (1-based indexing) for m
 
 elseif (b(m)>hN)%peak lobe croses Nyquist bin Y(2 *hN-b(m))
 
else peak lobe in positive freq range Y (b(m))
 
end end Y (hN+1:end)
 

Variables

function Y
 
function ipmag = val-.25*(lval-rval).*(iploc-ploc)
 
function ipphase = interp1(1:length(pX),pX,iploc,'linear')
 
function magnitudes and phases
 
function magnitudes and N
 
Y __pad2__
 
Y initialize output spectrum hN = N/2+1
 
size of positive freq spectrum for i =1:length(ploc)
 
generate all sine spectral lobes loc = ploc(i)-1
 
location of range
 
 end
 
avoid frequencies out of range binremainder = round(loc)-loc
 
 lb = [binremainder-4:binremainder+4]'
 
lobe magnitudes of the complex exponential b = 1+[round(loc)-4:round(loc)+4]'
 

Function Documentation

loc<=1||loc>=hN-1 continue ( )
virtual
elseif ( b(m ,
hN   
)
spectrum bins to fill ( 1-based  indexing)
main lobe ( real  value)
location of peak ( zero-based  indexing)
else peak lobe in positive freq range Y ( b(m )
end end Y ( hN+1:end  )

Variable Documentation

Y __pad2__

Definition at line 5 of file extra/genspecsines.m.

lobe magnitudes of the complex exponential b = 1+[round(loc)-4:round(loc)+4]'

Definition at line 13 of file extra/genspecsines.m.

avoid frequencies out of range binremainder = round(loc)-loc

Definition at line 10 of file extra/genspecsines.m.

end

Definition at line 9 of file extra/genspecsines.m.

Y initialize output spectrum hN = N/2+1

Definition at line 6 of file extra/genspecsines.m.

size of positive freq spectrum for i =1:length(ploc)

Definition at line 7 of file extra/genspecsines.m.

center of parabola ipmag = val-.25*(lval-rval).*(iploc-ploc)

Definition at line 1 of file extra/genspecsines.m.

magnitude of peaks ipphase = interp1(1:length(pX),pX,iploc,'linear')

Definition at line 1 of file extra/genspecsines.m.

generate all sine spectral lobes loc = ploc(i)-1

Definition at line 8 of file extra/genspecsines.m.

Referenced by decode_gain_control().

function magnitudes and N

Definition at line 1 of file extra/genspecsines.m.

function magnitudes and phases

Definition at line 1 of file extra/genspecsines.m.

Initial value:
= genspecsines (ploc, pmag, pphase, N)
% Compute a spectrum from a series of sine values
function magnitudes and N
function ploc
pphase
Definition: stft_peak.m:27
const char * from
phase spectrum(unwrapped) ploc
function pmag
magnitude of bin at right iploc
these buffered frames must be flushed immediately if a new input produces new the filter must not call request_frame to get more It must just process the frame or queue it The task of requesting more frames is left to the filter s request_frame method or the application If a filter has several the filter must be ready for frames arriving randomly on any input any filter with several inputs will most likely require some kind of queuing mechanism It is perfectly acceptable to have a limited queue and to drop frames when the inputs are too unbalanced request_frame This method is called when a frame is wanted on an output For an it should directly call filter_frame on the corresponding output For a if there are queued frames already one of these frames should be pushed If the filter should request a frame on one of its repeatedly until at least one frame has been pushed Return values

Definition at line 1 of file extra/genspecsines.m.