| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/surfaces/surface_aggregator_test_helpers.h" | 5 #include "cc/surfaces/surface_aggregator_test_helpers.h" |
| 6 | 6 |
| 7 #include "base/format_macros.h" | 7 #include "base/format_macros.h" |
| 8 #include "base/strings/stringprintf.h" | 8 #include "base/strings/stringprintf.h" |
| 9 #include "cc/layers/append_quads_data.h" | 9 #include "cc/layers/append_quads_data.h" |
| 10 #include "cc/output/compositor_frame.h" | 10 #include "cc/output/compositor_frame.h" |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 1, | 62 1, |
| 63 SkXfermode::kSrcOver_Mode, | 63 SkXfermode::kSrcOver_Mode, |
| 64 0); | 64 0); |
| 65 RenderPassDrawQuad* quad = | 65 RenderPassDrawQuad* quad = |
| 66 pass->CreateAndAppendDrawQuad<RenderPassDrawQuad>(); | 66 pass->CreateAndAppendDrawQuad<RenderPassDrawQuad>(); |
| 67 quad->SetNew(shared_state, | 67 quad->SetNew(shared_state, |
| 68 output_rect, | 68 output_rect, |
| 69 output_rect, | 69 output_rect, |
| 70 render_pass_id, | 70 render_pass_id, |
| 71 0, | 71 0, |
| 72 gfx::RectF(), | 72 gfx::Vector2dF(), |
| 73 gfx::Size(), |
| 73 FilterOperations(), | 74 FilterOperations(), |
| 74 gfx::Vector2dF(), | 75 gfx::Vector2dF(), |
| 75 FilterOperations()); | 76 FilterOperations()); |
| 76 } | 77 } |
| 77 | 78 |
| 78 void AddQuadInPass(TestRenderPass* pass, Quad desc) { | 79 void AddQuadInPass(TestRenderPass* pass, Quad desc) { |
| 79 switch (desc.material) { | 80 switch (desc.material) { |
| 80 case DrawQuad::SOLID_COLOR: | 81 case DrawQuad::SOLID_COLOR: |
| 81 AddQuad(pass, gfx::Rect(0, 0, 5, 5), desc.color); | 82 AddQuad(pass, gfx::Rect(0, 0, 5, 5), desc.color); |
| 82 break; | 83 break; |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 148 | 149 |
| 149 for (size_t i = 0; i < passes->size(); ++i) { | 150 for (size_t i = 0; i < passes->size(); ++i) { |
| 150 SCOPED_TRACE(base::StringPrintf("Pass number %" PRIuS, i)); | 151 SCOPED_TRACE(base::StringPrintf("Pass number %" PRIuS, i)); |
| 151 RenderPass* pass = passes->at(i); | 152 RenderPass* pass = passes->at(i); |
| 152 TestPassMatchesExpectations(expected_passes[i], pass); | 153 TestPassMatchesExpectations(expected_passes[i], pass); |
| 153 } | 154 } |
| 154 } | 155 } |
| 155 | 156 |
| 156 } // namespace test | 157 } // namespace test |
| 157 } // namespace cc | 158 } // namespace cc |
| OLD | NEW |