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

Side by Side Diff: cc/layers/picture_layer_impl.h

Issue 132083007: cc: don't add low-res tiling to GPU rasterized layers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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
« no previous file with comments | « no previous file | cc/layers/picture_layer_impl.cc » ('j') | cc/layers/picture_layer_impl.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 #ifndef CC_LAYERS_PICTURE_LAYER_IMPL_H_ 5 #ifndef CC_LAYERS_PICTURE_LAYER_IMPL_H_
6 #define CC_LAYERS_PICTURE_LAYER_IMPL_H_ 6 #define CC_LAYERS_PICTURE_LAYER_IMPL_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 return should_use_gpu_rasterization_; 78 return should_use_gpu_rasterization_;
79 } 79 }
80 80
81 protected: 81 protected:
82 PictureLayerImpl(LayerTreeImpl* tree_impl, int id); 82 PictureLayerImpl(LayerTreeImpl* tree_impl, int id);
83 PictureLayerTiling* AddTiling(float contents_scale); 83 PictureLayerTiling* AddTiling(float contents_scale);
84 void RemoveTiling(float contents_scale); 84 void RemoveTiling(float contents_scale);
85 void RemoveAllTilings(); 85 void RemoveAllTilings();
86 void SyncFromActiveLayer(const PictureLayerImpl* other); 86 void SyncFromActiveLayer(const PictureLayerImpl* other);
87 void ManageTilings(bool animating_transform_to_screen); 87 void ManageTilings(bool animating_transform_to_screen);
88 bool ShouldHaveLowResTiling() const {
89 return !should_use_gpu_rasterization();
90 }
88 virtual bool ShouldAdjustRasterScale( 91 virtual bool ShouldAdjustRasterScale(
89 bool animating_transform_to_screen) const; 92 bool animating_transform_to_screen) const;
90 virtual void RecalculateRasterScales( 93 virtual void RecalculateRasterScales(
91 bool animating_transform_to_screen); 94 bool animating_transform_to_screen);
92 void CleanUpTilingsOnActiveLayer( 95 void CleanUpTilingsOnActiveLayer(
93 std::vector<PictureLayerTiling*> used_tilings); 96 std::vector<PictureLayerTiling*> used_tilings);
94 float MinimumContentsScale() const; 97 float MinimumContentsScale() const;
95 float SnappedContentsScale(float new_contents_scale); 98 float SnappedContentsScale(float new_contents_scale);
96 void UpdateLCDTextStatus(bool new_status); 99 void UpdateLCDTextStatus(bool new_status);
97 void ResetRasterScale(); 100 void ResetRasterScale();
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 bool should_update_tile_priorities_; 150 bool should_update_tile_priorities_;
148 bool should_use_gpu_rasterization_; 151 bool should_use_gpu_rasterization_;
149 152
150 friend class PictureLayer; 153 friend class PictureLayer;
151 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl); 154 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl);
152 }; 155 };
153 156
154 } // namespace cc 157 } // namespace cc
155 158
156 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_ 159 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_
OLDNEW
« no previous file with comments | « no previous file | cc/layers/picture_layer_impl.cc » ('j') | cc/layers/picture_layer_impl.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698