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

Unified Diff: media/remoting/remoting_renderer_controller.cc

Issue 2622803002: Clean-up: media::PipelineMetadata stores the rotated video size. (Closed)
Patch Set: Addressed comments. Created 3 years, 11 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 | « media/blink/webmediaplayer_impl_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/remoting/remoting_renderer_controller.cc
diff --git a/media/remoting/remoting_renderer_controller.cc b/media/remoting/remoting_renderer_controller.cc
index 211e654c9fbe4514e06a6c327c5f0ee12519150d..b3c21fae12323c0f10a954d5e04b88458a4cfb0f 100644
--- a/media/remoting/remoting_renderer_controller.cc
+++ b/media/remoting/remoting_renderer_controller.cc
@@ -11,16 +11,6 @@
namespace media {
-namespace {
-
-gfx::Size GetRotatedVideoSize(VideoRotation rotation, gfx::Size natural_size) {
- if (rotation == VIDEO_ROTATION_90 || rotation == VIDEO_ROTATION_270)
- return gfx::Size(natural_size.height(), natural_size.width());
- return natural_size;
-}
-
-} // namespace
-
RemotingRendererController::RemotingRendererController(
scoped_refptr<RemotingSourceImpl> remoting_source)
: remoting_source_(remoting_source), weak_factory_(this) {
@@ -173,14 +163,10 @@ void RemotingRendererController::OnMetadataChanged(
pipeline_metadata_ = metadata;
is_encrypted_ = false;
- if (has_video()) {
+ if (has_video())
is_encrypted_ |= metadata.video_decoder_config.is_encrypted();
- pipeline_metadata_.natural_size = GetRotatedVideoSize(
- pipeline_metadata_.video_rotation, pipeline_metadata_.natural_size);
- }
- if (has_audio()) {
+ if (has_audio())
is_encrypted_ |= metadata.audio_decoder_config.is_encrypted();
- }
if (pipeline_metadata_.natural_size != old_size)
UpdateInterstitial(base::nullopt);
« no previous file with comments | « media/blink/webmediaplayer_impl_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698