Added function: UpdateSound()

This commit is contained in:
raysan5
2016-08-29 11:17:58 +02:00
parent 7dbb17792a
commit be97583f00
3 changed files with 31 additions and 0 deletions

View File

@@ -486,6 +486,7 @@ typedef struct Ray {
typedef struct Sound {
unsigned int source; // OpenAL audio source id
unsigned int buffer; // OpenAL audio buffer id
int format; // OpenAL audio format specifier
} Sound;
// Wave type, defines audio wave data
@@ -908,6 +909,7 @@ RLAPI bool IsAudioDeviceReady(void); // Check i
RLAPI Sound LoadSound(char *fileName); // Load sound to memory
RLAPI Sound LoadSoundFromWave(Wave wave); // Load sound to memory from wave data
RLAPI Sound LoadSoundFromRES(const char *rresName, int resId); // Load sound to memory from rRES file (raylib Resource)
RLAPI void UpdateSound(Sound sound, void *data, int numSamples); // Update sound buffer with new data
RLAPI void UnloadSound(Sound sound); // Unload sound
RLAPI void PlaySound(Sound sound); // Play a sound
RLAPI void PauseSound(Sound sound); // Pause a sound