OLD | NEW |
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 <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
147 float raster_contents_scale_; | 147 float raster_contents_scale_; |
148 float low_res_raster_contents_scale_; | 148 float low_res_raster_contents_scale_; |
149 | 149 |
150 bool was_screen_space_transform_animating_; | 150 bool was_screen_space_transform_animating_; |
151 bool only_used_low_res_last_append_quads_; | 151 bool only_used_low_res_last_append_quads_; |
152 const bool is_mask_; | 152 const bool is_mask_; |
153 | 153 |
154 bool nearest_neighbor_; | 154 bool nearest_neighbor_; |
155 | 155 |
156 // Any draw properties derived from |transform|, |viewport|, and |clip| | 156 // Any draw properties derived from |transform|, |viewport|, and |clip| |
157 // parameters in LayerTreeHostImpl::SetExternalDrawConstraints are not valid | 157 // parameters in LayerTreeHostImpl::OnDraw are not valid for prioritizing |
158 // for prioritizing tiles during resourceless software draws. This is because | 158 // tiles during resourceless software draws. This is because resourceless |
159 // resourceless software draws can have wildly different transforms/viewports | 159 // software draws can have wildly different transforms/viewports from regular |
160 // from regular draws. Save a copy of the required draw properties of the last | 160 // draws. Save a copy of the required draw properties of the last frame that |
161 // frame that has a valid viewport for prioritizing tiles. | 161 // has a valid viewport for prioritizing tiles. |
162 gfx::Rect visible_rect_for_tile_priority_; | 162 gfx::Rect visible_rect_for_tile_priority_; |
163 gfx::Rect viewport_rect_for_tile_priority_in_content_space_; | 163 gfx::Rect viewport_rect_for_tile_priority_in_content_space_; |
164 gfx::Transform screen_space_transform_for_tile_priority_; | 164 gfx::Transform screen_space_transform_for_tile_priority_; |
165 | 165 |
166 gfx::Size gpu_raster_max_texture_size_; | 166 gfx::Size gpu_raster_max_texture_size_; |
167 | 167 |
168 // List of tilings that were used last time we appended quads. This can be | 168 // List of tilings that were used last time we appended quads. This can be |
169 // used as an optimization not to remove tilings if they are still being | 169 // used as an optimization not to remove tilings if they are still being |
170 // drawn. Note that accessing this vector should only be done in the context | 170 // drawn. Note that accessing this vector should only be done in the context |
171 // of comparing pointers, since objects pointed to are not guaranteed to | 171 // of comparing pointers, since objects pointed to are not guaranteed to |
172 // exist. | 172 // exist. |
173 std::vector<PictureLayerTiling*> last_append_quads_tilings_; | 173 std::vector<PictureLayerTiling*> last_append_quads_tilings_; |
174 | 174 |
175 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl); | 175 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl); |
176 }; | 176 }; |
177 | 177 |
178 } // namespace cc | 178 } // namespace cc |
179 | 179 |
180 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_ | 180 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_ |
OLD | NEW |