Revert of Delete deprecated and transitional stuff related to video frame refactoring. (patchset #17 id:320001 of https://codereview.webrtc.org/2622263002/ )

Reason for revert:
Broke Chrome build, see, e.g.,
http://build.chromium.org/p/chromium.webrtc.fyi/builders/Linux%20Builder/builds/16237

Original issue's description:
> Delete deprecated and transitional stuff related to video frame refactoring.
>
> BUG=webrtc:5880
>
> Review-Url: https://codereview.webrtc.org/2622263002
> Cr-Commit-Position: refs/heads/master@{#17928}
> Committed: 713a3bbcc7

TBR=mflodman@webrtc.org,perkj@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:5880

Review-Url: https://codereview.webrtc.org/2845333002
Cr-Commit-Position: refs/heads/master@{#17929}
This commit is contained in:
nisse
2017-04-28 06:03:40 -07:00
committed by Commit bot
parent 713a3bbcc7
commit aec49d2b49
26 changed files with 151 additions and 21 deletions

View File

@ -160,7 +160,7 @@ void AVFoundationVideoCapturer::CaptureSampleBuffer(
// Applying rotation is only supported for legacy reasons and performance is
// not critical here.
if (apply_rotation() && rotation != kVideoRotation_0) {
buffer = I420Buffer::Rotate(*buffer->NativeToI420Buffer(),
buffer = I420Buffer::Rotate(buffer->NativeToI420Buffer(),
rotation);
if (rotation == kVideoRotation_90 || rotation == kVideoRotation_270) {
std::swap(captured_width, captured_height);

View File

@ -12,7 +12,6 @@
#import "RTCVideoFrame+Private.h"
#include "webrtc/api/video/i420_buffer.h"
#include "webrtc/common_video/include/corevideo_frame_buffer.h"
namespace webrtc {
@ -61,7 +60,7 @@ void ObjcVideoTrackSource::OnCapturedFrame(RTCVideoFrame* frame) {
// not critical here.
webrtc::VideoRotation rotation = static_cast<webrtc::VideoRotation>(frame.rotation);
if (apply_rotation() && rotation != kVideoRotation_0) {
buffer = I420Buffer::Rotate(*buffer->NativeToI420Buffer(), rotation);
buffer = I420Buffer::Rotate(buffer->NativeToI420Buffer(), rotation);
rotation = kVideoRotation_0;
}