| Index: webrtc/media/engine/webrtcvideoframe.cc
|
| diff --git a/webrtc/media/engine/webrtcvideoframe.cc b/webrtc/media/engine/webrtcvideoframe.cc
|
| index 4f89c8b85d100562d14cb891c6b11e8f67f247d1..091adc3c9ac26ad49ab6865fbe104d7e87373390 100644
|
| --- a/webrtc/media/engine/webrtcvideoframe.cc
|
| +++ b/webrtc/media/engine/webrtcvideoframe.cc
|
| @@ -149,26 +149,11 @@ bool WebRtcVideoFrame::Reset(uint32_t format,
|
| return true;
|
| }
|
|
|
| -VideoFrame* WebRtcVideoFrame::CreateEmptyFrame(int w,
|
| - int h,
|
| - int64_t timestamp_us) const {
|
| - WebRtcVideoFrame* frame = new WebRtcVideoFrame();
|
| - frame->InitToEmptyBuffer(w, h, rtc::kNumNanosecsPerMicrosec * timestamp_us);
|
| - return frame;
|
| -}
|
| -
|
| void WebRtcVideoFrame::InitToEmptyBuffer(int w, int h) {
|
| video_frame_buffer_ = new rtc::RefCountedObject<webrtc::I420Buffer>(w, h);
|
| rotation_ = webrtc::kVideoRotation_0;
|
| }
|
|
|
| -void WebRtcVideoFrame::InitToEmptyBuffer(int w, int h,
|
| - int64_t time_stamp_ns) {
|
| - video_frame_buffer_ = new rtc::RefCountedObject<webrtc::I420Buffer>(w, h);
|
| - SetTimeStamp(time_stamp_ns);
|
| - rotation_ = webrtc::kVideoRotation_0;
|
| -}
|
| -
|
| const VideoFrame* WebRtcVideoFrame::GetCopyWithRotationApplied() const {
|
| // If the frame is not rotated, the caller should reuse this frame instead of
|
| // making a redundant copy.
|
| @@ -197,7 +182,9 @@ const VideoFrame* WebRtcVideoFrame::GetCopyWithRotationApplied() const {
|
| }
|
|
|
| rotated_frame_.reset(
|
| - CreateEmptyFrame(rotated_width, rotated_height, timestamp_us_));
|
| + new WebRtcVideoFrame(new rtc::RefCountedObject<webrtc::I420Buffer>(
|
| + rotated_width, rotated_height),
|
| + webrtc::kVideoRotation_0, timestamp_us_));
|
|
|
| // TODO(guoweis): Add a function in webrtc_libyuv.cc to convert from
|
| // VideoRotation to libyuv::RotationMode.
|
|
|