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 #include "cc/quads/checkerboard_draw_quad.h" | 5 #include "cc/quads/checkerboard_draw_quad.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "base/trace_event/trace_event_argument.h" | 8 #include "base/trace_event/trace_event_argument.h" |
9 #include "base/values.h" | 9 #include "base/values.h" |
10 | 10 |
(...skipping 21 matching lines...) Expand all Loading... |
32 const gfx::Rect& visible_rect, | 32 const gfx::Rect& visible_rect, |
33 bool needs_blending, | 33 bool needs_blending, |
34 SkColor color, | 34 SkColor color, |
35 float scale) { | 35 float scale) { |
36 DrawQuad::SetAll(shared_quad_state, DrawQuad::CHECKERBOARD, rect, opaque_rect, | 36 DrawQuad::SetAll(shared_quad_state, DrawQuad::CHECKERBOARD, rect, opaque_rect, |
37 visible_rect, needs_blending); | 37 visible_rect, needs_blending); |
38 this->color = color; | 38 this->color = color; |
39 this->scale = scale; | 39 this->scale = scale; |
40 } | 40 } |
41 | 41 |
42 void CheckerboardDrawQuad::IterateResources( | |
43 const ResourceIteratorCallback& callback) {} | |
44 | |
45 const CheckerboardDrawQuad* CheckerboardDrawQuad::MaterialCast( | 42 const CheckerboardDrawQuad* CheckerboardDrawQuad::MaterialCast( |
46 const DrawQuad* quad) { | 43 const DrawQuad* quad) { |
47 DCHECK(quad->material == DrawQuad::CHECKERBOARD); | 44 DCHECK(quad->material == DrawQuad::CHECKERBOARD); |
48 return static_cast<const CheckerboardDrawQuad*>(quad); | 45 return static_cast<const CheckerboardDrawQuad*>(quad); |
49 } | 46 } |
50 | 47 |
51 void CheckerboardDrawQuad::ExtendValue( | 48 void CheckerboardDrawQuad::ExtendValue( |
52 base::trace_event::TracedValue* value) const { | 49 base::trace_event::TracedValue* value) const { |
53 value->SetInteger("color", color); | 50 value->SetInteger("color", color); |
54 value->SetDouble("scale", scale); | 51 value->SetDouble("scale", scale); |
55 } | 52 } |
56 | 53 |
57 } // namespace cc | 54 } // namespace cc |
OLD | NEW |