hedgewars/uSound.pas
changeset 3825 fd6c20cd90e3
parent 3697 d5b30d6373fc
child 4357 a1fcfc341a52
--- a/hedgewars/uSound.pas	Fri Sep 03 02:03:44 2010 +0200
+++ b/hedgewars/uSound.pas	Sat Sep 04 02:09:24 2010 +0200
@@ -77,13 +77,20 @@
 
 procedure InitSound;
 var i: TSound;
+    channels: LongInt;
 begin
     if not isSoundEnabled then exit;
     WriteToConsole('Init sound...');
     isSoundEnabled:= SDL_InitSubSystem(SDL_INIT_AUDIO) >= 0;
 
+{$IFDEF IPHONEOS}
+    channels:= 1;
+{$ELSE}
+    channels:= 2;
+{$ENDIF}
+
     if isSoundEnabled then
-        isSoundEnabled:= Mix_OpenAudio(44100, $8010, 2, 1024) = 0;
+        isSoundEnabled:= Mix_OpenAudio(44100, $8010, channels, 1024) = 0;
 
 {$IFDEF SDL_MIXER_NEWER}
     WriteToConsole('Init SDL_mixer... ');