audio: Rename SDL_GetAudioStreamBinding to SDL_GetAudioStreamDevice.
This commit is contained in:
@@ -72,7 +72,7 @@ open_audio(void)
|
||||
SDL_free(wave.sound);
|
||||
quit(2);
|
||||
}
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamBinding(stream));
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamDevice(stream));
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -28,8 +28,8 @@ static int done = 0;
|
||||
|
||||
static void loop(void)
|
||||
{
|
||||
const SDL_AudioDeviceID devid_in = SDL_GetAudioStreamBinding(stream_in);
|
||||
const SDL_AudioDeviceID devid_out = SDL_GetAudioStreamBinding(stream_out);
|
||||
const SDL_AudioDeviceID devid_in = SDL_GetAudioStreamDevice(stream_in);
|
||||
const SDL_AudioDeviceID devid_out = SDL_GetAudioStreamDevice(stream_out);
|
||||
SDL_bool please_quit = SDL_FALSE;
|
||||
SDL_Event e;
|
||||
|
||||
|
||||
@@ -88,7 +88,7 @@ static void iteration(void)
|
||||
/* !!! FIXME: laziness, this used to loop the audio, but we'll just play it once for now on each connect. */
|
||||
SDL_PutAudioStreamData(stream, sound, soundlen);
|
||||
SDL_FlushAudioStream(stream);
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamBinding(stream));
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamDevice(stream));
|
||||
/* !!! FIXME: this is leaking the stream for now. We'll wire it up to a dictionary or whatever later. */
|
||||
}
|
||||
}
|
||||
|
||||
@@ -66,7 +66,7 @@ test_multi_audio(SDL_AudioDeviceID *devices, int devcount)
|
||||
if ((stream = SDL_OpenAudioDeviceStream(devices[i], &spec, NULL, NULL)) == NULL) {
|
||||
SDL_LogError(SDL_LOG_CATEGORY_APPLICATION, "Audio stream creation failed: %s", SDL_GetError());
|
||||
} else {
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamBinding(stream));
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamDevice(stream));
|
||||
SDL_PutAudioStreamData(stream, sound, soundlen);
|
||||
SDL_FlushAudioStream(stream);
|
||||
#ifdef __EMSCRIPTEN__
|
||||
@@ -107,7 +107,7 @@ test_multi_audio(SDL_AudioDeviceID *devices, int devcount)
|
||||
/* try to start all the devices about the same time. SDL does not guarantee sync across physical devices. */
|
||||
for (i = 0; i < devcount; i++) {
|
||||
if (streams[i]) {
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamBinding(streams[i]));
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamDevice(streams[i]));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -216,7 +216,7 @@ int main(int argc, char *argv[])
|
||||
SDL_LogError(SDL_LOG_CATEGORY_APPLICATION, "SDL_OpenAudioDeviceStream() failed: %s\n", SDL_GetError());
|
||||
continue;
|
||||
}
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamBinding(stream));
|
||||
SDL_ResumeAudioDevice(SDL_GetAudioStreamDevice(stream));
|
||||
|
||||
for (j = 0; j < total_channels; j++) {
|
||||
const int sine_freq = is_lfe_channel(j, total_channels) ? LFE_SINE_FREQ_HZ : SINE_FREQ_HZ;
|
||||
|
||||
Reference in New Issue
Block a user