commit | d4fce5a361a4dba8a7c97e885af898e24344e7ec | [log] [tgz] |
---|---|---|
author | Peter Hanspers <peterhanspers@webrtc.org> | Thu Apr 28 18:38:01 2022 |
committer | WebRTC LUCI CQ <webrtc-scoped@luci-project-accounts.iam.gserviceaccount.com> | Fri Apr 29 14:07:02 2022 |
tree | d9ef0ed613c634fb679828b0f097cc44ea3344a9 | |
parent | 8ec4a2eca3a6bf8966ac07793297752b97a1ba18 [diff] |
Use playout sample rate for audio unit. Fixing a race condition where session.sampleRate changes before AudioDeviceIOS::HandleValidRouteChange() finishes. session.sampleRate is read into session_sample_rate at 576 and used at 623 to initialize the audio unit. However, in the call to SetupAudioBuffersForActiveAudioSession() the session.sampleRate is read again and may have changed, resulting in different sample rates used for the buffers and the audio unit. The consequence is a sample rate mismatch with either high pitched or low pitched audio. The fix is to always use the buffer sample rate for the audio unit. The DCHECK at 622 would save us in debug, but not in production, hence removed. Change-Id: I562f1bf7f94d7447139ada2636b02ade7fcd6371 Bug: webrtc:14011 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/260329 Reviewed-by: Henrik Andreasson <henrika@google.com> Commit-Queue: Peter Hanspers <peterhanspers@webrtc.org> Cr-Commit-Position: refs/heads/main@{#36708}
WebRTC is a free, open software project that provides browsers and mobile applications with Real-Time Communications (RTC) capabilities via simple APIs. The WebRTC components have been optimized to best serve this purpose.
Our mission: To enable rich, high-quality RTC applications to be developed for the browser, mobile platforms, and IoT devices, and allow them all to communicate via a common set of protocols.
The WebRTC initiative is a project supported by Google, Mozilla and Opera, amongst others.
See here for instructions on how to get started developing with the native code.
Authoritative list of directories that contain the native API header files.