合并两个音频Blob录音 [英] Combine two audio blob recordings

查看:202
本文介绍了合并两个音频Blob录音的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 recorder.js 在我的网页上录制两个音频文件,然后创建录音作为斑点.

一旦我有了这些音频Blob,我便希望将它们都合并到一个轨道中,以便由另一位html5音频播放器播放.

我已经搜索了互联网,但似乎找不到任何有关将两个Blob文件合并为一个文件的文档.

我已经找到了如何将一个Blob与另一个Blob连接起来,但是我想在开始时合并文件.

即-声音1在唱歌,声音2在吉他.

解决方案

我使用recorder.js进行了类似的尝试,但对我来说也没有用.即使下载了串联的音频文件之后,尽管整个串联的音频内容都可用,但音频播放器显示的持续时间仍保持为第一个音频Blob的持续时间.因此,在进行了几次更改和头发撕裂之后,我选择使用ffmpeg进行连接.这是指向我的存储库的链接( Audio-Recording-App )

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.

解决方案

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)

这篇关于合并两个音频Blob录音的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆