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

Unified Diff: webrtc/modules/video_coding/frame_object.cc

Issue 2124943002: Added various timestamps to FrameObject. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: std::unique_ptr<Clock> instead of Clock*. Created 4 years, 5 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/video_coding/frame_object.cc
diff --git a/webrtc/modules/video_coding/frame_object.cc b/webrtc/modules/video_coding/frame_object.cc
index c33fdf749b81b908fab9c29497c4d61308692c44..c99e7f56e291b85626b43a29d031a598960f67f2 100644
--- a/webrtc/modules/video_coding/frame_object.cc
+++ b/webrtc/modules/video_coding/frame_object.cc
@@ -26,10 +26,12 @@ RtpFrameObject::RtpFrameObject(PacketBuffer* packet_buffer,
uint16_t first_seq_num,
uint16_t last_seq_num,
size_t frame_size,
- int times_nacked)
+ int times_nacked,
+ int64_t received_timestamp)
terelius 2016/07/07 16:12:30 If I understand the intended usage correctly, I wo
philipel 2016/07/08 09:41:19 This timestamp indicates when the last packet of t
stefan-webrtc 2016/07/08 10:33:39 Should it then be called last_packet_time or somet
philipel 2016/07/08 11:10:50 Hmmm... naming here is kind of hard. I have chosen
stefan-webrtc 2016/07/08 11:34:23 Yes, it's a good idea to try to be clear. In the o
stefan-webrtc 2016/07/08 11:35:27 BTW, might be a good idea to add a comment about t
philipel 2016/07/08 13:40:02 Maybe this convention would work: "received frame
: packet_buffer_(packet_buffer),
first_seq_num_(first_seq_num),
last_seq_num_(last_seq_num),
+ received_timestamp_(received_timestamp),
times_nacked_(times_nacked) {
size = frame_size;
VCMPacket* packet = packet_buffer_->GetPacket(first_seq_num);
@@ -84,6 +86,18 @@ bool RtpFrameObject::GetBitstream(uint8_t* destination) const {
return packet_buffer_->GetBitstream(*this, destination);
}
+uint32_t RtpFrameObject::Timestamp() const {
+ return timestamp_;
+}
+
+int64_t RtpFrameObject::ReceivedTimestamp() const {
+ return received_timestamp_;
+}
+
+int64_t RtpFrameObject::RenderTimestamp() const {
+ return _renderTimeMs;
+}
+
RTPVideoTypeHeader* RtpFrameObject::GetCodecHeader() const {
VCMPacket* packet = packet_buffer_->GetPacket(first_seq_num_);
if (!packet)

Powered by Google App Engine
This is Rietveld 408576698