收藏
回答

录音格式为"aac",onFrameRecorded得到的数据是acc的净荷还是包含了acc的头?

//开始录音

    startRecord() {

        if (this.data.recorder != null) {

            let options = {}

            //组织录音参数

            options.duration = 600000 //最长连续录音10分钟

            options.sampleRate = 48000 //采样频率

            options.encodeBitRate = 192000 //编码率

            options.numberOfChannels = 1 //单通道采样

            options.format = "acc"

            options.frameSize = "22" //单位kB(数据不会太准确,因此需要缓存数据以实施成帧操作)

            options.audioSource = "auto"//录音源,默认使用手机麦克风,插上耳麦后自动切换使用耳机麦克风,所有平台适用。

            //开始录音

            this.data.recorder.start(options)

        }

    },

回答关注问题邀请回答
收藏

1 个回答

登录 后发表内容