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

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

Issue 21159007: cc: Adding support for RGBA_4444 tile textures (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Code review comments Created 7 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 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/containers/hash_tables.h" 10 #include "base/containers/hash_tables.h"
(...skipping 1611 matching lines...) Expand 10 before | Expand all | Expand 10 after
1622 // Note: order is important here. 1622 // Note: order is important here.
1623 renderer_.reset(); 1623 renderer_.reset();
1624 tile_manager_.reset(); 1624 tile_manager_.reset();
1625 resource_provider_.reset(); 1625 resource_provider_.reset();
1626 output_surface_.reset(); 1626 output_surface_.reset();
1627 1627
1628 if (!output_surface->BindToClient(this)) 1628 if (!output_surface->BindToClient(this))
1629 return false; 1629 return false;
1630 1630
1631 scoped_ptr<ResourceProvider> resource_provider = ResourceProvider::Create( 1631 scoped_ptr<ResourceProvider> resource_provider = ResourceProvider::Create(
1632 output_surface.get(), settings_.highp_threshold_min); 1632 output_surface.get(),
1633 settings_.highp_threshold_min,
1634 settings_.use_rgba_4444_textures);
1633 if (!resource_provider) 1635 if (!resource_provider)
1634 return false; 1636 return false;
1635 1637
1636 if (output_surface->capabilities().deferred_gl_initialization) 1638 if (output_surface->capabilities().deferred_gl_initialization)
1637 EnforceZeroBudget(true); 1639 EnforceZeroBudget(true);
1638 1640
1639 bool skip_gl_renderer = false; 1641 bool skip_gl_renderer = false;
1640 CreateAndSetRenderer( 1642 CreateAndSetRenderer(
1641 output_surface.get(), resource_provider.get(), skip_gl_renderer); 1643 output_surface.get(), resource_provider.get(), skip_gl_renderer);
1642 1644
(...skipping 934 matching lines...) Expand 10 before | Expand all | Expand 10 after
2577 2579
2578 ResourceProvider::ResourceId LayerTreeHostImpl::ResourceIdForUIResource( 2580 ResourceProvider::ResourceId LayerTreeHostImpl::ResourceIdForUIResource(
2579 UIResourceId uid) const { 2581 UIResourceId uid) const {
2580 UIResourceMap::const_iterator iter = ui_resource_map_.find(uid); 2582 UIResourceMap::const_iterator iter = ui_resource_map_.find(uid);
2581 if (iter != ui_resource_map_.end()) 2583 if (iter != ui_resource_map_.end())
2582 return iter->second; 2584 return iter->second;
2583 return 0; 2585 return 0;
2584 } 2586 }
2585 2587
2586 } // namespace cc 2588 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698