From c03603b58d4cf6a25d36bca00305970bc9f163b4 Mon Sep 17 00:00:00 2001 From: MathiusD Date: Sun, 26 Nov 2023 03:33:00 +0100 Subject: Add query fonction in ALC_SOFT_system_events unreleased extension (#938) * feat(ALC_SOFT_system_events): Add alcEventIsSupportedSOFT method in ALC_SOFT_system_events unreleased extension The purpose of this addition (to my collection) are allow to retrieve which events are supported and if events are fully supported or if some case isn't managed for some reason For exemple only some backends provide system events: * pipewire -> Full support of extension * wasapi -> Full support of extension * pulseaudio -> Support of add and remove devices events only * coreaudio -> Support of default device change only * feat(ALC_SOFT_system_events): Fix typo in alext.h Cf following review : https://github.com/kcat/openal-soft/pull/938#discussion_r1404509828 * feat(ALC_SOFT_system_events): Remove ALC_EVENT_NOT_SUPPORTED_SOFT token Cf following discussions between this comment : https://github.com/kcat/openal-soft/pull/938#issuecomment-1825876452 to this comment : https://github.com/kcat/openal-soft/pull/938#issuecomment-1826419406 --- alc/backends/base.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'alc/backends/base.h') diff --git a/alc/backends/base.h b/alc/backends/base.h index a4079fe4..ea3b57a3 100644 --- a/alc/backends/base.h +++ b/alc/backends/base.h @@ -11,6 +11,7 @@ #include "core/device.h" #include "core/except.h" +#include "alc/events.h" using uint = unsigned int; @@ -79,6 +80,10 @@ struct BackendFactory { virtual bool querySupport(BackendType type) = 0; + virtual alc::EventSupport queryEventSupport(alc::EventType eventType, BackendType type) { + return alc::EventSupport::NoSupport; + } + virtual std::string probe(BackendType type) = 0; virtual BackendPtr createBackend(DeviceBase *device, BackendType type) = 0; -- cgit v1.2.3