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

Unified Diff: webrtc/common_video/video_frame.cc

Issue 2378003002: Delete webrtc::VideoFrame::CreateEmptyFrame. (Closed)
Patch Set: Added size_t/int cast, needed for windows 64-bit builds. Created 4 years, 3 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/common_video/video_frame.cc
diff --git a/webrtc/common_video/video_frame.cc b/webrtc/common_video/video_frame.cc
index a9f0b4d295ee44c05c925e1724653087284a13c6..9a8f8ab3187e10d5f1eb15dc8226f3bcf23ef4e9 100644
--- a/webrtc/common_video/video_frame.cc
+++ b/webrtc/common_video/video_frame.cc
@@ -51,29 +51,6 @@ VideoFrame::VideoFrame(const rtc::scoped_refptr<VideoFrameBuffer>& buffer,
RTC_DCHECK(buffer);
}
-void VideoFrame::CreateEmptyFrame(int width,
- int height,
- int stride_y,
- int stride_u,
- int stride_v) {
- const int half_width = (width + 1) / 2;
- RTC_DCHECK_GT(width, 0);
- RTC_DCHECK_GT(height, 0);
- RTC_DCHECK_GE(stride_y, width);
- RTC_DCHECK_GE(stride_u, half_width);
- RTC_DCHECK_GE(stride_v, half_width);
-
- // Creating empty frame - reset all values.
- timestamp_rtp_ = 0;
- ntp_time_ms_ = 0;
- timestamp_us_ = 0;
- rotation_ = kVideoRotation_0;
-
- // Allocate a new buffer.
- video_frame_buffer_ = I420Buffer::Create(
- width, height, stride_y, stride_u, stride_v);
-}
-
void VideoFrame::CreateFrame(const uint8_t* buffer_y,
const uint8_t* buffer_u,
const uint8_t* buffer_v,
« no previous file with comments | « webrtc/common_video/i420_video_frame_unittest.cc ('k') | webrtc/modules/video_coding/video_sender_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698