Commit 28602b12357b983802ac0386185b3de4a208826a

Sam Lantinga 2017-09-22T11:15:57

The volume was too high, clamp to SDL_MIX_MAXVOLUME

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/Xcode-iOS/Demos/src/mixer.c b/Xcode-iOS/Demos/src/mixer.c
index 81f0166..14945ad 100644
--- a/Xcode-iOS/Demos/src/mixer.c
+++ b/Xcode-iOS/Demos/src/mixer.c
@@ -250,7 +250,7 @@ audioCallback(void *userdata, Uint8 * stream, int len)
 
         /* mix this sound effect with the output */
         SDL_MixAudioFormat(stream, mixer.channels[i].position,
-                           mixer.outputSpec.format, copy_amt, 150);
+                           mixer.outputSpec.format, copy_amt, SDL_MIX_MAXVOLUME);
 
         /* update buffer position in sound effect and the number of bytes left */
         mixer.channels[i].position += copy_amt;