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

Side by Side Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 1139903005: Add PERSISTENT_MAP usage for GpuMemoryBuffers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: persistentmap: . Created 5 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
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 // Represents the browser side of the browser <--> renderer communication 5 // Represents the browser side of the browser <--> renderer communication
6 // channel. There will be one RenderProcessHost per renderer process. 6 // channel. There will be one RenderProcessHost per renderer process.
7 7
8 #include "content/browser/renderer_host/render_process_host_impl.h" 8 #include "content/browser/renderer_host/render_process_host_impl.h"
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 1120 matching lines...) Expand 10 before | Expand all | Expand 10 after
1131 DCHECK_IMPLIES(IsOneCopyUploadEnabled(), !IsZeroCopyUploadEnabled()); 1131 DCHECK_IMPLIES(IsOneCopyUploadEnabled(), !IsZeroCopyUploadEnabled());
1132 if (IsZeroCopyUploadEnabled()) 1132 if (IsZeroCopyUploadEnabled())
1133 command_line->AppendSwitch(switches::kEnableZeroCopy); 1133 command_line->AppendSwitch(switches::kEnableZeroCopy);
1134 if (!IsOneCopyUploadEnabled()) 1134 if (!IsOneCopyUploadEnabled())
1135 command_line->AppendSwitch(switches::kDisableOneCopy); 1135 command_line->AppendSwitch(switches::kDisableOneCopy);
1136 1136
1137 if (IsForceGpuRasterizationEnabled()) 1137 if (IsForceGpuRasterizationEnabled())
1138 command_line->AppendSwitch(switches::kForceGpuRasterization); 1138 command_line->AppendSwitch(switches::kForceGpuRasterization);
1139 1139
1140 command_line->AppendSwitchASCII( 1140 command_line->AppendSwitchASCII(
1141 switches::kUseImageTextureTarget, 1141 switches::kMapImageTextureTarget,
1142 base::UintToString( 1142 base::UintToString(BrowserGpuChannelHostFactory::GetImageTextureTarget(
1143 BrowserGpuChannelHostFactory::GetImageTextureTarget())); 1143 gfx::GpuMemoryBuffer::MAP)));
1144 command_line->AppendSwitchASCII(
1145 switches::kPersistentMapImageTextureTarget,
1146 base::UintToString(BrowserGpuChannelHostFactory::GetImageTextureTarget(
1147 gfx::GpuMemoryBuffer::PERSISTENT_MAP)));
1144 1148
1145 // Appending disable-gpu-feature switches due to software rendering list. 1149 // Appending disable-gpu-feature switches due to software rendering list.
1146 GpuDataManagerImpl* gpu_data_manager = GpuDataManagerImpl::GetInstance(); 1150 GpuDataManagerImpl* gpu_data_manager = GpuDataManagerImpl::GetInstance();
1147 DCHECK(gpu_data_manager); 1151 DCHECK(gpu_data_manager);
1148 gpu_data_manager->AppendRendererCommandLine(command_line); 1152 gpu_data_manager->AppendRendererCommandLine(command_line);
1149 } 1153 }
1150 1154
1151 void RenderProcessHostImpl::AppendRendererCommandLine( 1155 void RenderProcessHostImpl::AppendRendererCommandLine(
1152 base::CommandLine* command_line) const { 1156 base::CommandLine* command_line) const {
1153 // Pass the process type first, so it shows first in process listings. 1157 // Pass the process type first, so it shows first in process listings.
(...skipping 1304 matching lines...) Expand 10 before | Expand all | Expand 10 after
2458 if (worker_ref_count_ == 0) 2462 if (worker_ref_count_ == 0)
2459 Cleanup(); 2463 Cleanup();
2460 } 2464 }
2461 2465
2462 void RenderProcessHostImpl::GetAudioOutputControllers( 2466 void RenderProcessHostImpl::GetAudioOutputControllers(
2463 const GetAudioOutputControllersCallback& callback) const { 2467 const GetAudioOutputControllersCallback& callback) const {
2464 audio_renderer_host()->GetOutputControllers(callback); 2468 audio_renderer_host()->GetOutputControllers(callback);
2465 } 2469 }
2466 2470
2467 } // namespace content 2471 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698