didgmo 0.3.2
Functions
peak
didgmo

Routines for interaction with peak objects. More...

Collaboration diagram for peak:

Functions

peak * peak_new (int i_min_size, int i_max_size)
 creates new peak object.
void peak_free (peak *i_peak)
 frees peak object.
void peak_save (peak *i_peak, char *i_path)
 saves peak object to file
peak * peak_load (char *i_path)
 load peak object from file
char * peak_tone (double i_freq, int *o_cents, int *o_octave)
 gives name of tone corresponding to frequency
double peak_freq (const char *i_tone, int i_cents, int i_octave)
 gives freqency of given tone and cents

Detailed Description

Routines for interaction with peak objects.


Function Documentation

peak* peak_new ( int  i_min_size,
int  i_max_size 
)

creates new peak object.

Parameters:
i_min_sizenumber of 'valleys'
i_max_sizenumber of 'peaks'
Returns:
peak object (free with peak_free)
void peak_free ( peak *  i_peak)

frees peak object.

Parameters:
i_peakpeak object
void peak_save ( peak *  i_peak,
char *  i_path 
)

saves peak object to file

Parameters:
i_peakpeak object
i_pathfile path
peak* peak_load ( char *  i_path)

load peak object from file

Parameters:
i_pathfile path
Returns:
peak object (free with peak_free)
char* peak_tone ( double  i_freq,
int *  o_cents,
int *  o_octave 
)

gives name of tone corresponding to frequency

Parameters:
i_freqfrequency
o_centscents
o_octaveoctave
Returns:
name of tone
double peak_freq ( const char *  i_tone,
int  i_cents,
int  i_octave 
)

gives freqency of given tone and cents

@ param i_tone character string of tone @ param i_cents number of cents

@ return frequency of tone