| 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 <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 // PictureLayerTilingClient overrides. | 55 // PictureLayerTilingClient overrides. |
| 56 virtual scoped_refptr<Tile> CreateTile( | 56 virtual scoped_refptr<Tile> CreateTile( |
| 57 PictureLayerTiling* tiling, | 57 PictureLayerTiling* tiling, |
| 58 const gfx::Rect& content_rect) OVERRIDE; | 58 const gfx::Rect& content_rect) OVERRIDE; |
| 59 virtual void UpdatePile(Tile* tile) OVERRIDE; | 59 virtual void UpdatePile(Tile* tile) OVERRIDE; |
| 60 virtual gfx::Size CalculateTileSize( | 60 virtual gfx::Size CalculateTileSize( |
| 61 const gfx::Size& content_bounds) const OVERRIDE; | 61 const gfx::Size& content_bounds) const OVERRIDE; |
| 62 virtual const Region* GetInvalidation() OVERRIDE; | 62 virtual const Region* GetInvalidation() OVERRIDE; |
| 63 virtual const PictureLayerTiling* GetTwinTiling( | 63 virtual const PictureLayerTiling* GetTwinTiling( |
| 64 const PictureLayerTiling* tiling) const OVERRIDE; | 64 const PictureLayerTiling* tiling) const OVERRIDE; |
| 65 virtual size_t GetMaxTilesForInterestArea() const OVERRIDE; |
| 66 virtual float GetSkewportTargetTimeInSeconds() const OVERRIDE; |
| 65 | 67 |
| 66 // PushPropertiesTo active tree => pending tree. | 68 // PushPropertiesTo active tree => pending tree. |
| 67 void SyncTiling(const PictureLayerTiling* tiling); | 69 void SyncTiling(const PictureLayerTiling* tiling); |
| 68 | 70 |
| 69 // Mask-related functions | 71 // Mask-related functions |
| 70 void SetIsMask(bool is_mask); | 72 void SetIsMask(bool is_mask); |
| 71 virtual ResourceProvider::ResourceId ContentsResourceId() const OVERRIDE; | 73 virtual ResourceProvider::ResourceId ContentsResourceId() const OVERRIDE; |
| 72 | 74 |
| 73 virtual size_t GPUMemoryUsageInBytes() const OVERRIDE; | 75 virtual size_t GPUMemoryUsageInBytes() const OVERRIDE; |
| 74 | 76 |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 virtual void GetDebugBorderProperties( | 122 virtual void GetDebugBorderProperties( |
| 121 SkColor* color, float* width) const OVERRIDE; | 123 SkColor* color, float* width) const OVERRIDE; |
| 122 virtual void AsValueInto(base::DictionaryValue* dict) const OVERRIDE; | 124 virtual void AsValueInto(base::DictionaryValue* dict) const OVERRIDE; |
| 123 | 125 |
| 124 PictureLayerImpl* twin_layer_; | 126 PictureLayerImpl* twin_layer_; |
| 125 | 127 |
| 126 scoped_ptr<PictureLayerTilingSet> tilings_; | 128 scoped_ptr<PictureLayerTilingSet> tilings_; |
| 127 scoped_refptr<PicturePileImpl> pile_; | 129 scoped_refptr<PicturePileImpl> pile_; |
| 128 Region invalidation_; | 130 Region invalidation_; |
| 129 | 131 |
| 130 gfx::Transform last_screen_space_transform_; | |
| 131 gfx::Size last_bounds_; | |
| 132 float last_content_scale_; | |
| 133 bool is_mask_; | 132 bool is_mask_; |
| 134 | 133 |
| 135 float ideal_page_scale_; | 134 float ideal_page_scale_; |
| 136 float ideal_device_scale_; | 135 float ideal_device_scale_; |
| 137 float ideal_source_scale_; | 136 float ideal_source_scale_; |
| 138 float ideal_contents_scale_; | 137 float ideal_contents_scale_; |
| 139 | 138 |
| 140 float raster_page_scale_; | 139 float raster_page_scale_; |
| 141 float raster_device_scale_; | 140 float raster_device_scale_; |
| 142 float raster_source_scale_; | 141 float raster_source_scale_; |
| 143 float raster_contents_scale_; | 142 float raster_contents_scale_; |
| 144 float low_res_raster_contents_scale_; | 143 float low_res_raster_contents_scale_; |
| 145 | 144 |
| 146 bool raster_source_scale_was_animating_; | 145 bool raster_source_scale_was_animating_; |
| 147 bool is_using_lcd_text_; | 146 bool is_using_lcd_text_; |
| 148 bool needs_post_commit_initialization_; | 147 bool needs_post_commit_initialization_; |
| 149 // A sanity state check to make sure UpdateTilePriorities only gets called | 148 // A sanity state check to make sure UpdateTilePriorities only gets called |
| 150 // after a CalculateContentsScale/ManageTilings. | 149 // after a CalculateContentsScale/ManageTilings. |
| 151 bool should_update_tile_priorities_; | 150 bool should_update_tile_priorities_; |
| 152 bool should_use_gpu_rasterization_; | 151 bool should_use_gpu_rasterization_; |
| 153 | 152 |
| 154 friend class PictureLayer; | 153 friend class PictureLayer; |
| 155 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl); | 154 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl); |
| 156 }; | 155 }; |
| 157 | 156 |
| 158 } // namespace cc | 157 } // namespace cc |
| 159 | 158 |
| 160 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_ | 159 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_ |
| OLD | NEW |