OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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/render_pass_draw_quad.h" | 5 #include "cc/quads/render_pass_draw_quad.h" |
6 | 6 |
7 #include "base/trace_event/trace_event_argument.h" | 7 #include "base/trace_event/trace_event_argument.h" |
8 #include "base/values.h" | 8 #include "base/values.h" |
9 #include "cc/base/math_util.h" | 9 #include "cc/base/math_util.h" |
10 #include "cc/debug/traced_value.h" | 10 #include "cc/debug/traced_value.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 const gfx::Rect& rect, | 24 const gfx::Rect& rect, |
25 const gfx::Rect& visible_rect, | 25 const gfx::Rect& visible_rect, |
26 RenderPassId render_pass_id, | 26 RenderPassId render_pass_id, |
27 ResourceId mask_resource_id, | 27 ResourceId mask_resource_id, |
28 const gfx::Vector2dF& mask_uv_scale, | 28 const gfx::Vector2dF& mask_uv_scale, |
29 const gfx::Size& mask_texture_size, | 29 const gfx::Size& mask_texture_size, |
30 const FilterOperations& filters, | 30 const FilterOperations& filters, |
31 const gfx::Vector2dF& filters_scale, | 31 const gfx::Vector2dF& filters_scale, |
32 const FilterOperations& background_filters) { | 32 const FilterOperations& background_filters) { |
33 DCHECK_GT(render_pass_id.layer_id, 0); | 33 DCHECK_GT(render_pass_id.layer_id, 0); |
34 DCHECK_GE(render_pass_id.index, 0); | |
35 | 34 |
36 gfx::Rect opaque_rect; | 35 gfx::Rect opaque_rect; |
37 bool needs_blending = false; | 36 bool needs_blending = false; |
38 SetAll(shared_quad_state, | 37 SetAll(shared_quad_state, |
39 rect, | 38 rect, |
40 opaque_rect, | 39 opaque_rect, |
41 visible_rect, | 40 visible_rect, |
42 needs_blending, | 41 needs_blending, |
43 render_pass_id, | 42 render_pass_id, |
44 mask_resource_id, | 43 mask_resource_id, |
(...skipping 10 matching lines...) Expand all Loading... |
55 const gfx::Rect& visible_rect, | 54 const gfx::Rect& visible_rect, |
56 bool needs_blending, | 55 bool needs_blending, |
57 RenderPassId render_pass_id, | 56 RenderPassId render_pass_id, |
58 ResourceId mask_resource_id, | 57 ResourceId mask_resource_id, |
59 const gfx::Vector2dF& mask_uv_scale, | 58 const gfx::Vector2dF& mask_uv_scale, |
60 const gfx::Size& mask_texture_size, | 59 const gfx::Size& mask_texture_size, |
61 const FilterOperations& filters, | 60 const FilterOperations& filters, |
62 const gfx::Vector2dF& filters_scale, | 61 const gfx::Vector2dF& filters_scale, |
63 const FilterOperations& background_filters) { | 62 const FilterOperations& background_filters) { |
64 DCHECK_GT(render_pass_id.layer_id, 0); | 63 DCHECK_GT(render_pass_id.layer_id, 0); |
65 DCHECK_GE(render_pass_id.index, 0); | |
66 | 64 |
67 DrawQuad::SetAll(shared_quad_state, DrawQuad::RENDER_PASS, rect, opaque_rect, | 65 DrawQuad::SetAll(shared_quad_state, DrawQuad::RENDER_PASS, rect, opaque_rect, |
68 visible_rect, needs_blending); | 66 visible_rect, needs_blending); |
69 this->render_pass_id = render_pass_id; | 67 this->render_pass_id = render_pass_id; |
70 this->mask_resource_id = mask_resource_id; | 68 this->mask_resource_id = mask_resource_id; |
71 this->mask_uv_scale = mask_uv_scale; | 69 this->mask_uv_scale = mask_uv_scale; |
72 this->mask_texture_size = mask_texture_size; | 70 this->mask_texture_size = mask_texture_size; |
73 this->filters = filters; | 71 this->filters = filters; |
74 this->filters_scale = filters_scale; | 72 this->filters_scale = filters_scale; |
75 this->background_filters = background_filters; | 73 this->background_filters = background_filters; |
(...skipping 30 matching lines...) Expand all Loading... |
106 filters.AsValueInto(value); | 104 filters.AsValueInto(value); |
107 value->EndDictionary(); | 105 value->EndDictionary(); |
108 MathUtil::AddToTracedValue("filters_scale", filters_scale, value); | 106 MathUtil::AddToTracedValue("filters_scale", filters_scale, value); |
109 | 107 |
110 value->BeginDictionary("background_filters"); | 108 value->BeginDictionary("background_filters"); |
111 background_filters.AsValueInto(value); | 109 background_filters.AsValueInto(value); |
112 value->EndDictionary(); | 110 value->EndDictionary(); |
113 } | 111 } |
114 | 112 |
115 } // namespace cc | 113 } // namespace cc |
OLD | NEW |