mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-01 23:07:45 +08:00
audio: Remove const from an SDL_bool parameter in SDL_AddAudioDevice.
This commit is contained in:
@@ -622,7 +622,7 @@ static SDL_AudioDevice *CreateAudioPlaybackDevice(const char *name, const SDL_Au
|
|||||||
}
|
}
|
||||||
|
|
||||||
// The audio backends call this when a new device is plugged in.
|
// The audio backends call this when a new device is plugged in.
|
||||||
SDL_AudioDevice *SDL_AddAudioDevice(const SDL_bool recording, const char *name, const SDL_AudioSpec *inspec, void *handle)
|
SDL_AudioDevice *SDL_AddAudioDevice(SDL_bool recording, const char *name, const SDL_AudioSpec *inspec, void *handle)
|
||||||
{
|
{
|
||||||
// device handles MUST be unique! If the target reuses the same handle for hardware with both recording and playback interfaces, wrap it in a pointer you SDL_malloc'd!
|
// device handles MUST be unique! If the target reuses the same handle for hardware with both recording and playback interfaces, wrap it in a pointer you SDL_malloc'd!
|
||||||
SDL_assert(SDL_FindPhysicalAudioDeviceByHandle(handle) == NULL);
|
SDL_assert(SDL_FindPhysicalAudioDeviceByHandle(handle) == NULL);
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ extern void SDL_SetupAudioResampler(void);
|
|||||||
/* Backends should call this as devices are added to the system (such as
|
/* Backends should call this as devices are added to the system (such as
|
||||||
a USB headset being plugged in), and should also be called for
|
a USB headset being plugged in), and should also be called for
|
||||||
for every device found during DetectDevices(). */
|
for every device found during DetectDevices(). */
|
||||||
extern SDL_AudioDevice *SDL_AddAudioDevice(const SDL_bool recording, const char *name, const SDL_AudioSpec *spec, void *handle);
|
extern SDL_AudioDevice *SDL_AddAudioDevice(SDL_bool recording, const char *name, const SDL_AudioSpec *spec, void *handle);
|
||||||
|
|
||||||
/* Backends should call this if an opened audio device is lost.
|
/* Backends should call this if an opened audio device is lost.
|
||||||
This can happen due to i/o errors, or a device being unplugged, etc. */
|
This can happen due to i/o errors, or a device being unplugged, etc. */
|
||||||
|
|||||||
Reference in New Issue
Block a user