Data Structures | |
struct | pgeWav |
Functions | |
int | pgeWavInit (void) |
void | pgeWavShutdown (void) |
pgeWav * | pgeWavLoad (const char *filename) |
pgeWav * | pgeWavLoadMemory (unsigned char *buffer, int size) |
void | pgeWavDestroy (pgeWav *wav) |
int | pgeWavPlay (pgeWav *wav) |
void | pgeWavStop (pgeWav *wav) |
void | pgeWavStopAll (void) |
int | pgeWavIsPlaying (pgeWav *wav) |
void | pgeWavLoop (pgeWav *wav, unsigned int loop) |
void | pgeWavVolume (pgeWav *wav, unsigned char leftvolume, unsigned char rightvolume) |
void | pgeWavPitch (pgeWav *wav, float pitch) |
void pgeWavDestroy | ( | pgeWav * | wav | ) |
int pgeWavInit | ( | void | ) |
Initialise the WAV playback
int pgeWavIsPlaying | ( | pgeWav * | wav | ) |
Check if a WAV is playing
wav | A pointer to a valid pgeWav struct. |
pgeWav* pgeWavLoad | ( | const char * | filename | ) |
Load a WAV file
filename | - Path of the file to load. |
pgeWav* pgeWavLoadMemory | ( | unsigned char * | buffer, | |
int | size | |||
) |
Load a WAV file from memory
buffer | - Buffer that contains the WAV data. | |
size | - Size of the buffer. |
void pgeWavLoop | ( | pgeWav * | wav, | |
unsigned int | loop | |||
) |
Set the loop of the WAV
wav | - A pointer to a valid pgeWav struct. | |
loop | - Set to 1 to loop, 0 to playback once. |
void pgeWavPitch | ( | pgeWav * | wav, | |
float | pitch | |||
) |
Set the pitch of the WAV
wav | - A pointer to a valid pgeWav struct. | |
pitch | - The new pitch. |
int pgeWavPlay | ( | pgeWav * | wav | ) |
Start playing a loaded WAV file
wav | A pointer to a valid pgeWav struct. |
void pgeWavShutdown | ( | void | ) |
Shutdown WAV playback
void pgeWavStop | ( | pgeWav * | wav | ) |
void pgeWavStopAll | ( | void | ) |
Stop playing all WAVs
void pgeWavVolume | ( | pgeWav * | wav, | |
unsigned char | leftvolume, | |||
unsigned char | rightvolume | |||
) |
Set the volume of the WAV
wav | - A pointer to a valid pgeWav struct. | |
leftvolume | - Set to 0 for no volume, 100 for full volume. | |
rightvolume | - Set to 0 for no volume, 100 for full volume. |