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

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

Issue 1236533004: cc: Change max_tiles_for_interest_rect to be screen pixels padding. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 5 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/renderer_host/render_process_host_impl.cc ('k') | no next file » | 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) 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 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
367 *cmd, 367 *cmd,
368 cc::switches::kSlowDownRasterScaleFactor, 368 cc::switches::kSlowDownRasterScaleFactor,
369 kMinSlowDownScaleFactor, 369 kMinSlowDownScaleFactor,
370 kMaxSlowDownScaleFactor, 370 kMaxSlowDownScaleFactor,
371 &settings.initial_debug_state.slow_down_raster_scale_factor); 371 &settings.initial_debug_state.slow_down_raster_scale_factor);
372 } 372 }
373 373
374 settings.invert_viewport_scroll_order = 374 settings.invert_viewport_scroll_order =
375 cmd->HasSwitch(switches::kInvertViewportScrollOrder); 375 cmd->HasSwitch(switches::kInvertViewportScrollOrder);
376 376
377 if (cmd->HasSwitch(cc::switches::kMaxTilesForInterestArea)) {
378 int max_tiles_for_interest_area;
379 if (GetSwitchValueAsInt(*cmd,
380 cc::switches::kMaxTilesForInterestArea,
381 1, std::numeric_limits<int>::max(),
382 &max_tiles_for_interest_area))
383 settings.max_tiles_for_interest_area = max_tiles_for_interest_area;
384 }
385
386 if (cmd->HasSwitch(cc::switches::kMaxUnusedResourceMemoryUsagePercentage)) { 377 if (cmd->HasSwitch(cc::switches::kMaxUnusedResourceMemoryUsagePercentage)) {
387 int max_unused_resource_memory_percentage; 378 int max_unused_resource_memory_percentage;
388 if (GetSwitchValueAsInt( 379 if (GetSwitchValueAsInt(
389 *cmd, 380 *cmd,
390 cc::switches::kMaxUnusedResourceMemoryUsagePercentage, 381 cc::switches::kMaxUnusedResourceMemoryUsagePercentage,
391 0, 100, 382 0, 100,
392 &max_unused_resource_memory_percentage)) { 383 &max_unused_resource_memory_percentage)) {
393 settings.max_unused_resource_memory_percentage = 384 settings.max_unused_resource_memory_percentage =
394 max_unused_resource_memory_percentage; 385 max_unused_resource_memory_percentage;
395 } 386 }
(...skipping 651 matching lines...) Expand 10 before | Expand all | Expand 10 after
1047 return; 1038 return;
1048 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); 1039 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM();
1049 } 1040 }
1050 1041
1051 void RenderWidgetCompositor::SetSurfaceIdNamespace( 1042 void RenderWidgetCompositor::SetSurfaceIdNamespace(
1052 uint32_t surface_id_namespace) { 1043 uint32_t surface_id_namespace) {
1053 layer_tree_host_->set_surface_id_namespace(surface_id_namespace); 1044 layer_tree_host_->set_surface_id_namespace(surface_id_namespace);
1054 } 1045 }
1055 1046
1056 } // namespace content 1047 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/render_process_host_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698