From deac4dea4fa3fde805c1b988a846e776a62b7b2c Mon Sep 17 00:00:00 2001 From: Philipp Hancke Date: Fri, 23 Jul 2021 07:08:33 +0200 Subject: [PATCH] red: copy audio level from main packet for recovery packet fill the audio level of the recovery packets from the main packet. While not exact, this should be close enough. Without this, the audio level in getStats() will be filled but the audio level in getSynchronizationSources() will be empty. In chrome this is easy to test, the audio level graph on https://webrtc.github.io/samples/src/content/peerconnection/audio/ will be empty all the time prior to this fix. BUG=webrtc:11640 Change-Id: Ia1e61fd1852445239021a76d08032120a92d83aa Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/226840 Reviewed-by: Henrik Lundin Commit-Queue: Henrik Lundin Cr-Commit-Position: refs/heads/master@{#34635} --- modules/audio_coding/neteq/red_payload_splitter.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/audio_coding/neteq/red_payload_splitter.cc b/modules/audio_coding/neteq/red_payload_splitter.cc index b7b4520d5b..7438f25301 100644 --- a/modules/audio_coding/neteq/red_payload_splitter.cc +++ b/modules/audio_coding/neteq/red_payload_splitter.cc @@ -136,7 +136,7 @@ bool RedPayloadSplitter::SplitRed(PacketList* packet_list) { /*ssrc=*/red_packet.packet_info.ssrc(), /*csrcs=*/std::vector(), /*rtp_timestamp=*/new_packet.timestamp, - /*audio_level=*/absl::nullopt, + red_packet.packet_info.audio_level(), /*absolute_capture_time=*/absl::nullopt, /*receive_time=*/red_packet.packet_info.receive_time()); new_packets.push_front(std::move(new_packet));