Skip to content

Commit c804490

Browse files
committed
2 parents 6564a25 + 4310182 commit c804490

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

src/pt2_audio.c

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,7 @@ bool setupAudio(void)
430430
want.callback = audioCallback;
431431
want.userdata = NULL;
432432

433-
dev = SDL_OpenAudioDevice(NULL, 0, &want, &have, SDL_AUDIO_ALLOW_ANY_CHANGE);
433+
dev = SDL_OpenAudioDevice(NULL, 0, &want, &have, SDL_AUDIO_ALLOW_FREQUENCY_CHANGE);
434434
if (dev == 0)
435435
{
436436
showErrorMsgBox("Couldn't open audio device:\n\"%s\"\n\nDo you have an audio device enabled and plugged in?", SDL_GetError());
@@ -445,12 +445,6 @@ bool setupAudio(void)
445445
return false;
446446
}
447447

448-
if (have.format != AUDIO_S16)
449-
{
450-
showErrorMsgBox("Couldn't open audio device:\nThis program only supports 16-bit audio streams. Sorry!");
451-
return false;
452-
}
453-
454448
audio.outputRate = have.freq;
455449
audio.audioBufferSize = have.samples;
456450
audio.oversamplingFlag = (audio.outputRate < 96000); // we do 2x oversampling if the audio output rate is below 96kHz

0 commit comments

Comments
 (0)