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

Unified Diff: webrtc/modules/video_coding/codecs/h264/h264_decoder_impl.cc

Issue 2772033002: Add content type information to encoded images and corresponding rtp extension header (Closed)
Patch Set: Fix Mac CE Created 3 years, 9 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/codecs/h264/h264_decoder_impl.cc
diff --git a/webrtc/modules/video_coding/codecs/h264/h264_decoder_impl.cc b/webrtc/modules/video_coding/codecs/h264/h264_decoder_impl.cc
index 8407451bd4d7658595c28acba9ec04bcb7d1c997..659ea767df8d164c69948f7c5998a302982315a1 100644
--- a/webrtc/modules/video_coding/codecs/h264/h264_decoder_impl.cc
+++ b/webrtc/modules/video_coding/codecs/h264/h264_decoder_impl.cc
@@ -156,13 +156,10 @@ int H264DecoderImpl::AVGetBuffer2(
// TODO(nisse): The VideoFrame's timestamp and rotation info is not used.
// Refactor to do not use a VideoFrame object at all.
av_frame->buf[0] = av_buffer_create(
- av_frame->data[kYPlaneIndex],
- total_size,
- AVFreeBuffer2,
- static_cast<void*>(new VideoFrame(frame_buffer,
- 0 /* timestamp */,
- 0 /* render_time_ms */,
- kVideoRotation_0)),
+ av_frame->data[kYPlaneIndex], total_size, AVFreeBuffer2,
+ static_cast<void*>(new VideoFrame(
+ frame_buffer, 0 /* timestamp */, 0 /* render_time_ms */,
+ kVideoRotation_0, VideoContentType::kDefault)),
0);
RTC_CHECK(av_frame->buf[0]);
return 0;
@@ -380,7 +377,7 @@ int32_t H264DecoderImpl::Decode(const EncodedImage& input_image,
rtc::KeepRefUntilDone(buf)));
VideoFrame cropped_frame(
cropped_buf, video_frame->timestamp(), video_frame->render_time_ms(),
- video_frame->rotation());
+ video_frame->rotation(), video_frame->content_type());
// TODO(nisse): Timestamp and rotation are all zero here. Change decoder
// interface to pass a VideoFrameBuffer instead of a VideoFrame?
decoded_image_callback_->Decoded(cropped_frame, rtc::Optional<int32_t>(),

Powered by Google App Engine
This is Rietveld 408576698