triVoid triWavFree(triWav *theWav)
Unload a previously loaded WAV file.
triWav * triWavLoad(const triChar *filename)
Load a WAV file.
triVoid triWavSetLoop(triWav *theWav, triUInt loop)
Set the loop of the WAV playback.
triBool triWavPlay(triWav *theWav)
Start playing a loaded WAV file.
triVoid triWavStop(triWav *theWav)
Stop playing a loaded WAV.
triVoid triWavStopAll()
Stop playing all WAVs.
triBool triWavInit()
Initialise the WAV playback.
A WAV file struct.
Definition: triWav.h:38
triU32 bitPerSample
The bit rate of the WAV.
Definition: triWav.h:49
triU32 sampleCount
Sample count.
Definition: triWav.h:41
triU32 channels
Number of channels.
Definition: triWav.h:39
triUInt loop
Loop flag.
Definition: triWav.h:46
triU32 playPtr_frac
Internal.
Definition: triWav.h:45
triU32 rateRatio
Rate ratio (sampleRate / 44100 * 0x10000)
Definition: triWav.h:43
triU32 sampleRate
Sample rate.
Definition: triWav.h:40
triUInt id
The ID of the WAV.
Definition: triWav.h:48
triU32 dataLength
Data length.
Definition: triWav.h:42
triU32 playPtr
Internal.
Definition: triWav.h:44
void * data
A pointer to the actual WAV data.
Definition: triWav.h:47