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 "cc/output/compositor_frame.h" | 5 #include "cc/output/compositor_frame.h" |
6 #include "cc/output/delegated_frame_data.h" | 6 #include "cc/output/delegated_frame_data.h" |
7 #include "cc/quads/render_pass.h" | 7 #include "cc/quads/render_pass.h" |
8 #include "cc/quads/render_pass_draw_quad.h" | 8 #include "cc/quads/render_pass_draw_quad.h" |
9 #include "cc/quads/render_pass_id.h" | 9 #include "cc/quads/render_pass_id.h" |
10 #include "cc/quads/solid_color_draw_quad.h" | 10 #include "cc/quads/solid_color_draw_quad.h" |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 EXPECT_TRUE(hittest.GetTransformToTargetSurface( | 48 EXPECT_TRUE(hittest.GetTransformToTargetSurface( |
49 test.input_surface_id, test.expected_output_surface_id, | 49 test.input_surface_id, test.expected_output_surface_id, |
50 &target_transform)); | 50 &target_transform)); |
51 EXPECT_EQ(transform, target_transform); | 51 EXPECT_EQ(transform, target_transform); |
52 } | 52 } |
53 } | 53 } |
54 | 54 |
55 class EmptySurfaceFactoryClient : public SurfaceFactoryClient { | 55 class EmptySurfaceFactoryClient : public SurfaceFactoryClient { |
56 public: | 56 public: |
57 void ReturnResources(const ReturnedResourceArray& resources) override {} | 57 void ReturnResources(const ReturnedResourceArray& resources) override {} |
| 58 void SetBeginFrameSource(SurfaceId surface_id, |
| 59 BeginFrameSource* begin_frame_source) override {} |
58 }; | 60 }; |
59 | 61 |
60 void CreateSharedQuadState(RenderPass* pass, | 62 void CreateSharedQuadState(RenderPass* pass, |
61 const gfx::Transform& transform, | 63 const gfx::Transform& transform, |
62 const gfx::Rect& root_rect) { | 64 const gfx::Rect& root_rect) { |
63 SharedQuadState* child_shared_state = | 65 SharedQuadState* child_shared_state = |
64 pass->CreateAndAppendSharedQuadState(); | 66 pass->CreateAndAppendSharedQuadState(); |
65 child_shared_state->SetAll(transform, | 67 child_shared_state->SetAll(transform, |
66 root_rect.size(), | 68 root_rect.size(), |
67 root_rect, root_rect, false, 1.0f, | 69 root_rect, root_rect, false, 1.0f, |
(...skipping 486 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
554 gfx::Point(100, 100) | 556 gfx::Point(100, 100) |
555 } | 557 } |
556 }; | 558 }; |
557 | 559 |
558 RunTests(&manager, tests, sizeof(tests) / sizeof(*tests)); | 560 RunTests(&manager, tests, sizeof(tests) / sizeof(*tests)); |
559 | 561 |
560 factory.Destroy(root_surface_id); | 562 factory.Destroy(root_surface_id); |
561 } | 563 } |
562 | 564 |
563 } // namespace cc | 565 } // namespace cc |
OLD | NEW |