| 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_PICTURE_PILE_H_ | 5 #ifndef CC_PICTURE_PILE_H_ |
| 6 #define CC_PICTURE_PILE_H_ | 6 #define CC_PICTURE_PILE_H_ |
| 7 | 7 |
| 8 #include "cc/picture_pile_base.h" | 8 #include "cc/picture_pile_base.h" |
| 9 #include "ui/gfx/rect.h" | 9 #include "ui/gfx/rect.h" |
| 10 | 10 |
| 11 namespace cc { | 11 namespace cc { |
| 12 class PicturePileImpl; | 12 class PicturePileImpl; |
| 13 class Region; | 13 class Region; |
| 14 struct RenderingStats; | 14 struct RenderingStats; |
| 15 | 15 |
| 16 class CC_EXPORT PicturePile : public PicturePileBase { | 16 class CC_EXPORT PicturePile : public PicturePileBase { |
| 17 public: | 17 public: |
| 18 PicturePile(); | 18 PicturePile(); |
| 19 | 19 |
| 20 // Re-record parts of the picture that are invalid. | 20 // Re-record parts of the picture that are invalid. |
| 21 // Invalidations are in layer space. | 21 // Invalidations are in layer space. |
| 22 void Update( | 22 void Update( |
| 23 ContentLayerClient* painter, | 23 ContentLayerClient* painter, |
| 24 const Region& invalidation, | 24 const Region& invalidation, |
| 25 gfx::Rect visible_layer_rect, | 25 gfx::Rect visible_layer_rect, |
| 26 RenderingStats& stats); | 26 RenderingStats* stats); |
| 27 | 27 |
| 28 // Update other with a shallow copy of this (main => compositor thread commit) | 28 // Update other with a shallow copy of this (main => compositor thread commit) |
| 29 void PushPropertiesTo(PicturePileImpl* other); | 29 void PushPropertiesTo(PicturePileImpl* other); |
| 30 | 30 |
| 31 private: | 31 private: |
| 32 virtual ~PicturePile(); | 32 virtual ~PicturePile(); |
| 33 friend class PicturePileImpl; | 33 friend class PicturePileImpl; |
| 34 | 34 |
| 35 // Add an invalidation to this picture list. If the list needs to be | 35 // Add an invalidation to this picture list. If the list needs to be |
| 36 // entirely recreated, leave it empty. Do not call this on an empty list. | 36 // entirely recreated, leave it empty. Do not call this on an empty list. |
| 37 void InvalidateRect( | 37 void InvalidateRect( |
| 38 PictureList& picture_list, | 38 PictureList& picture_list, |
| 39 gfx::Rect invalidation); | 39 gfx::Rect invalidation); |
| 40 | 40 |
| 41 DISALLOW_COPY_AND_ASSIGN(PicturePile); | 41 DISALLOW_COPY_AND_ASSIGN(PicturePile); |
| 42 }; | 42 }; |
| 43 | 43 |
| 44 } // namespace cc | 44 } // namespace cc |
| 45 | 45 |
| 46 #endif // CC_PICTURE_PILE_H_ | 46 #endif // CC_PICTURE_PILE_H_ |
| OLD | NEW |