1 year ago
#287589

Chris
Play but don't record avaudioplayer background music
I have an app that records a video/audio like Instagram stories with avassetwriter
and simultaneously plays an audio background music file with avaudioplayer
. It both records and plays great.
The problem I am noticing though, is when I play back the recording, the background music is extremely loud, and I'm assuming it's because the mic and the bottom-of-the-phone default speaker, through which the audio background music is playing out of, are situated right next to each other - even though when I record it sounds like it's not that loud.
Is there any possible way or workaround that results in allowing the background music to play while recording but to not have it actually be recorded? I'm stumped on what my options are, and am desperately hoping to see if anyone else had any ideas/thoughts as I couldn't find any existing content addressing this issue.
ios
swift
avplayer
avaudioplayer
avassetwriter
0 Answers
Your Answer