scale.h File Reference

Vector scaling function. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef _aubio_scale_t aubio_scale_t
 scale object

Functions

aubio_scale_tnew_aubio_scale (smpl_t flow, smpl_t fhig, smpl_t ilow, smpl_t ihig)
 create a scale object
void del_aubio_scale (aubio_scale_t *s)
 delete a scale object
void aubio_scale_do (aubio_scale_t *s, fvec_t *input)
 scale input vector
void aubio_scale_set (aubio_scale_t *s, smpl_t ilow, smpl_t ihig, smpl_t olow, smpl_t ohig)
 modify scale parameters after object creation


Detailed Description

Vector scaling function.

This object, inspired from the scale object in FTS, the jMax engine, scales the values of a vector according to an affine function defined as follow:

$ y = (x - ilow)*(ohig-olow)/(ihig-ilow) + olow $


Function Documentation

void aubio_scale_do ( aubio_scale_t s,
fvec_t input 
)

scale input vector

Parameters:
s scale object as returned by new_aubio_scale
input vector to scale

void aubio_scale_set ( aubio_scale_t s,
smpl_t  ilow,
smpl_t  ihig,
smpl_t  olow,
smpl_t  ohig 
)

modify scale parameters after object creation

Parameters:
s scale object as returned by new_aubio_scale
olow lower value of output function
ohig higher value of output function
ilow lower value of input function
ihig higher value of output function

void del_aubio_scale ( aubio_scale_t s  ) 

delete a scale object

Parameters:
s scale object as returned by new_aubio_scale

aubio_scale_t* new_aubio_scale ( smpl_t  flow,
smpl_t  fhig,
smpl_t  ilow,
smpl_t  ihig 
)

create a scale object

Parameters:
flow lower value of output function
fhig higher value of output function
ilow lower value of input function
ihig higher value of output function


Generated on Wed Oct 11 17:36:54 2006 for aubio by  doxygen 1.4.7