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

Unified Diff: webrtc/modules/video_coding/utility/quality_scaler.cc

Issue 1886113003: Add rotation to EncodedImage and make sure it is passed through encoders. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fix merge mistake. Created 4 years, 8 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
« no previous file with comments | « webrtc/modules/video_coding/generic_encoder.cc ('k') | webrtc/test/call_test.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/video_coding/utility/quality_scaler.cc
diff --git a/webrtc/modules/video_coding/utility/quality_scaler.cc b/webrtc/modules/video_coding/utility/quality_scaler.cc
index a5e8c22bb093fe6bd776d4c6983f9eee3c2a8e77..5b2e94b88d53e85dd36c3b30da7c4b33a5c298a8 100644
--- a/webrtc/modules/video_coding/utility/quality_scaler.cc
+++ b/webrtc/modules/video_coding/utility/quality_scaler.cc
@@ -144,9 +144,15 @@ const VideoFrame& QualityScaler::GetScaledFrame(const VideoFrame& frame) {
if (scaler_.Scale(frame, &scaled_frame_) != 0)
return frame;
+ // TODO(perkj): Refactor the scaler to not own |scaled_frame|. VideoFrame are
+ // just thin wrappers so instead the scaler should return a
+ // rtc::scoped_refptr<VideoFrameBuffer> and a new VideoFrame be created with
+ // the meta data from |frame|. That way we would not have to set all these
+ // meta data.
scaled_frame_.set_ntp_time_ms(frame.ntp_time_ms());
scaled_frame_.set_timestamp(frame.timestamp());
scaled_frame_.set_render_time_ms(frame.render_time_ms());
+ scaled_frame_.set_rotation(frame.rotation());
return scaled_frame_;
}
« no previous file with comments | « webrtc/modules/video_coding/generic_encoder.cc ('k') | webrtc/test/call_test.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698