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 #ifndef CC_TREES_CHANNEL_MAIN_H_ | 5 #ifndef CC_TREES_CHANNEL_MAIN_H_ |
6 #define CC_TREES_CHANNEL_MAIN_H_ | 6 #define CC_TREES_CHANNEL_MAIN_H_ |
7 | 7 |
8 #include "cc/base/cc_export.h" | 8 #include "cc/base/cc_export.h" |
| 9 #include "cc/output/output_surface.h" |
9 | 10 |
10 namespace cc { | 11 namespace cc { |
11 | |
12 // ChannelMain and ChannelImpl provide an abstract communication layer for | 12 // ChannelMain and ChannelImpl provide an abstract communication layer for |
13 // the main and impl side of the compositor. | 13 // the main and impl side of the compositor. |
14 // | 14 // |
15 // The communication sequence between the 2 sides is: | 15 // The communication sequence between the 2 sides is: |
16 // | 16 // |
17 // LayerTreeHost<-->ProxyMain<-->ChannelMain | 17 // LayerTreeHost<-->ProxyMain<-->ChannelMain |
18 // | | 18 // | |
19 // | | 19 // | |
20 // ChannelImpl<-->ProxyImpl<-->LayerTreeHostImpl | 20 // ChannelImpl<-->ProxyImpl<-->LayerTreeHostImpl |
21 | 21 |
22 class CC_EXPORT ChannelMain { | 22 class CC_EXPORT ChannelMain { |
23 public: | 23 public: |
24 // Interface for commands sent to the ProxyImpl | 24 // Interface for commands sent to the ProxyImpl |
25 virtual void SetThrottleFrameProductionOnImpl(bool throttle) = 0; | 25 virtual void SetThrottleFrameProductionOnImpl(bool throttle) = 0; |
| 26 virtual void InitializeOutputSurfaceOnImpl(OutputSurface* output_surface) = 0; |
| 27 virtual void MainThreadHasStoppedFlingingOnImpl() = 0; |
| 28 virtual void SetInputThrottledUntilCommitOnImpl(bool is_throttled) = 0; |
| 29 virtual void SetDeferCommitsOnImpl(bool defer_commits) = 0; |
| 30 virtual void FinishAllRenderingOnImpl() = 0; |
| 31 virtual void SetVisibleOnImpl(bool visible) = 0; |
| 32 virtual void ReleaseOutputSurfaceOnImpl() = 0; |
| 33 virtual void FinishGLOnImpl() = 0; |
| 34 virtual void MainFrameWillHappenOnImplForTesting( |
| 35 bool* main_frame_will_happen) = 0; |
26 | 36 |
27 virtual ~ChannelMain() {} | 37 virtual ~ChannelMain() {} |
28 }; | 38 }; |
29 | 39 |
30 } // namespace cc | 40 } // namespace cc |
31 | 41 |
32 #endif // CC_TREES_CHANNEL_MAIN_H_ | 42 #endif // CC_TREES_CHANNEL_MAIN_H_ |
OLD | NEW |