commit | f0820ffd880925772f427fdc0df321308e53354d | [log] [tgz] |
---|---|---|
author | Rasmus Brandt <brandtr@webrtc.org> | Thu May 25 07:37:16 2023 |
committer | WebRTC LUCI CQ <webrtc-scoped@luci-project-accounts.iam.gserviceaccount.com> | Fri May 26 13:34:09 2023 |
tree | a1df717ccb861e31bf28db3f8e6093871cf7a31d | |
parent | 9caef2a8b88f389af10cee841732c42a98d3d45d [diff] [blame] |
Implement video versions of RTCInboundRtpStreamStats.jitterBuffer{Target,Minimum}Delay * https://www.w3.org/TR/webrtc-stats/#dom-rtcinboundrtpstreamstats-jitterbuffertargetdelay * https://www.w3.org/TR/webrtc-stats/#dom-rtcinboundrtpstreamstats-jitterbufferminimumdelay Tested: https://jsfiddle.net/pfgzj0yo/17/ Bug: webrtc:14244 Change-Id: I3d949ba63c8339b3881f5d00356559d5789d283d Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/304404 Commit-Queue: Henrik Boström <hbos@webrtc.org> Reviewed-by: Henrik Boström <hbos@webrtc.org> Reviewed-by: Åsa Persson <asapersson@webrtc.org> Cr-Commit-Position: refs/heads/main@{#40157}
diff --git a/video/receive_statistics_proxy.cc b/video/receive_statistics_proxy.cc index faa0ea9..049f212 100644 --- a/video/receive_statistics_proxy.cc +++ b/video/receive_statistics_proxy.cc
@@ -531,12 +531,15 @@ })); } -void ReceiveStatisticsProxy::OnDecodableFrame(TimeDelta jitter_buffer_delay) { +void ReceiveStatisticsProxy::OnDecodableFrame(TimeDelta jitter_buffer_delay, + TimeDelta target_delay, + TimeDelta minimum_delay) { RTC_DCHECK_RUN_ON(&main_thread_); // Cumulative stats exposed through standardized GetStats. - // TODO(crbug.com/webrtc/14244): Implement targetDelay and minimumDelay here. stats_.jitter_buffer_delay += jitter_buffer_delay; + stats_.jitter_buffer_target_delay += target_delay; ++stats_.jitter_buffer_emitted_count; + stats_.jitter_buffer_minimum_delay += minimum_delay; } void ReceiveStatisticsProxy::OnFrameBufferTimingsUpdated(