OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_RESOURCES_PICTURE_PILE_BASE_H_ | 5 #ifndef CC_RESOURCES_PICTURE_PILE_BASE_H_ |
6 #define CC_RESOURCES_PICTURE_PILE_BASE_H_ | 6 #define CC_RESOURCES_PICTURE_PILE_BASE_H_ |
7 | 7 |
8 #include <bitset> | 8 #include <bitset> |
9 #include <list> | 9 #include <list> |
10 #include <utility> | 10 #include <utility> |
(...skipping 11 matching lines...) Expand all Loading... |
22 } | 22 } |
23 | 23 |
24 namespace cc { | 24 namespace cc { |
25 | 25 |
26 class CC_EXPORT PicturePileBase : public base::RefCounted<PicturePileBase> { | 26 class CC_EXPORT PicturePileBase : public base::RefCounted<PicturePileBase> { |
27 public: | 27 public: |
28 PicturePileBase(); | 28 PicturePileBase(); |
29 explicit PicturePileBase(const PicturePileBase* other); | 29 explicit PicturePileBase(const PicturePileBase* other); |
30 PicturePileBase(const PicturePileBase* other, unsigned thread_index); | 30 PicturePileBase(const PicturePileBase* other, unsigned thread_index); |
31 | 31 |
32 void SetTilingRect(const gfx::Rect& tiling_rect); | |
33 gfx::Rect tiling_rect() const { return tiling_.tiling_rect(); } | 32 gfx::Rect tiling_rect() const { return tiling_.tiling_rect(); } |
34 void SetMinContentsScale(float min_contents_scale); | 33 void SetMinContentsScale(float min_contents_scale); |
35 | 34 |
36 // If non-empty, all pictures tiles inside this rect are recorded. There may | 35 // If non-empty, all pictures tiles inside this rect are recorded. There may |
37 // be recordings outside this rect, but everything inside the rect is | 36 // be recordings outside this rect, but everything inside the rect is |
38 // recorded. | 37 // recorded. |
39 gfx::Rect recorded_viewport() const { return recorded_viewport_; } | 38 gfx::Rect recorded_viewport() const { return recorded_viewport_; } |
40 | 39 |
41 int num_tiles_x() const { return tiling_.num_tiles_x(); } | 40 int num_tiles_x() const { return tiling_.num_tiles_x(); } |
42 int num_tiles_y() const { return tiling_.num_tiles_y(); } | 41 int num_tiles_y() const { return tiling_.num_tiles_y(); } |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
119 private: | 118 private: |
120 void SetBufferPixels(int buffer_pixels); | 119 void SetBufferPixels(int buffer_pixels); |
121 | 120 |
122 friend class base::RefCounted<PicturePileBase>; | 121 friend class base::RefCounted<PicturePileBase>; |
123 DISALLOW_COPY_AND_ASSIGN(PicturePileBase); | 122 DISALLOW_COPY_AND_ASSIGN(PicturePileBase); |
124 }; | 123 }; |
125 | 124 |
126 } // namespace cc | 125 } // namespace cc |
127 | 126 |
128 #endif // CC_RESOURCES_PICTURE_PILE_BASE_H_ | 127 #endif // CC_RESOURCES_PICTURE_PILE_BASE_H_ |
OLD | NEW |