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 #ifndef CC_OUTPUT_DELEGATING_RENDERER_H_ | 5 #ifndef CC_OUTPUT_DELEGATING_RENDERER_H_ |
6 #define CC_OUTPUT_DELEGATING_RENDERER_H_ | 6 #define CC_OUTPUT_DELEGATING_RENDERER_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "cc/base/cc_export.h" | 11 #include "cc/base/cc_export.h" |
12 #include "cc/output/compositor_frame.h" | 12 #include "cc/output/compositor_frame.h" |
13 | 13 |
14 namespace cc { | 14 namespace cc { |
15 class OutputSurface; | 15 class OutputSurface; |
16 class ResourceProvider; | 16 class ResourceProvider; |
17 | 17 |
18 class CC_EXPORT DelegatingRenderer { | 18 class CC_EXPORT DelegatingRenderer { |
19 public: | 19 public: |
20 DelegatingRenderer(OutputSurface* output_surface, | 20 DelegatingRenderer(OutputSurface* output_surface, |
21 ResourceProvider* resource_provider); | 21 ResourceProvider* resource_provider); |
22 ~DelegatingRenderer(); | 22 ~DelegatingRenderer(); |
23 | 23 |
24 void DrawFrame(RenderPassList* render_passes_in_draw_order); | 24 void DrawFrame(CompositorFrameMetadata metadata, |
25 | 25 RenderPassList render_passes_in_draw_order); |
26 void SwapBuffers(CompositorFrameMetadata metadata); | |
27 | 26 |
28 private: | 27 private: |
29 OutputSurface* const output_surface_; | 28 OutputSurface* const output_surface_; |
30 ResourceProvider* const resource_provider_; | 29 ResourceProvider* const resource_provider_; |
31 std::unique_ptr<DelegatedFrameData> delegated_frame_data_; | |
32 | 30 |
33 DISALLOW_COPY_AND_ASSIGN(DelegatingRenderer); | 31 DISALLOW_COPY_AND_ASSIGN(DelegatingRenderer); |
34 }; | 32 }; |
35 | 33 |
36 } // namespace cc | 34 } // namespace cc |
37 | 35 |
38 #endif // CC_OUTPUT_DELEGATING_RENDERER_H_ | 36 #endif // CC_OUTPUT_DELEGATING_RENDERER_H_ |
OLD | NEW |