OLD | NEW |
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 #ifndef CC_LAYERS_LAYER_IMPL_H_ | 5 #ifndef CC_LAYERS_LAYER_IMPL_H_ |
6 #define CC_LAYERS_LAYER_IMPL_H_ | 6 #define CC_LAYERS_LAYER_IMPL_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
201 virtual void DidDraw(ResourceProvider* resource_provider); | 201 virtual void DidDraw(ResourceProvider* resource_provider); |
202 | 202 |
203 virtual void GetContentsResourceId(ResourceProvider::ResourceId* resource_id, | 203 virtual void GetContentsResourceId(ResourceProvider::ResourceId* resource_id, |
204 gfx::Size* resource_size) const; | 204 gfx::Size* resource_size) const; |
205 | 205 |
206 virtual bool HasDelegatedContent() const; | 206 virtual bool HasDelegatedContent() const; |
207 virtual bool HasContributingDelegatedRenderPasses() const; | 207 virtual bool HasContributingDelegatedRenderPasses() const; |
208 virtual RenderPassId FirstContributingRenderPassId() const; | 208 virtual RenderPassId FirstContributingRenderPassId() const; |
209 virtual RenderPassId NextContributingRenderPassId(RenderPassId id) const; | 209 virtual RenderPassId NextContributingRenderPassId(RenderPassId id) const; |
210 | 210 |
211 virtual void UpdateTiles(const Occlusion& occlusion_in_layer_space, | 211 // Updates the layer's tiles. This should return true if meaningful work was |
212 bool resourceless_software_draw) {} | 212 // done. That is, if an early-out was hit and as a result the internal state |
| 213 // of tiles didn't change, this function should return false. |
| 214 virtual bool UpdateTiles(const Occlusion& occlusion_in_layer_space, |
| 215 bool resourceless_software_draw); |
213 virtual void NotifyTileStateChanged(const Tile* tile) {} | 216 virtual void NotifyTileStateChanged(const Tile* tile) {} |
214 | 217 |
215 virtual ScrollbarLayerImplBase* ToScrollbarLayer(); | 218 virtual ScrollbarLayerImplBase* ToScrollbarLayer(); |
216 | 219 |
217 // Returns true if this layer has content to draw. | 220 // Returns true if this layer has content to draw. |
218 void SetDrawsContent(bool draws_content); | 221 void SetDrawsContent(bool draws_content); |
219 bool DrawsContent() const { return draws_content_; } | 222 bool DrawsContent() const { return draws_content_; } |
220 | 223 |
221 int NumDescendantsThatDrawContent() const; | 224 int NumDescendantsThatDrawContent() const; |
222 void SetHideLayerAndSubtree(bool hide); | 225 void SetHideLayerAndSubtree(bool hide); |
(...skipping 493 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
716 DrawProperties<LayerImpl> draw_properties_; | 719 DrawProperties<LayerImpl> draw_properties_; |
717 | 720 |
718 scoped_refptr<base::debug::ConvertableToTraceFormat> debug_info_; | 721 scoped_refptr<base::debug::ConvertableToTraceFormat> debug_info_; |
719 scoped_ptr<RenderSurfaceImpl> render_surface_; | 722 scoped_ptr<RenderSurfaceImpl> render_surface_; |
720 DISALLOW_COPY_AND_ASSIGN(LayerImpl); | 723 DISALLOW_COPY_AND_ASSIGN(LayerImpl); |
721 }; | 724 }; |
722 | 725 |
723 } // namespace cc | 726 } // namespace cc |
724 | 727 |
725 #endif // CC_LAYERS_LAYER_IMPL_H_ | 728 #endif // CC_LAYERS_LAYER_IMPL_H_ |
OLD | NEW |