Calculate JitterBufferDelayInMs in the new jitter buffer.

JitterBufferDelayInMs is used for the WebRTC-NewVideoJitterBuffer finch
experiment, and therefore needs to be calculated.

BUG=webrtc:5514

Review-Url: https://codereview.webrtc.org/2534093003
Cr-Commit-Position: refs/heads/master@{#15313}
This commit is contained in:
philipel
2016-11-30 01:31:40 -08:00
committed by Commit bot
parent e69b46863a
commit be74270ebe
3 changed files with 37 additions and 9 deletions

View File

@ -139,6 +139,8 @@ class FrameBuffer {
FrameMap::iterator info)
EXCLUSIVE_LOCKS_REQUIRED(crit_);
void UpdateJitterDelay() EXCLUSIVE_LOCKS_REQUIRED(crit_);
void UpdateHistograms() const;
FrameMap frames_ GUARDED_BY(crit_);
@ -155,10 +157,16 @@ class FrameBuffer {
int num_frames_buffered_ GUARDED_BY(crit_);
bool stopped_ GUARDED_BY(crit_);
VCMVideoProtection protection_mode_ GUARDED_BY(crit_);
int num_total_frames_ GUARDED_BY(crit_);
int num_key_frames_ GUARDED_BY(crit_);
RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(FrameBuffer);
// For WebRTC.Video.JitterBufferDelayInMs metric.
int64_t accumulated_delay_ = 0;
int64_t accumulated_delay_samples_ = 0;
// For WebRTC.Video.KeyFramesReceivedInPermille metric.
int64_t num_total_frames_ = 0;
int64_t num_key_frames_ = 0;
};
} // namespace video_coding