OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "base/memory/ptr_util.h" | 5 #include "base/memory/ptr_util.h" |
6 #include "cc/debug/lap_timer.h" | 6 #include "cc/debug/lap_timer.h" |
7 #include "cc/output/compositor_frame.h" | 7 #include "cc/output/compositor_frame.h" |
8 #include "cc/output/delegated_frame_data.h" | 8 #include "cc/output/delegated_frame_data.h" |
9 #include "cc/quads/surface_draw_quad.h" | 9 #include "cc/quads/surface_draw_quad.h" |
10 #include "cc/quads/texture_draw_quad.h" | 10 #include "cc/quads/texture_draw_quad.h" |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 bool premultiplied_alpha = false; | 71 bool premultiplied_alpha = false; |
72 const gfx::PointF uv_top_left; | 72 const gfx::PointF uv_top_left; |
73 const gfx::PointF uv_bottom_right; | 73 const gfx::PointF uv_bottom_right; |
74 SkColor background_color = SK_ColorGREEN; | 74 SkColor background_color = SK_ColorGREEN; |
75 const float vertex_opacity[4] = {0.f, 0.f, 1.f, 1.f}; | 75 const float vertex_opacity[4] = {0.f, 0.f, 1.f, 1.f}; |
76 bool flipped = false; | 76 bool flipped = false; |
77 bool nearest_neighbor = false; | 77 bool nearest_neighbor = false; |
78 quad->SetAll(sqs, rect, opaque_rect, visible_rect, needs_blending, j, | 78 quad->SetAll(sqs, rect, opaque_rect, visible_rect, needs_blending, j, |
79 gfx::Size(), premultiplied_alpha, uv_top_left, | 79 gfx::Size(), premultiplied_alpha, uv_top_left, |
80 uv_bottom_right, background_color, vertex_opacity, flipped, | 80 uv_bottom_right, background_color, vertex_opacity, flipped, |
81 nearest_neighbor); | 81 nearest_neighbor, false); |
82 } | 82 } |
83 sqs = pass->CreateAndAppendSharedQuadState(); | 83 sqs = pass->CreateAndAppendSharedQuadState(); |
84 sqs->opacity = opacity; | 84 sqs->opacity = opacity; |
85 if (i > 1) { | 85 if (i > 1) { |
86 SurfaceDrawQuad* surface_quad = | 86 SurfaceDrawQuad* surface_quad = |
87 pass->CreateAndAppendDrawQuad<SurfaceDrawQuad>(); | 87 pass->CreateAndAppendDrawQuad<SurfaceDrawQuad>(); |
88 surface_quad->SetNew(sqs, gfx::Rect(0, 0, 1, 1), gfx::Rect(0, 0, 1, 1), | 88 surface_quad->SetNew(sqs, gfx::Rect(0, 0, 1, 1), gfx::Rect(0, 0, 1, 1), |
89 SurfaceId(i - 1)); | 89 SurfaceId(i - 1)); |
90 } | 90 } |
91 | 91 |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
168 TEST_F(SurfaceAggregatorPerfTest, FewSurfacesDamageCalc) { | 168 TEST_F(SurfaceAggregatorPerfTest, FewSurfacesDamageCalc) { |
169 RunTest(3, 1000, 1.f, true, true, "few_surfaces_damage_calc"); | 169 RunTest(3, 1000, 1.f, true, true, "few_surfaces_damage_calc"); |
170 } | 170 } |
171 | 171 |
172 TEST_F(SurfaceAggregatorPerfTest, FewSurfacesAggregateDamaged) { | 172 TEST_F(SurfaceAggregatorPerfTest, FewSurfacesAggregateDamaged) { |
173 RunTest(3, 1000, 1.f, true, false, "few_surfaces_aggregate_damaged"); | 173 RunTest(3, 1000, 1.f, true, false, "few_surfaces_aggregate_damaged"); |
174 } | 174 } |
175 | 175 |
176 } // namespace | 176 } // namespace |
177 } // namespace cc | 177 } // namespace cc |
OLD | NEW |