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

Side by Side Diff: content/renderer/gpu/render_widget_compositor.cc

Issue 1336703002: Revert of Re-land: cc: Use worker context for one-copy tile initialization. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/renderer/gpu/render_widget_compositor.h" 5 #include "content/renderer/gpu/render_widget_compositor.h"
6 6
7 #include <limits> 7 #include <limits>
8 #include <string> 8 #include <string>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after
463 settings.create_low_res_tiling = false; 463 settings.create_low_res_tiling = false;
464 if (cmd->HasSwitch(cc::switches::kEnableBeginFrameScheduling)) 464 if (cmd->HasSwitch(cc::switches::kEnableBeginFrameScheduling))
465 settings.use_external_begin_frame_source = true; 465 settings.use_external_begin_frame_source = true;
466 466
467 if (widget_->for_oopif()) { 467 if (widget_->for_oopif()) {
468 // TODO(simonhong): Apply BeginFrame scheduling for OOPIF. 468 // TODO(simonhong): Apply BeginFrame scheduling for OOPIF.
469 // See crbug.com/471411. 469 // See crbug.com/471411.
470 settings.use_external_begin_frame_source = false; 470 settings.use_external_begin_frame_source = false;
471 } 471 }
472 472
473 settings.max_staging_buffers = 32;
474 // Use 1/4th of staging buffers on low-end devices.
475 if (base::SysInfo::IsLowEndDevice())
476 settings.max_staging_buffers /= 4;
477
478 scoped_refptr<base::SingleThreadTaskRunner> compositor_thread_task_runner = 473 scoped_refptr<base::SingleThreadTaskRunner> compositor_thread_task_runner =
479 compositor_deps_->GetCompositorImplThreadTaskRunner(); 474 compositor_deps_->GetCompositorImplThreadTaskRunner();
480 scoped_refptr<base::SingleThreadTaskRunner> 475 scoped_refptr<base::SingleThreadTaskRunner>
481 main_thread_compositor_task_runner = 476 main_thread_compositor_task_runner =
482 compositor_deps_->GetCompositorMainThreadTaskRunner(); 477 compositor_deps_->GetCompositorMainThreadTaskRunner();
483 cc::SharedBitmapManager* shared_bitmap_manager = 478 cc::SharedBitmapManager* shared_bitmap_manager =
484 compositor_deps_->GetSharedBitmapManager(); 479 compositor_deps_->GetSharedBitmapManager();
485 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager = 480 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager =
486 compositor_deps_->GetGpuMemoryBufferManager(); 481 compositor_deps_->GetGpuMemoryBufferManager();
487 cc::TaskGraphRunner* task_graph_runner = 482 cc::TaskGraphRunner* task_graph_runner =
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after
1050 return; 1045 return;
1051 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); 1046 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM();
1052 } 1047 }
1053 1048
1054 void RenderWidgetCompositor::SetSurfaceIdNamespace( 1049 void RenderWidgetCompositor::SetSurfaceIdNamespace(
1055 uint32_t surface_id_namespace) { 1050 uint32_t surface_id_namespace) {
1056 layer_tree_host_->set_surface_id_namespace(surface_id_namespace); 1051 layer_tree_host_->set_surface_id_namespace(surface_id_namespace);
1057 } 1052 }
1058 1053
1059 } // namespace content 1054 } // namespace content
OLDNEW
« no previous file with comments | « content/common/gpu/client/command_buffer_metrics.cc ('k') | gpu/command_buffer/build_gles2_cmd_buffer.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698