mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-24 01:04:02 +02:00
Add some clarification notes for device notifications.
This commit is contained in:
+15
@@ -5821,6 +5821,21 @@ pNotification (in)
|
|||||||
Remarks
|
Remarks
|
||||||
-------
|
-------
|
||||||
Do not restart or uninitialize the device from the callback.
|
Do not restart or uninitialize the device from the callback.
|
||||||
|
|
||||||
|
Not all notifications will be triggered by all backends, however the started and stopped events
|
||||||
|
should be reliable for all backends. Some backends do not have a good way to detect device
|
||||||
|
stoppages due to unplugging the device which may result in the stopped callback not getting
|
||||||
|
fired. This has been observed with at least one BSD variant.
|
||||||
|
|
||||||
|
The rerouted notification is fired *after* the reroute has occurred. The stopped notification will
|
||||||
|
*not* get fired when a device is rerouted. The following backends are known to do automatic stream
|
||||||
|
rerouting, but do not have a way to be notified of the change:
|
||||||
|
|
||||||
|
* DirectSound
|
||||||
|
|
||||||
|
The interruption notifications are used on mobile platforms for detecting when audio is interrupted
|
||||||
|
due to things like an incoming phone call. Currently this is only implemented on iOS. None of the
|
||||||
|
Android backends will report this notification.
|
||||||
*/
|
*/
|
||||||
typedef void (* ma_device_notification_proc)(const ma_device_notification* pNotification);
|
typedef void (* ma_device_notification_proc)(const ma_device_notification* pNotification);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user