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

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

Issue 222903005: cc: Let skia veto gpu rasterization. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: added comment about SetNeedsCommit Created 6 years, 8 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 | « cc/layers/picture_layer.cc ('k') | cc/layers/picture_layer_impl.cc » ('j') | no next file with comments »
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 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 void SyncTiling(const PictureLayerTiling* tiling); 122 void SyncTiling(const PictureLayerTiling* tiling);
123 123
124 // Mask-related functions 124 // Mask-related functions
125 void SetIsMask(bool is_mask); 125 void SetIsMask(bool is_mask);
126 virtual ResourceProvider::ResourceId ContentsResourceId() const OVERRIDE; 126 virtual ResourceProvider::ResourceId ContentsResourceId() const OVERRIDE;
127 127
128 virtual size_t GPUMemoryUsageInBytes() const OVERRIDE; 128 virtual size_t GPUMemoryUsageInBytes() const OVERRIDE;
129 129
130 virtual void RunMicroBenchmark(MicroBenchmarkImpl* benchmark) OVERRIDE; 130 virtual void RunMicroBenchmark(MicroBenchmarkImpl* benchmark) OVERRIDE;
131 131
132 void SetHasGpuRasterizationHint(bool has_hint); 132 void SetUseGpuRasterization(bool use_gpu);
133 bool ShouldUseGpuRasterization() const; 133 bool ShouldUseGpuRasterization() const { return use_gpu_rasterization_; }
134 134
135 // Functions used by tile manager. 135 // Functions used by tile manager.
136 void DidUnregisterLayer(); 136 void DidUnregisterLayer();
137 PictureLayerImpl* GetTwinLayer() { return twin_layer_; } 137 PictureLayerImpl* GetTwinLayer() { return twin_layer_; }
138 WhichTree GetTree() const; 138 WhichTree GetTree() const;
139 bool IsOnActiveOrPendingTree() const; 139 bool IsOnActiveOrPendingTree() const;
140 140
141 protected: 141 protected:
142 friend class LayerRasterTileIterator; 142 friend class LayerRasterTileIterator;
143 143
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 float raster_source_scale_; 201 float raster_source_scale_;
202 float raster_contents_scale_; 202 float raster_contents_scale_;
203 float low_res_raster_contents_scale_; 203 float low_res_raster_contents_scale_;
204 204
205 bool raster_source_scale_was_animating_; 205 bool raster_source_scale_was_animating_;
206 bool is_using_lcd_text_; 206 bool is_using_lcd_text_;
207 bool needs_post_commit_initialization_; 207 bool needs_post_commit_initialization_;
208 // A sanity state check to make sure UpdateTilePriorities only gets called 208 // A sanity state check to make sure UpdateTilePriorities only gets called
209 // after a CalculateContentsScale/ManageTilings. 209 // after a CalculateContentsScale/ManageTilings.
210 bool should_update_tile_priorities_; 210 bool should_update_tile_priorities_;
211 bool has_gpu_rasterization_hint_;
212 bool should_use_low_res_tiling_; 211 bool should_use_low_res_tiling_;
212 bool use_gpu_rasterization_;
213 213
214 bool layer_needs_to_register_itself_; 214 bool layer_needs_to_register_itself_;
215 215
216 friend class PictureLayer; 216 friend class PictureLayer;
217 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl); 217 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl);
218 }; 218 };
219 219
220 } // namespace cc 220 } // namespace cc
221 221
222 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_ 222 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_
OLDNEW
« no previous file with comments | « cc/layers/picture_layer.cc ('k') | cc/layers/picture_layer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698