| 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_IMPL_H_ | 5 #ifndef CC_PICTURE_PILE_IMPL_H_ |
| 6 #define CC_PICTURE_PILE_IMPL_H_ | 6 #define CC_PICTURE_PILE_IMPL_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "cc/cc_export.h" | 10 #include "cc/cc_export.h" |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 static scoped_refptr<PicturePileImpl> Create(); | 21 static scoped_refptr<PicturePileImpl> Create(); |
| 22 | 22 |
| 23 // Clone a paint-safe version of this picture. | 23 // Clone a paint-safe version of this picture. |
| 24 scoped_refptr<PicturePileImpl> CloneForDrawing() const; | 24 scoped_refptr<PicturePileImpl> CloneForDrawing() const; |
| 25 | 25 |
| 26 // Raster a subrect of this PicturePileImpl into the given canvas. | 26 // Raster a subrect of this PicturePileImpl into the given canvas. |
| 27 // It's only safe to call paint on a cloned version. | 27 // It's only safe to call paint on a cloned version. |
| 28 // It is assumed that contentsScale has already been applied to this canvas. | 28 // It is assumed that contentsScale has already been applied to this canvas. |
| 29 void Raster(SkCanvas* canvas, gfx::Rect rect, RenderingStats* stats); | 29 void Raster(SkCanvas* canvas, gfx::Rect rect, RenderingStats* stats); |
| 30 | 30 |
| 31 std::vector<SkPixelRef*> GatherPixelRefs(const gfx::Rect& rect); |
| 32 |
| 31 private: | 33 private: |
| 32 friend class PicturePile; | 34 friend class PicturePile; |
| 33 | 35 |
| 34 PicturePileImpl(); | 36 PicturePileImpl(); |
| 35 ~PicturePileImpl(); | 37 ~PicturePileImpl(); |
| 36 | 38 |
| 37 PicturePile::Pile pile_; | 39 PicturePile::Pile pile_; |
| 38 | 40 |
| 39 friend class base::RefCounted<PicturePileImpl>; | 41 friend class base::RefCounted<PicturePileImpl>; |
| 40 DISALLOW_COPY_AND_ASSIGN(PicturePileImpl); | 42 DISALLOW_COPY_AND_ASSIGN(PicturePileImpl); |
| 41 }; | 43 }; |
| 42 | 44 |
| 43 } // namespace cc | 45 } // namespace cc |
| 44 | 46 |
| 45 #endif // CC_PICTURE_PILE_IMPL_H_ | 47 #endif // CC_PICTURE_PILE_IMPL_H_ |
| OLD | NEW |