Combine two audio blob recordings

2019-04-29 11:45发布

问题:

I am using recorder.js to record two audio files on my web page, which then creates recordings as blobs.

Once I have these audio blobs I would then like to combine them both into one track to be played by another html5 audio player.

I've searched the internet but I can't seem to find any documentation on combining two blob files into one.

I've found how to concatenate one blob to the other but I'm wanting to merge the files at the beginning.

i.e. - sound 1 is singing and sound 2 is guitar.

回答1:

I made a similar attempt using recorder.js and it did not work out for me too. Even after downloading the concatenated audio file, the time duration displayed by the audio player remained as the time duration of the first audio blob, though the whole concatenated audio content was available. So after several changes and hair tearing moments I chose to concatenate using ffmpeg. Here is link to my repository (Audio-Recording-App)