head 1.1; branch 1.1.1; access ; symbols start:1.1.1.1 PAlibDoc:1.1.1; locks ; strict; comment @# @; 1.1 date 2005.11.02.08.30.26; author jandujar; state Exp; branches 1.1.1.1; next ; 1.1.1.1 date 2005.11.02.08.30.26; author jandujar; state Exp; branches ; next ; desc @@ 1.1 log @Initial revision @ text @ PA_lib: Sound ARM9 functions

Sound ARM9 functions


Defines

#define PA_PlayMod(mod_snd)   SndPlayMOD((u8*)mod_snd)
 Play a mod ! Thanks to Deku for that :p
#define PA_StopMod()   SndStopMOD()
 Stop playing the mod ! Thanks to Deku for that :p
#define PA_PauseMod(bool)   SndPauseMOD(bool)
 Pause the mod ! Thanks to Deku for that :p

Functions

void PA_SetDefaultSound (u8 volume, s16 freq, s16 format)
 Set the default sound options (for the PlaySimpleSound function)
void PA_InitSound (void)
 Initialise the Sound system, for mods and sound effects
void PA_PlaySoundEx (u8 PA_Channel, const void *data, u32 length, u8 volume, s16 freq, s16 format)
 Play a given sound effect, but chose your format
void PA_PlayGBFSSoundEx (u8 PA_Channel, u16 GBFS_wav_number, u8 volume, s16 freq, s16 format)
 Play a given sound effect, but chose your format, from GBFS
void PA_PlaySound (u8 PA_Channel, const void *data, u32 length, u8 volume, s16 freq)
 Play a given sound effect, with default format (raw)
void PA_PlayGBFSSound (u8 PA_Channel, u16 GBFS_wav_number, u8 volume, s16 freq)
 Play a given sound effect, with default format (raw), from GBFS
void PA_PlaySimpleSound (u8 PA_Channel, const void *data, u32 length)
 Simplest sound playing function... Takes the default options for volume, format, and rate (11025). You can change these options by using PA_SetDefaultSound
void PA_PlayGBFSSimpleSound (u8 PA_Channel, u16 GBFS_wav_number)
 Simplest sound playing function... From GBFS... Takes the default options for volume, format, and rate (11025). You can change these options by using PA_SetDefaultSound
void PA_PlayGBFSMod (u16 GBFS_mod_number)
 Play a mod from GBFS... Warning, it copies to RAM, so big mods will make the DS crash...

Detailed Description

Play sounds, etc...

Define Documentation

#define PA_PauseMod bool   )     SndPauseMOD(bool)
 

Pause the mod ! Thanks to Deku for that :p

Parameters:
bool 0 or 1...

#define PA_PlayMod mod_snd   )     SndPlayMOD((u8*)mod_snd)
 

Play a mod ! Thanks to Deku for that :p

Parameters:
mod_snd Mod name


Function Documentation

inline void PA_PlayGBFSMod u16  GBFS_mod_number  )  [inline]
 

Play a mod from GBFS... Warning, it copies to RAM, so big mods will make the DS crash...

Parameters:
GBFS_mod_number Mod's PA GBFS file number

inline void PA_PlayGBFSSimpleSound u8  PA_Channel,
u16  GBFS_wav_number
[inline]
 

Simplest sound playing function... From GBFS... Takes the default options for volume, format, and rate (11025). You can change these options by using PA_SetDefaultSound

Parameters:
PA_Channel Audio channel, from 0 to 7
GBFS_wav_number Number of your sound RAW file in the PA GBFS system

inline void PA_PlayGBFSSound u8  PA_Channel,
u16  GBFS_wav_number,
u8  volume,
s16  freq
[inline]
 

Play a given sound effect, with default format (raw), from GBFS

Parameters:
PA_Channel Audio channel, from 0 to 7
GBFS_wav_number Number of your sound RAW file in the PA GBFS system
volume Volume, from 0 to 127. 64 if not used
freq Sound frequence, depends on the sound... 11025 by default

inline void PA_PlayGBFSSoundEx u8  PA_Channel,
u16  GBFS_wav_number,
u8  volume,
s16  freq,
s16  format
[inline]
 

Play a given sound effect, but chose your format, from GBFS

Parameters:
PA_Channel Audio channel, from 0 to 7
GBFS_wav_number Number of your sound RAW file in the PA GBFS system
volume Volume, from 0 to 127. 64 if not used
freq Sound frequence, depends on the sound... 11025 by default
format Sound format.

inline void PA_PlaySimpleSound u8  PA_Channel,
const void *  data,
u32  length
[inline]
 

Simplest sound playing function... Takes the default options for volume, format, and rate (11025). You can change these options by using PA_SetDefaultSound

Parameters:
PA_Channel Audio channel, from 0 to 7
data Sound data
length Sound length, with (u32)sound_size

inline void PA_PlaySound u8  PA_Channel,
const void *  data,
u32  length,
u8  volume,
s16  freq
[inline]
 

Play a given sound effect, with default format (raw)

Parameters:
PA_Channel Audio channel, from 0 to 7
data Sound data
length Sound length, with (u32)sound_size
volume Volume, from 0 to 127. 64 if not used
freq Sound frequence, depends on the sound... 11025 by default

void PA_PlaySoundEx u8  PA_Channel,
const void *  data,
u32  length,
u8  volume,
s16  freq,
s16  format
 

Play a given sound effect, but chose your format

Parameters:
PA_Channel Audio channel, from 0 to 7
data Sound data
length Sound length, with (u32)sound_size
volume Volume, from 0 to 127. 64 if not used
freq Sound frequence, depends on the sound... 11025 by default
format Sound format.

void PA_SetDefaultSound u8  volume,
s16  freq,
s16  format
 

Set the default sound options (for the PlaySimpleSound function)

Parameters:
volume Volume, from 0 to 127. 64 if not used
freq Sound frequence, depends on the sound... 11025 by default
format Sound format.


Generated on Fri Oct 28 23:16:51 2005 for PA_lib by  doxygen 1.3.9.1
@ 1.1.1.1 log @Initial import of PalibDoc, begin on PAlib0.64b @ text @@