back to the text
/*--------------------------------------------------
*
* adio.h - Thanks to Marcus Thiebaux
*
*--------------------------------------------------*/
#ifndef AUDIO_SAMPLE_CLASS
#define AUDIO_SAMPLE_CLASS
///////////////////////////////////////////////////////////////////////////
#define SET_PLAY_CUT 1
#define SET_PLAY_AMP 2
#define SET_PLAY_VEL 3
#define SET_LOOP_ON 1
#define SET_LOOP_AMP 2
#define SET_LOOP_VEL 3
#define SET_LOOP_OFF 4
///////////////////////////////////////////////////////////////////////////
class AUDIOserver {
public:
AUDIOserver(void);
~AUDIOserver(void);
void enable(int E = 1, int F = 0); /* Enable, Forced (o.w. if cavemaster) */
};
class AUDIOsample {
public:
AUDIOsample(void);
~AUDIOsample(void);
void create(char *dir, char *file);
void play(float freq = 1.0, float ampl = 0.5, int ctl = 0);
void loop(float freq = 1.0, float ampl = 0.5, int ctl = 1);
void destroy(void);
private:
float actor, note;
char sample[128];
};
///////////////////////////////////////////////////////////////////////////
#endif
/*--------------------------------------------------*/