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

Side by Side Diff: content/public/browser/gpu_utils.cc

Issue 2440093003: WIP GPU scheduler + delayed activation / tile draw
Patch Set: SignalSyncToken -> IsFenceSyncReleased Created 4 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 | « content/common/gpu_host_messages.h ('k') | content/public/common/content_switches.h » ('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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "content/public/browser/gpu_utils.h" 5 #include "content/public/browser/gpu_utils.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "content/public/common/content_switches.h" 9 #include "content/public/common/content_switches.h"
10 #include "gpu/command_buffer/service/gpu_switches.h" 10 #include "gpu/command_buffer/service/gpu_switches.h"
(...skipping 20 matching lines...) Expand all
31 DCHECK(base::CommandLine::InitializedForCurrentProcess()); 31 DCHECK(base::CommandLine::InitializedForCurrentProcess());
32 const base::CommandLine* command_line = 32 const base::CommandLine* command_line =
33 base::CommandLine::ForCurrentProcess(); 33 base::CommandLine::ForCurrentProcess();
34 gpu::GpuPreferences gpu_preferences; 34 gpu::GpuPreferences gpu_preferences;
35 gpu_preferences.single_process = 35 gpu_preferences.single_process =
36 command_line->HasSwitch(switches::kSingleProcess); 36 command_line->HasSwitch(switches::kSingleProcess);
37 gpu_preferences.in_process_gpu = 37 gpu_preferences.in_process_gpu =
38 command_line->HasSwitch(switches::kInProcessGPU); 38 command_line->HasSwitch(switches::kInProcessGPU);
39 gpu_preferences.ui_prioritize_in_gpu_process = 39 gpu_preferences.ui_prioritize_in_gpu_process =
40 command_line->HasSwitch(switches::kUIPrioritizeInGpuProcess); 40 command_line->HasSwitch(switches::kUIPrioritizeInGpuProcess);
41 gpu_preferences.enable_gpu_scheduler =
42 command_line->HasSwitch(switches::kEnableGpuScheduler);
41 gpu_preferences.disable_accelerated_video_decode = 43 gpu_preferences.disable_accelerated_video_decode =
42 command_line->HasSwitch(switches::kDisableAcceleratedVideoDecode); 44 command_line->HasSwitch(switches::kDisableAcceleratedVideoDecode);
43 #if defined(OS_CHROMEOS) 45 #if defined(OS_CHROMEOS)
44 gpu_preferences.disable_vaapi_accelerated_video_encode = 46 gpu_preferences.disable_vaapi_accelerated_video_encode =
45 command_line->HasSwitch(switches::kDisableVaapiAcceleratedVideoEncode); 47 command_line->HasSwitch(switches::kDisableVaapiAcceleratedVideoEncode);
46 #endif 48 #endif
47 #if BUILDFLAG(ENABLE_WEBRTC) 49 #if BUILDFLAG(ENABLE_WEBRTC)
48 gpu_preferences.disable_web_rtc_hw_encoding = 50 gpu_preferences.disable_web_rtc_hw_encoding =
49 command_line->HasSwitch(switches::kDisableWebRtcHWEncoding) && 51 command_line->HasSwitch(switches::kDisableWebRtcHWEncoding) &&
50 command_line->GetSwitchValueASCII(switches::kDisableWebRtcHWEncoding) 52 command_line->GetSwitchValueASCII(switches::kDisableWebRtcHWEncoding)
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 gpu_preferences.enable_gpu_service_tracing = 111 gpu_preferences.enable_gpu_service_tracing =
110 command_line->HasSwitch(switches::kEnableGPUServiceTracing); 112 command_line->HasSwitch(switches::kEnableGPUServiceTracing);
111 gpu_preferences.use_passthrough_cmd_decoder = 113 gpu_preferences.use_passthrough_cmd_decoder =
112 command_line->HasSwitch(switches::kUsePassthroughCmdDecoder); 114 command_line->HasSwitch(switches::kUsePassthroughCmdDecoder);
113 // Some of these preferences are set or adjusted in 115 // Some of these preferences are set or adjusted in
114 // GpuDataManagerImplPrivate::AppendGpuCommandLine. 116 // GpuDataManagerImplPrivate::AppendGpuCommandLine.
115 return gpu_preferences; 117 return gpu_preferences;
116 } 118 }
117 119
118 } // namespace content 120 } // namespace content
OLDNEW
« no previous file with comments | « content/common/gpu_host_messages.h ('k') | content/public/common/content_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698