Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(833)

Unified Diff: webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc

Issue 3000713002: Add audio_level member to RtpSource and set it from RtpReceiverImpl::IncomingRtpPacket. (Closed)
Patch Set: Created 3 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc
diff --git a/webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc b/webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc
index 20f57460a68ffc1cb30d84b43e46dd2361400c7f..f0c5c99bda93606d3802527dae11c4fb4d006dbb 100644
--- a/webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc
+++ b/webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc
@@ -165,6 +165,12 @@ bool RtpReceiverImpl::IncomingRtpPacket(
UpdateSources();
+ auto source = ssrc_sources_.rbegin();
danilchap 2017/08/15 08:18:29 though it is not annotated, it seems ssrc_sources_
Zach Stein 2017/08/15 21:44:59 Done.
+ source->update_audio_level(
danilchap 2017/08/15 08:18:29 minor suggestion to use back() instead of rbegin()
Zach Stein 2017/08/15 21:44:59 Done.
+ rtp_header.extension.hasAudioLevel
+ ? rtc::Optional<uint8_t>(rtp_header.extension.audioLevel)
+ : rtc::Optional<uint8_t>());
+
size_t payload_data_length = payload_length - rtp_header.paddingLength;
bool is_first_packet_in_frame = false;

Powered by Google App Engine
This is Rietveld 408576698