| Index: talk/app/webrtc/androidvideocapturer.cc
|
| diff --git a/talk/app/webrtc/androidvideocapturer.cc b/talk/app/webrtc/androidvideocapturer.cc
|
| index c4c5a480b4f759253d7062f0f2c8e671540259ca..d8f12174db4d81317795d144e73ecd46d8b57072 100644
|
| --- a/talk/app/webrtc/androidvideocapturer.cc
|
| +++ b/talk/app/webrtc/androidvideocapturer.cc
|
| @@ -102,12 +102,17 @@ class AndroidVideoCapturer::FrameFactory : public cricket::VideoFrameFactory {
|
| int output_width,
|
| int output_height) const override {
|
| if (buffer_->native_handle() != nullptr) {
|
| + // TODO(perkj) Implement cropping.
|
| + RTC_CHECK_EQ(cropped_input_width, buffer_->width());
|
| + RTC_CHECK_EQ(cropped_input_height, buffer_->height());
|
| rtc::scoped_refptr<webrtc::VideoFrameBuffer> scaled_buffer(
|
| static_cast<webrtc_jni::AndroidTextureBuffer*>(buffer_.get())
|
| - ->CropAndScale(cropped_input_width, cropped_input_height,
|
| - output_width, output_height));
|
| + ->ScaleAndRotate(output_width, output_height,
|
| + apply_rotation_ ? input_frame->rotation :
|
| + webrtc::kVideoRotation_0));
|
| return new cricket::WebRtcVideoFrame(
|
| - scaled_buffer, input_frame->time_stamp, input_frame->rotation);
|
| + scaled_buffer, input_frame->time_stamp,
|
| + apply_rotation_ ? webrtc::kVideoRotation_0 : input_frame->rotation);
|
| }
|
| return VideoFrameFactory::CreateAliasedFrame(input_frame,
|
| cropped_input_width,
|
|
|