Audio
This section provides information on using Magic Leap 2's Audio API for audio input and output.
SDK 1.0.0 or greater
In Project Settings > XR Plugin Management > Magic Leap Settings, there will be a new checkbox to toggle usage of MLAudio
on
/off
. This switches between the usage of Java AudioTrack
(Android's default) and MLAudio
as the main playback API for the audio. These demos require MLAudio to be unchecked.
More Information
📄️ Audio Change Events
This section provides an example script that demonstrates how to subscribe to Magic Leap's Audio change events.
📄️ Audio Input
This section provides examples of how to use Magic Leap's APIs to record audio.