/****************************************************************************************/
/*                                                                                      */
/*              load_sound.h                                                            */
/*                                                                                      */
/****************************************************************************************/

#ifndef _LOAD_SOUND_H_
#define _LOAD_SOUND_H_

#include "sound/sound.h"
#include "sound/wave.h"
#include "sound/audiocmp.h"


#define NSOUNDPKG 16

char* soundname[NSOUNDPKG]=
{"_sndPlayStart",
 "_sndPlayStop",
 "_sndRecStart",
 "_sndRecStop",
 "_sndSetPending",
 "_sndUnsetPending",
 "_sndSetPlayBuffersN",
 "_sndSetRecBuffersN",
 "_sndSetRflxRecOpen",
 "_sndSetRflxRecClose",
 "_sndSetRflxRecBuf",
 "_sndSetRflxPlayOpen",
 "_sndSetRflxPlayClose",
 "_sndSetRflxPlayBuf",
 "SoundRec",
 "SoundPlay"};
int (*soundfun[NSOUNDPKG])(mmachine m)=
{sndPlayStart,
 sndPlayStop,
 sndRecStart,
 sndRecStop,
 sndSetPending,
 sndUnsetPending,
 sndSetPlayBuffersN,
 sndSetRecBuffersN,
 sndrflRecOpen,
 sndrflRecClose,
 sndrflRecBuf,
 sndrflPlayOpen,
 sndrflPlayClose,
 sndrflPlayBuf};
int soundnarg[NSOUNDPKG]=
{5, // Srv,Rate,buffersize,resolution,nchannels
 0, 
 5,
 0,
 0,
 0,
 1,
 1,
 3,
 3,
 3,
 3,
 3,
 3,
 TYPTYPE,
 TYPTYPE};
char* soundtype[NSOUNDPKG]=
{"fun [Chn I I I I] SoundPlay",
 "fun [] I",
 "fun [Chn I I I I] SoundRec",
 "fun [] I",
 "fun [] I",
 "fun [] I",
 "fun [I] I",
 "fun [I] I",
 "fun [SoundRec fun [SoundRec u0] u1 u0] SoundRec",
 "fun [SoundRec fun [SoundRec u0] u1 u0] SoundRec",
 "fun [SoundRec fun [SoundRec u0 S I] u1 u0] SoundRec",
 "fun [SoundPlay fun [SoundPlay u0] u1 u0] SoundPlay",
 "fun [SoundPlay fun [SoundPlay u0] u1 u0] SoundPlay",
 "fun [SoundPlay fun [SoundPlay u0 I] S u0] SoundPlay",
 NULL,
 NULL};


#define NAUDIOCMPPKG 20

char* audiocmpname[NAUDIOCMPPKG]=
{"_AudioCrunch4bit",
 "_AudioDecrunch4bit",
 "_AudioCrunch2bit",
 "_AudioDecrunch2bit",
 "_AudioUninterpol2",
 "_AudioInterpol2",
 "_AudioGsmInit",
 "_AudioGsmDestroy",
 "_AudioGsmEncode",
 "_AudioGsmDecode",
 "_AudioGsmEncode16",
 "_AudioGsmDecode16",
 "_AudioNoiseGate8",
 "_AudioNoiseGate16",
 "_AudioNormalyse8",
 "_AudioNormalyse16",
 "_AudioGsmSetNoiseLevel",
 "_AudioGetLevel8",
 "_AudioGetLevel16",
 "GsmCodec"};
int (*audiocmpfun[NAUDIOCMPPKG])(mmachine m)=
{AudioCrunch4bit,
 AudioDecrunch4bit,
 AudioCrunch2bit,
 AudioDecrunch2bit,
 AudioUnInterpol2,
 AudioInterpol2,
 AudioGsmInit,
 AudioGsmDestroy,
 AudioGsmCrunch,
 AudioGsmDecrunch,
 AudioGsmCrunch16,
 AudioGsmDecrunch16,
 AudioNoiseGate8,
 AudioNoiseGate16,
 AudioNormalyse8,
 AudioNormalyse16,
 AudioGsmSetNoiseLevel,
 AudioGetLevel8,
 AudioGetLevel16,
 NULL};
int audiocmpnarg[NAUDIOCMPPKG]=
{1,
 1,
 1,
 1,
 1,
 1,
 0,
 1,
 2,
 2,
 2,
 2,
 3,
 3,
 1,
 1,
 1,
 1,
 1,
 TYPTYPE};
char* audiocmptype[NAUDIOCMPPKG]=
{"fun [S] S",
 "fun [S] S",
 "fun [S] S",
 "fun [S] S",
 "fun [S] S",
 "fun [S] S",
 "fun [] GsmCodec",
 "fun [GsmCodec] I",
 "fun [S GsmCodec] S",
 "fun [S GsmCodec] S",
 "fun [S GsmCodec] S",
 "fun [S GsmCodec] S",
 "fun [S I I] S",
 "fun [S I I] S",
 "fun [S] S",
 "fun [S] S",
 "fun [I] I",
 "fun [S] I",
 "fun [S] I",
 NULL};

#endif
