Pulp 1.88.0
Cross-platform audio plugin framework
Loading...
Searching...
No Matches
ios_audio_session.hpp
Go to the documentation of this file.
1#pragma once
2
3// C++ adapter over ios_audio_session.h.
4//
5// Wraps the C callback plumbing in a std::function-based subscription so
6// application code can subscribe without juggling raw function pointers
7// or user_data void*s. A single subscriber is supported for now —
8// matches how AVAudioSession delivers notifications (one
9// NotificationCenter observer per process that cares).
10
12
13#include <functional>
14#include <string_view>
15
16namespace pulp::format {
17
20 std::function<void(const PulpIosAudioSessionEvent&)>;
21
25
30
32std::string_view to_string(PulpIosAudioEvent event);
33
34} // namespace pulp::format
PulpIosAudioEvent
Definition ios_audio_session.h:23
What the product grants a device: the quota table indexed by capability tier and live thermal state.
Definition aax_editor.hpp:31
std::string_view to_string(PulpIosAudioEvent event)
Human-readable label for an event type (for logs and tests).
bool emit_ios_audio_session_event(const PulpIosAudioSessionEvent &event)
Emit a session event (usually from Swift).
std::function< void(const PulpIosAudioSessionEvent &)> IosAudioSessionListener
Typed callback — C++ side of the AVAudioSession bridge.
Definition ios_audio_session.hpp:19
void set_ios_audio_session_listener(IosAudioSessionListener listener)
Subscribe to session events.
Definition ios_audio_session.h:55