Sample app for AudioPlaybackCapture API, which allows applications to capture the audio of other applications.
Tapping the "Start Recording" button on the UI will present two permission requests:
- Sample rate: 44100 Hz
- channel: 1 channel(Mono)
- encoding: PCM 16-bit
- byte-order: little endian
/storage/emulated/0/Android/data/com.myfreax.audiorecorder/files/AudioCaptures/
You can then pull the file from the device and play the media back. Make sure you use a player that is capable of rendering raw PCM data (for example, on Audacity, you can File > Import > Raw Data
).