| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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_SINGLE_THREAD_PROXY_H_ | 5 #ifndef CC_TREES_SINGLE_THREAD_PROXY_H_ |
| 6 #define CC_TREES_SINGLE_THREAD_PROXY_H_ | 6 #define CC_TREES_SINGLE_THREAD_PROXY_H_ |
| 7 | 7 |
| 8 #include <limits> | 8 #include <limits> |
| 9 | 9 |
| 10 #include "base/cancelable_callback.h" | 10 #include "base/cancelable_callback.h" |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 122 void CompositeImmediately(base::TimeTicks frame_begin_time); | 122 void CompositeImmediately(base::TimeTicks frame_begin_time); |
| 123 | 123 |
| 124 protected: | 124 protected: |
| 125 SingleThreadProxy( | 125 SingleThreadProxy( |
| 126 LayerTreeHost* layer_tree_host, | 126 LayerTreeHost* layer_tree_host, |
| 127 LayerTreeHostSingleThreadClient* client, | 127 LayerTreeHostSingleThreadClient* client, |
| 128 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner, | 128 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner, |
| 129 scoped_ptr<BeginFrameSource> external_begin_frame_source); | 129 scoped_ptr<BeginFrameSource> external_begin_frame_source); |
| 130 | 130 |
| 131 private: | 131 private: |
| 132 void BeginMainFrame(); | 132 void BeginMainFrame(const BeginFrameArgs& begin_frame_args); |
| 133 void BeginMainFrameAbortedOnImplThread(CommitEarlyOutReason reason); | 133 void BeginMainFrameAbortedOnImplThread(CommitEarlyOutReason reason); |
| 134 void DoAnimate(); | 134 void DoAnimate(); |
| 135 void DoBeginMainFrame(const BeginFrameArgs& begin_frame_args); | 135 void DoBeginMainFrame(const BeginFrameArgs& begin_frame_args); |
| 136 void DoCommit(); | 136 void DoCommit(); |
| 137 DrawResult DoComposite(base::TimeTicks frame_begin_time, | 137 DrawResult DoComposite(base::TimeTicks frame_begin_time, |
| 138 LayerTreeHostImpl::FrameData* frame); | 138 LayerTreeHostImpl::FrameData* frame); |
| 139 void DoSwap(); | 139 void DoSwap(); |
| 140 void DidCommitAndDrawFrame(); | 140 void DidCommitAndDrawFrame(); |
| 141 void CommitComplete(); | 141 void CommitComplete(); |
| 142 | 142 |
| (...skipping 10 matching lines...) Expand all Loading... |
| 153 RendererCapabilities renderer_capabilities_for_main_thread_; | 153 RendererCapabilities renderer_capabilities_for_main_thread_; |
| 154 | 154 |
| 155 // Accessed from both threads. | 155 // Accessed from both threads. |
| 156 scoped_ptr<Scheduler> scheduler_on_impl_thread_; | 156 scoped_ptr<Scheduler> scheduler_on_impl_thread_; |
| 157 ProxyTimingHistory timing_history_; | 157 ProxyTimingHistory timing_history_; |
| 158 | 158 |
| 159 scoped_ptr<BlockingTaskRunner::CapturePostTasks> commit_blocking_task_runner_; | 159 scoped_ptr<BlockingTaskRunner::CapturePostTasks> commit_blocking_task_runner_; |
| 160 scoped_ptr<ResourceUpdateQueue> queue_for_commit_; | 160 scoped_ptr<ResourceUpdateQueue> queue_for_commit_; |
| 161 bool next_frame_is_newly_committed_frame_; | 161 bool next_frame_is_newly_committed_frame_; |
| 162 | 162 |
| 163 bool inside_impl_frame_; |
| 163 bool inside_draw_; | 164 bool inside_draw_; |
| 164 bool defer_commits_; | 165 bool defer_commits_; |
| 165 bool animate_requested_; | 166 bool animate_requested_; |
| 166 bool commit_requested_; | 167 bool commit_requested_; |
| 167 bool inside_synchronous_composite_; | 168 bool inside_synchronous_composite_; |
| 168 | 169 |
| 169 // True if a request to the LayerTreeHostClient to create an output surface | 170 // True if a request to the LayerTreeHostClient to create an output surface |
| 170 // is still outstanding. | 171 // is still outstanding. |
| 171 bool output_surface_creation_requested_; | 172 bool output_surface_creation_requested_; |
| 172 | 173 |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 235 private: | 236 private: |
| 236 DebugScopedSetImplThread impl_thread_; | 237 DebugScopedSetImplThread impl_thread_; |
| 237 DebugScopedSetMainThreadBlocked main_thread_blocked_; | 238 DebugScopedSetMainThreadBlocked main_thread_blocked_; |
| 238 | 239 |
| 239 DISALLOW_COPY_AND_ASSIGN(DebugScopedSetImplThreadAndMainThreadBlocked); | 240 DISALLOW_COPY_AND_ASSIGN(DebugScopedSetImplThreadAndMainThreadBlocked); |
| 240 }; | 241 }; |
| 241 | 242 |
| 242 } // namespace cc | 243 } // namespace cc |
| 243 | 244 |
| 244 #endif // CC_TREES_SINGLE_THREAD_PROXY_H_ | 245 #endif // CC_TREES_SINGLE_THREAD_PROXY_H_ |
| OLD | NEW |