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

Unified Diff: webrtc/examples/peerconnection/client/main_wnd.cc

Issue 2285693002: New static I420Buffer::Rotate method, to replace GetCopyWithRotationApplied. (Closed)
Patch Set: Created 4 years, 4 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/examples/peerconnection/client/main_wnd.cc
diff --git a/webrtc/examples/peerconnection/client/main_wnd.cc b/webrtc/examples/peerconnection/client/main_wnd.cc
index 91e66cd519fab6b72b8734fa6ca44aeb3d8f5d09..9be7cd91c76ace151b1091c8e33363664ccb498e 100644
--- a/webrtc/examples/peerconnection/client/main_wnd.cc
+++ b/webrtc/examples/peerconnection/client/main_wnd.cc
@@ -604,13 +604,16 @@ void MainWnd::VideoRenderer::OnFrame(
{
AutoLock<VideoRenderer> lock(this);
- const cricket::VideoFrame* frame =
- video_frame.GetCopyWithRotationApplied();
+ const cricket::WebRtcVideoFrame frame(
+ webrtc::VideoFrameBuffer::Rotate(video_frame.video_frame_buffer(),
+ video_frame.rotation()),
+ webrtc::kVideoRotation_0,
+ video_frame.timestamp_us());
- SetSize(frame->width(), frame->height());
+ SetSize(frame.width(), frame.height());
ASSERT(image_.get() != NULL);
- frame->ConvertToRgbBuffer(cricket::FOURCC_ARGB,
+ frame.ConvertToRgbBuffer(cricket::FOURCC_ARGB,
image_.get(),
magjed_webrtc 2016/08/26 12:04:15 you need to adjust indentation here
nisse-webrtc 2016/08/26 12:31:40 Done.
bmi_.bmiHeader.biSizeImage,
bmi_.bmiHeader.biWidth *

Powered by Google App Engine
This is Rietveld 408576698