diff src/audio/mint/SDL_mintaudio_xbios.c @ 3851:405a192b68e7 SDL-1.2

Backport from 1.3: most of the audio drivers can now handle data conversion at a higher level when they can't open the hardware in the exact format requested.
author Ryan C. Gordon <icculus@icculus.org>
date Fri, 01 Sep 2006 22:50:24 +0000
parents a8181c4040b8
children 492ff98822fd
line wrap: on
line diff
--- a/src/audio/mint/SDL_mintaudio_xbios.c	Wed Aug 02 21:26:31 2006 +0000
+++ b/src/audio/mint/SDL_mintaudio_xbios.c	Fri Sep 01 22:50:24 2006 +0000
@@ -341,6 +341,10 @@
 	DEBUG_PRINT(("channels=%d, ", spec->channels));
 	DEBUG_PRINT(("freq=%d\n", spec->freq));
 
+    if (spec->channels > 2) {
+        spec->channels = 2;  /* no more than stereo! */
+    }
+
 	spec->format |= 0x8000;	/* Audio is always signed */
 	if ((spec->format & 0x00ff)==16) {
 		spec->format |= 0x1000;	/* Audio is always big endian */