How to use WebRTC for 3A with AVAudioPCMBuffer data

  Kiến thức lập trình

Now I use AVAudioEngine to record audio, and want to improve the quality of audio data for ASR transfer later.

How can I use the function of WebRTC to process the Audio Data with the follow functions in WebRTC:

googEchoCancellation",
"googAutoGainControl",
"googNoiseSuppression"

I tried to use GoogleWebRTC for Cocoapods, and can’t find the api to set this.

let peerConnectionFactory = RTCPeerConnectionFactory()

        // Create audio constraints
        let audioConstraints = RTCMediaConstraints(mandatoryConstraints: nil, optionalConstraints: [
            "googEchoCancellation": "true",
            "googAutoGainControl": "true",
            "googNoiseSuppression": "true"
        ])

LEAVE A COMMENT