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

Side by Side Diff: content/browser/gpu/gpu_process_host.cc

Issue 1998723002: Move code in ui/gl/* from gfx:: to gl:: (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 7 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 unified diff | Download patch
« no previous file with comments | « content/browser/gpu/gpu_ipc_browsertests.cc ('k') | content/browser/gpu/gpu_surface_tracker.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 (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 "content/browser/gpu/gpu_process_host.h" 5 #include "content/browser/gpu/gpu_process_host.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
198 return true; 198 return true;
199 } 199 }
200 200
201 // For the GPU process we gotten as far as USER_LIMITED. The next level 201 // For the GPU process we gotten as far as USER_LIMITED. The next level
202 // which is USER_RESTRICTED breaks both the DirectX backend and the OpenGL 202 // which is USER_RESTRICTED breaks both the DirectX backend and the OpenGL
203 // backend. Note that the GPU process is connected to the interactive 203 // backend. Note that the GPU process is connected to the interactive
204 // desktop. 204 // desktop.
205 bool PreSpawnTarget(sandbox::TargetPolicy* policy) override { 205 bool PreSpawnTarget(sandbox::TargetPolicy* policy) override {
206 if (base::win::GetVersion() > base::win::VERSION_XP) { 206 if (base::win::GetVersion() > base::win::VERSION_XP) {
207 if (cmd_line_->GetSwitchValueASCII(switches::kUseGL) == 207 if (cmd_line_->GetSwitchValueASCII(switches::kUseGL) ==
208 gfx::kGLImplementationDesktopName) { 208 gl::kGLImplementationDesktopName) {
209 // Open GL path. 209 // Open GL path.
210 policy->SetTokenLevel(sandbox::USER_RESTRICTED_SAME_ACCESS, 210 policy->SetTokenLevel(sandbox::USER_RESTRICTED_SAME_ACCESS,
211 sandbox::USER_LIMITED); 211 sandbox::USER_LIMITED);
212 SetJobLevel(*cmd_line_, sandbox::JOB_UNPROTECTED, 0, policy); 212 SetJobLevel(*cmd_line_, sandbox::JOB_UNPROTECTED, 0, policy);
213 policy->SetDelayedIntegrityLevel(sandbox::INTEGRITY_LEVEL_LOW); 213 policy->SetDelayedIntegrityLevel(sandbox::INTEGRITY_LEVEL_LOW);
214 } else { 214 } else {
215 policy->SetTokenLevel(sandbox::USER_RESTRICTED_SAME_ACCESS, 215 policy->SetTokenLevel(sandbox::USER_RESTRICTED_SAME_ACCESS,
216 sandbox::USER_LIMITED); 216 sandbox::USER_LIMITED);
217 217
218 // UI restrictions break when we access Windows from outside our job. 218 // UI restrictions break when we access Windows from outside our job.
(...skipping 953 matching lines...) Expand 10 before | Expand all | Expand 10 after
1172 TRACE_EVENT0("gpu", "GpuProcessHost::OnCacheShader"); 1172 TRACE_EVENT0("gpu", "GpuProcessHost::OnCacheShader");
1173 ClientIdToShaderCacheMap::iterator iter = 1173 ClientIdToShaderCacheMap::iterator iter =
1174 client_id_to_shader_cache_.find(client_id); 1174 client_id_to_shader_cache_.find(client_id);
1175 // If the cache doesn't exist then this is an off the record profile. 1175 // If the cache doesn't exist then this is an off the record profile.
1176 if (iter == client_id_to_shader_cache_.end()) 1176 if (iter == client_id_to_shader_cache_.end())
1177 return; 1177 return;
1178 iter->second->Cache(GetShaderPrefixKey() + ":" + key, shader); 1178 iter->second->Cache(GetShaderPrefixKey() + ":" + key, shader);
1179 } 1179 }
1180 1180
1181 } // namespace content 1181 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/gpu/gpu_ipc_browsertests.cc ('k') | content/browser/gpu/gpu_surface_tracker.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698