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

Side by Side Diff: media/filters/gpu_video_decoder.cc

Issue 819203002: Make callers of CommandLine use it via the base:: namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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 unified diff | Download patch
« no previous file with comments | « media/filters/ffmpeg_video_decoder.cc ('k') | media/filters/vpx_video_decoder.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "media/filters/gpu_video_decoder.h" 5 #include "media/filters/gpu_video_decoder.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback_helpers.h" 10 #include "base/callback_helpers.h"
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 // Only non-Windows, Ivy Bridge+ platforms can support more than 1920x1080. 110 // Only non-Windows, Ivy Bridge+ platforms can support more than 1920x1080.
111 // We test against 1088 to account for 16x16 macroblocks. 111 // We test against 1088 to account for 16x16 macroblocks.
112 if (coded_size.width() <= 1920 && coded_size.height() <= 1088) 112 if (coded_size.width() <= 1920 && coded_size.height() <= 1088)
113 return true; 113 return true;
114 114
115 // NOTE: additional autodetection logic may require updating input buffer size 115 // NOTE: additional autodetection logic may require updating input buffer size
116 // selection in platform-specific implementations, such as 116 // selection in platform-specific implementations, such as
117 // V4L2VideoDecodeAccelerator. 117 // V4L2VideoDecodeAccelerator.
118 base::CPU cpu; 118 base::CPU cpu;
119 bool hw_large_video_support = 119 bool hw_large_video_support =
120 CommandLine::ForCurrentProcess()->HasSwitch( 120 base::CommandLine::ForCurrentProcess()->HasSwitch(
121 switches::kIgnoreResolutionLimitsForAcceleratedVideoDecode) || 121 switches::kIgnoreResolutionLimitsForAcceleratedVideoDecode) ||
122 ((cpu.vendor_name() == "GenuineIntel") && cpu.model() >= 55); 122 ((cpu.vendor_name() == "GenuineIntel") && cpu.model() >= 55);
123 bool os_large_video_support = true; 123 bool os_large_video_support = true;
124 #if defined(OS_WIN) 124 #if defined(OS_WIN)
125 os_large_video_support = false; 125 os_large_video_support = false;
126 #endif 126 #endif
127 return os_large_video_support && hw_large_video_support; 127 return os_large_video_support && hw_large_video_support;
128 } 128 }
129 129
130 // Report |status| to UMA and run |cb| with it. This is super-specific to the 130 // Report |status| to UMA and run |cb| with it. This is super-specific to the
(...skipping 491 matching lines...) Expand 10 before | Expand all | Expand 10 after
622 DLOG(ERROR) << "VDA Error: " << error; 622 DLOG(ERROR) << "VDA Error: " << error;
623 DestroyVDA(); 623 DestroyVDA();
624 } 624 }
625 625
626 void GpuVideoDecoder::DCheckGpuVideoAcceleratorFactoriesTaskRunnerIsCurrent() 626 void GpuVideoDecoder::DCheckGpuVideoAcceleratorFactoriesTaskRunnerIsCurrent()
627 const { 627 const {
628 DCHECK(factories_->GetTaskRunner()->BelongsToCurrentThread()); 628 DCHECK(factories_->GetTaskRunner()->BelongsToCurrentThread());
629 } 629 }
630 630
631 } // namespace media 631 } // namespace media
OLDNEW
« no previous file with comments | « media/filters/ffmpeg_video_decoder.cc ('k') | media/filters/vpx_video_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698