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

Side by Side Diff: cc/trees/layer_tree_host_impl.cc

Issue 13863015: Add flag for drawing layers to screen with Ganesh (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address review comments Created 7 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 "cc/trees/layer_tree_host_impl.h" 5 #include "cc/trees/layer_tree_host_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/json/json_writer.h" 10 #include "base/json/json_writer.h"
(...skipping 1381 matching lines...) Expand 10 before | Expand all | Expand 10 after
1392 UpdateTileManagerMemoryPolicy(managed_memory_policy_); 1392 UpdateTileManagerMemoryPolicy(managed_memory_policy_);
1393 } 1393 }
1394 1394
1395 if (output_surface->capabilities().has_parent_compositor) { 1395 if (output_surface->capabilities().has_parent_compositor) {
1396 renderer_ = DelegatingRenderer::Create(this, output_surface.get(), 1396 renderer_ = DelegatingRenderer::Create(this, output_surface.get(),
1397 resource_provider.get()); 1397 resource_provider.get());
1398 } else if (output_surface->context3d()) { 1398 } else if (output_surface->context3d()) {
1399 renderer_ = GLRenderer::Create(this, 1399 renderer_ = GLRenderer::Create(this,
1400 output_surface.get(), 1400 output_surface.get(),
1401 resource_provider.get(), 1401 resource_provider.get(),
1402 settings_.highp_threshold_min); 1402 settings_.highp_threshold_min,
1403 settings_.force_direct_layer_drawing);
1403 } else if (output_surface->software_device()) { 1404 } else if (output_surface->software_device()) {
1404 renderer_ = SoftwareRenderer::Create(this, 1405 renderer_ = SoftwareRenderer::Create(this,
1405 output_surface.get(), 1406 output_surface.get(),
1406 resource_provider.get()); 1407 resource_provider.get());
1407 } 1408 }
1408 if (!renderer_) 1409 if (!renderer_)
1409 return false; 1410 return false;
1410 1411
1411 resource_provider_ = resource_provider.Pass(); 1412 resource_provider_ = resource_provider.Pass();
1412 output_surface_ = output_surface.Pass(); 1413 output_surface_ = output_surface.Pass();
(...skipping 749 matching lines...) Expand 10 before | Expand all | Expand 10 after
2162 } 2163 }
2163 2164
2164 void LayerTreeHostImpl::SetDebugState(const LayerTreeDebugState& debug_state) { 2165 void LayerTreeHostImpl::SetDebugState(const LayerTreeDebugState& debug_state) {
2165 if (debug_state_.continuous_painting != debug_state.continuous_painting) 2166 if (debug_state_.continuous_painting != debug_state.continuous_painting)
2166 paint_time_counter_->ClearHistory(); 2167 paint_time_counter_->ClearHistory();
2167 2168
2168 debug_state_ = debug_state; 2169 debug_state_ = debug_state;
2169 } 2170 }
2170 2171
2171 } // namespace cc 2172 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698