Reland "Improve outbound-rtp statistics for simulcast"

This reverts commit 9a925c9ce33a6ccdd11b545b11ba68e985c2a65d.

Reason for revert: The original CL is updated in PS #2 to
fix the googRtt issue which was that when the legacy sender
stats were put in "aggregated_senders" we forgot to update
rtt_ms the same way that we do it for "senders".

Original change's description:
> Revert "Improve outbound-rtp statistics for simulcast"
>
> This reverts commit da6cda839dac7d9d18eba8d365188fa94831e0b1.
>
> Reason for revert: Breaks googRtt in legacy getStats API
>
> Original change's description:
> > Improve outbound-rtp statistics for simulcast
> >
> > Bug: webrtc:9547
> > Change-Id: Iec4eb976aa11ee743805425bedb77dcea7c2c9be
> > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/168120
> > Reviewed-by: Sebastian Jansson <srte@webrtc.org>
> > Reviewed-by: Erik Språng <sprang@webrtc.org>
> > Reviewed-by: Henrik Boström <hbos@webrtc.org>
> > Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> > Commit-Queue: Eldar Rello <elrello@microsoft.com>
> > Cr-Commit-Position: refs/heads/master@{#31097}
>
> TBR=hbos@webrtc.org,sprang@webrtc.org,stefan@webrtc.org,srte@webrtc.org,hta@webrtc.org,elrello@microsoft.com
>
> # Not skipping CQ checks because original CL landed > 1 day ago.
>
> Bug: webrtc:9547
> Change-Id: I06673328c2a5293a7eef03b3aaf2ded9d13df1b3
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/174443
> Reviewed-by: Henrik Boström <hbos@webrtc.org>
> Commit-Queue: Henrik Boström <hbos@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#31165}

TBR=hbos@webrtc.org,sprang@webrtc.org,stefan@webrtc.org,srte@webrtc.org,hta@webrtc.org,elrello@microsoft.com

# Not skipping CQ checks because this is a reland.

Bug: webrtc:9547
Change-Id: I723744c496c3c65f95ab6a8940862c8b9f544338
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/174480
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Henrik Boström <hbos@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#31169}
This commit is contained in:
Henrik Boström
2020-05-05 15:54:46 +02:00
committed by Commit Bot
parent c0df5fc25b
commit a0ff50c031
23 changed files with 792 additions and 150 deletions

View File

@ -698,6 +698,7 @@ WEBRTC_RTCSTATS_IMPL(
RTCOutboundRTPStreamStats, RTCRTPStreamStats, "outbound-rtp",
&media_source_id,
&remote_id,
&rid,
&packets_sent,
&retransmitted_packets_sent,
&bytes_sent,
@ -708,6 +709,11 @@ WEBRTC_RTCSTATS_IMPL(
&key_frames_encoded,
&total_encode_time,
&total_encoded_bytes_target,
&frame_width,
&frame_height,
&frames_per_second,
&frames_sent,
&huge_frames_sent,
&total_packet_send_delay,
&quality_limitation_reason,
&quality_limitation_resolution_changes,
@ -724,6 +730,7 @@ RTCOutboundRTPStreamStats::RTCOutboundRTPStreamStats(std::string&& id,
: RTCRTPStreamStats(std::move(id), timestamp_us),
media_source_id("mediaSourceId"),
remote_id("remoteId"),
rid("rid"),
packets_sent("packetsSent"),
retransmitted_packets_sent("retransmittedPacketsSent"),
bytes_sent("bytesSent"),
@ -734,6 +741,11 @@ RTCOutboundRTPStreamStats::RTCOutboundRTPStreamStats(std::string&& id,
key_frames_encoded("keyFramesEncoded"),
total_encode_time("totalEncodeTime"),
total_encoded_bytes_target("totalEncodedBytesTarget"),
frame_width("frameWidth"),
frame_height("frameHeight"),
frames_per_second("framesPerSecond"),
frames_sent("framesSent"),
huge_frames_sent("hugeFramesSent"),
total_packet_send_delay("totalPacketSendDelay"),
quality_limitation_reason("qualityLimitationReason"),
quality_limitation_resolution_changes(
@ -746,6 +758,7 @@ RTCOutboundRTPStreamStats::RTCOutboundRTPStreamStats(
: RTCRTPStreamStats(other),
media_source_id(other.media_source_id),
remote_id(other.remote_id),
rid(other.rid),
packets_sent(other.packets_sent),
retransmitted_packets_sent(other.retransmitted_packets_sent),
bytes_sent(other.bytes_sent),
@ -756,6 +769,11 @@ RTCOutboundRTPStreamStats::RTCOutboundRTPStreamStats(
key_frames_encoded(other.key_frames_encoded),
total_encode_time(other.total_encode_time),
total_encoded_bytes_target(other.total_encoded_bytes_target),
frame_width(other.frame_width),
frame_height(other.frame_height),
frames_per_second(other.frames_per_second),
frames_sent(other.frames_sent),
huge_frames_sent(other.huge_frames_sent),
total_packet_send_delay(other.total_packet_send_delay),
quality_limitation_reason(other.quality_limitation_reason),
quality_limitation_resolution_changes(