I am developing a karaoke app and i have been dealing with audio from android.I want an opinion on how can i save a single song from a voice recorded and another song playing in the background.
Thanks
You can try FFMPEG Library for Android, consider using android wrapper. There are several SO answers of help
Audio song mixer in android programmatically
How to overlay two audio files using ffmpeg
FFmpeg on Android
You may want to check amerge and amix ffmpeg filters based on your needs
SoundPool is a good option if requirements can be met just by playing two audio streams together.
SoundPool can also manage the number of audio streams being rendered at once. When the SoundPool object is constructed, the maxStreams parameter sets the maximum number of streams that can be played at a time from this single SoundPool.
Also note Android - Lollipop version now supports multi-channel audio stream mixing
Multi-channel audio stream mixing means professional audio applications can now mix up to eight channels including 5.1 and 7.1 channels.
Multi-channel support
If your hardware and driver supports multichannel audio via HDMI, you can output the audio stream directly to the audio hardware.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With