fix sound in SDL port/ConfigManager
Since we are using sound frequency to control game speed, not quality, change ConfigManager to default to a frequency of 44100 instead of 22050. This also fixes trace.log files showing up with "unknown sound quality" warnings.
This commit is contained in:
parent
f2bfc549ea
commit
d1b4abc85a
|
@ -537,15 +537,15 @@ void LoadConfig()
|
|||
winGbBorderOn = ReadPref("borderOn", 0);
|
||||
winGbPrinterEnabled = ReadPref("gbPrinter", 0);
|
||||
|
||||
int soundQuality = (ReadPrefHex("soundQuality"));
|
||||
int soundQuality = (ReadPrefHex("soundQuality", 1));
|
||||
switch (soundQuality) {
|
||||
case 1:
|
||||
case 2:
|
||||
case 4:
|
||||
break;
|
||||
default:
|
||||
log("Unknown sound quality %d. Defaulting to 22Khz\n", soundQuality);
|
||||
soundQuality = 2;
|
||||
log("Unknown sound quality %d. Defaulting to 44Khz\n", soundQuality);
|
||||
soundQuality = 1;
|
||||
break;
|
||||
}
|
||||
soundSetSampleRate(44100 / soundQuality);
|
||||
|
|
Loading…
Reference in New Issue