aboutsummaryrefslogtreecommitdiff
path: root/webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc
diff options
context:
space:
mode:
authorwu@webrtc.org <wu@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d>2014-04-15 17:46:33 +0000
committerwu@webrtc.org <wu@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d>2014-04-15 17:46:33 +0000
commit6c75c989648018a1537bb29d41fbcb730b143c15 (patch)
tree2c528362ac26c102e40dd137e9ac9250f41659cf /webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc
parent1fd5b45a0eb1359fa829a0d4cf93c48d47f3e519 (diff)
downloadwebrtc-6c75c989648018a1537bb29d41fbcb730b143c15.tar.gz
Propagate capture ntp timestamp from rtp to renderer.
Mostly the interface changes, the real implementation of ntp timestamp will come in a follow up cl. TEST=new tests and try bots BUG=3111 R=niklas.enbom@webrtc.org, stefan@webrtc.org Review URL: https://webrtc-codereview.appspot.com/11469004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@5911 4adac7df-926f-26a2-2b94-8c16560cd09d
Diffstat (limited to 'webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc')
-rw-r--r--webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc b/webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc
index 0a67064fbb..dfe76e0155 100644
--- a/webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc
+++ b/webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc
@@ -710,7 +710,7 @@ int VP8DecoderImpl::Decode(const EncodedImage& input_image,
}
img = vpx_codec_get_frame(decoder_, &iter);
- ret = ReturnFrame(img, input_image._timeStamp);
+ ret = ReturnFrame(img, input_image._timeStamp, input_image.ntp_time_ms_);
if (ret != 0) {
// Reset to avoid requesting key frames too often.
if (ret < 0 && propagation_cnt_ > 0)
@@ -790,7 +790,9 @@ int VP8DecoderImpl::DecodePartitions(
return WEBRTC_VIDEO_CODEC_OK;
}
-int VP8DecoderImpl::ReturnFrame(const vpx_image_t* img, uint32_t timestamp) {
+int VP8DecoderImpl::ReturnFrame(const vpx_image_t* img,
+ uint32_t timestamp,
+ int64_t ntp_time_ms) {
if (img == NULL) {
// Decoder OK and NULL image => No show frame
return WEBRTC_VIDEO_CODEC_NO_OUTPUT;
@@ -808,6 +810,7 @@ int VP8DecoderImpl::ReturnFrame(const vpx_image_t* img, uint32_t timestamp) {
img->stride[VPX_PLANE_U],
img->stride[VPX_PLANE_V]);
decoded_image_.set_timestamp(timestamp);
+ decoded_image_.set_ntp_time_ms(ntp_time_ms);
int ret = decode_complete_callback_->Decoded(decoded_image_);
if (ret != 0)
return ret;