diff options
author | Chris Robinson <[email protected]> | 2023-05-30 21:16:41 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2023-05-30 21:16:41 -0700 |
commit | 517bb94c0953de768f6aacca45456fd63bb2c96d (patch) | |
tree | 28852929ea0c61e1e7ad6f20233c861c5ae3f040 /alc/inprogext.h | |
parent | 2e75909ce90027267775d53e997d4936d6ef31a5 (diff) |
Add a callback to report system device changes
Devices being added or removed, or the default device changing. Not all
backends report this (none do currently), but it'll be supported where it can.
Diffstat (limited to 'alc/inprogext.h')
-rw-r--r-- | alc/inprogext.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/alc/inprogext.h b/alc/inprogext.h index 38ef2bf8..7cf49868 100644 --- a/alc/inprogext.h +++ b/alc/inprogext.h @@ -443,6 +443,21 @@ ALenum AL_APIENTRY EAXGetBufferModeDirect(ALCcontext *context, ALuint buffer, AL #endif #endif +#ifndef ALC_SOFT_system_events +#define ALC_SOFT_system_events +#define ALC_EVENT_TYPE_DEFAULT_DEVICE_CHANGED_SOFT 0x19CF +#define ALC_EVENT_TYPE_DEVICE_ADDED_SOFT 0x19D0 +#define ALC_EVENT_TYPE_DEVICE_REMOVED_SOFT 0x19D1 +typedef void (ALC_APIENTRY*ALCEVENTPROCTYPESOFT)(ALCenum eventType, ALCdevice *device, + ALCsizei length, const ALCchar *message, void *userParam) ALC_API_NOEXCEPT17; +typedef ALCboolean (ALC_APIENTRY*LPALCEVENTCONTROLSOFT)(ALCsizei count, const ALCenum *types, ALCboolean enable) ALC_API_NOEXCEPT17; +typedef void (ALC_APIENTRY*LPALCEVENTCALLBACKSOFT)(ALCEVENTPROCTYPESOFT callback, void *userParam) ALC_API_NOEXCEPT17; +#ifdef AL_ALEXT_PROTOTYPES +ALCboolean ALC_APIENTRY alcEventControlSOFT(ALCsizei count, const ALCenum *types, ALCboolean enable) ALC_API_NOEXCEPT; +void ALC_APIENTRY alcEventCallbackSOFT(ALCEVENTPROCTYPESOFT callback, void *userParam) ALC_API_NOEXCEPT; +#endif +#endif + /* Non-standard export. Not part of any extension. */ AL_API const ALchar* AL_APIENTRY alsoft_get_version(void) noexcept; |