--- a/include/SDL_audio.h Sat Dec 13 06:27:58 2008 +0000
+++ b/include/SDL_audio.h Sat Dec 13 06:36:47 2008 +0000
@@ -129,6 +129,11 @@
#define AUDIO_F32SYS AUDIO_F32MSB
#endif
+/* Which audio format changes are allowed when opening a device */
+#define SDL_AUDIO_ALLOW_FREQUENCY_CHANGE 0x00000001
+#define SDL_AUDIO_ALLOW_FORMAT_CHANGE 0x00000002
+#define SDL_AUDIO_ALLOW_CHANNELS_CHANGE 0x00000004
+#define SDL_AUDIO_ALLOW_ANY_CHANGE (SDL_AUDIO_ALLOW_FREQUENCY_CHANGE|SDL_AUDIO_ALLOW_FORMAT_CHANGE|SDL_AUDIO_ALLOW_CHANNELS_CHANGE)
/* A structure to hold a set of audio conversion filters and buffers */
struct SDL_AudioCVT;
@@ -217,7 +222,7 @@
* may modify the requested size of the audio buffer, you should allocate
* any local mixing buffers after you open the audio device.
*/
-extern DECLSPEC int SDLCALL SDL_OpenAudio(const SDL_AudioSpec * desired,
+extern DECLSPEC int SDLCALL SDL_OpenAudio(SDL_AudioSpec * desired,
SDL_AudioSpec * obtained);
/*
@@ -277,7 +282,9 @@
SDL_AudioSpec *
desired,
SDL_AudioSpec *
- obtained);
+ obtained,
+ int
+ allowed_changes);