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_QUADS_DRAW_QUAD_H_ | 5 #ifndef CC_QUADS_DRAW_QUAD_H_ |
6 #define CC_QUADS_DRAW_QUAD_H_ | 6 #define CC_QUADS_DRAW_QUAD_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "cc/base/cc_export.h" | 9 #include "cc/base/cc_export.h" |
10 #include "cc/base/resource_id.h" | 10 #include "cc/base/resource_id.h" |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
118 Resources(); | 118 Resources(); |
119 | 119 |
120 ResourceId* begin() { return ids; } | 120 ResourceId* begin() { return ids; } |
121 ResourceId* end() { | 121 ResourceId* end() { |
122 DCHECK_LE(count, kMaxResourceIdCount); | 122 DCHECK_LE(count, kMaxResourceIdCount); |
123 return ids + count; | 123 return ids + count; |
124 } | 124 } |
125 | 125 |
126 size_t count; | 126 size_t count; |
127 ResourceId ids[kMaxResourceIdCount]; | 127 ResourceId ids[kMaxResourceIdCount]; |
128 gfx::Size size_in_pixels[kMaxResourceIdCount]; | |
danakj
2015/06/05 18:13:26
I don't think we should put this on every quad whe
achaulk
2015/06/05 18:14:31
Ok
| |
129 bool allow_overlay[kMaxResourceIdCount]; | |
128 }; | 130 }; |
129 | 131 |
130 Resources resources; | 132 Resources resources; |
131 | 133 |
132 protected: | 134 protected: |
133 DrawQuad(); | 135 DrawQuad(); |
134 | 136 |
135 void SetAll(const SharedQuadState* shared_quad_state, | 137 void SetAll(const SharedQuadState* shared_quad_state, |
136 Material material, | 138 Material material, |
137 const gfx::Rect& rect, | 139 const gfx::Rect& rect, |
138 const gfx::Rect& opaque_rect, | 140 const gfx::Rect& opaque_rect, |
139 const gfx::Rect& visible_rect, | 141 const gfx::Rect& visible_rect, |
140 bool needs_blending); | 142 bool needs_blending); |
141 virtual void ExtendValue(base::trace_event::TracedValue* value) const = 0; | 143 virtual void ExtendValue(base::trace_event::TracedValue* value) const = 0; |
142 }; | 144 }; |
143 | 145 |
144 } // namespace cc | 146 } // namespace cc |
145 | 147 |
146 #endif // CC_QUADS_DRAW_QUAD_H_ | 148 #endif // CC_QUADS_DRAW_QUAD_H_ |
OLD | NEW |