Added various timestamps to FrameObject.

Added various timestamps to the FrameObject class which are needed to calculate
the jitter delay.

BUG=webrtc:5514

Review-Url: https://codereview.webrtc.org/2124943002
Cr-Commit-Position: refs/heads/master@{#13434}
This commit is contained in:
philipel
2016-07-11 08:46:29 -07:00
committed by Commit bot
parent 65a001fe30
commit b4d31085b4
6 changed files with 67 additions and 16 deletions

View File

@ -16,14 +16,17 @@
#include "webrtc/base/checks.h"
#include "webrtc/base/logging.h"
#include "webrtc/modules/video_coding/frame_object.h"
#include "webrtc/system_wrappers/include/clock.h"
namespace webrtc {
namespace video_coding {
PacketBuffer::PacketBuffer(size_t start_buffer_size,
PacketBuffer::PacketBuffer(Clock* clock,
size_t start_buffer_size,
size_t max_buffer_size,
OnCompleteFrameCallback* frame_callback)
: size_(start_buffer_size),
: clock_(clock),
size_(start_buffer_size),
max_size_(max_buffer_size),
first_seq_num_(0),
last_seq_num_(0),
@ -163,8 +166,9 @@ void PacketBuffer::FindFrames(uint16_t seq_num) {
start_seq_num--;
}
std::unique_ptr<RtpFrameObject> frame(new RtpFrameObject(
this, start_seq_num, seq_num, frame_size, max_nack_count));
std::unique_ptr<RtpFrameObject> frame(
new RtpFrameObject(this, start_seq_num, seq_num, frame_size,
max_nack_count, clock_->TimeInMilliseconds()));
reference_finder_.ManageFrame(std::move(frame));
}