Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Side by Side Diff: cc/trees/thread_proxy.h

Issue 1194623003: cc: Remove contents_texture_manager from LayerTreeHost(Impl) and proxy. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: contentstexturemanager: rebase Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « cc/trees/single_thread_proxy.cc ('k') | cc/trees/thread_proxy.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_THREAD_PROXY_H_ 5 #ifndef CC_TREES_THREAD_PROXY_H_
6 #define CC_TREES_THREAD_PROXY_H_ 6 #define CC_TREES_THREAD_PROXY_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 RendererCapabilities renderer_capabilities_main_thread_copy; 81 RendererCapabilities renderer_capabilities_main_thread_copy;
82 82
83 base::WeakPtrFactory<ThreadProxy> weak_factory; 83 base::WeakPtrFactory<ThreadProxy> weak_factory;
84 }; 84 };
85 85
86 // Accessed on the main thread, or when main thread is blocked. 86 // Accessed on the main thread, or when main thread is blocked.
87 struct MainThreadOrBlockedMainThread { 87 struct MainThreadOrBlockedMainThread {
88 explicit MainThreadOrBlockedMainThread(LayerTreeHost* host); 88 explicit MainThreadOrBlockedMainThread(LayerTreeHost* host);
89 ~MainThreadOrBlockedMainThread(); 89 ~MainThreadOrBlockedMainThread();
90 90
91 PrioritizedResourceManager* contents_texture_manager();
92
93 LayerTreeHost* layer_tree_host; 91 LayerTreeHost* layer_tree_host;
94 bool commit_waits_for_activation; 92 bool commit_waits_for_activation;
95 bool main_thread_inside_commit; 93 bool main_thread_inside_commit;
96 }; 94 };
97 95
98 struct CompositorThreadOnly { 96 struct CompositorThreadOnly {
99 CompositorThreadOnly( 97 CompositorThreadOnly(
100 ThreadProxy* proxy, 98 ThreadProxy* proxy,
101 int layer_tree_host_id, 99 int layer_tree_host_id,
102 RenderingStatsInstrumentation* rendering_stats_instrumentation, 100 RenderingStatsInstrumentation* rendering_stats_instrumentation,
103 scoped_ptr<BeginFrameSource> external_begin_frame_source); 101 scoped_ptr<BeginFrameSource> external_begin_frame_source);
104 ~CompositorThreadOnly(); 102 ~CompositorThreadOnly();
105 103
106 const int layer_tree_host_id; 104 const int layer_tree_host_id;
107 105
108 // Copy of the main thread side contents texture manager for work
109 // that needs to be done on the compositor thread.
110 PrioritizedResourceManager* contents_texture_manager;
111
112 scoped_ptr<Scheduler> scheduler; 106 scoped_ptr<Scheduler> scheduler;
113 107
114 // Set when the main thread is waiting on a 108 // Set when the main thread is waiting on a
115 // ScheduledActionSendBeginMainFrame to be issued. 109 // ScheduledActionSendBeginMainFrame to be issued.
116 CompletionEvent* begin_main_frame_sent_completion_event; 110 CompletionEvent* begin_main_frame_sent_completion_event;
117 111
118 // Set when the main thread is waiting on a commit to complete. 112 // Set when the main thread is waiting on a commit to complete.
119 CompletionEvent* commit_completion_event; 113 CompletionEvent* commit_completion_event;
120 114
121 // Set when the main thread is waiting on a pending tree activation. 115 // Set when the main thread is waiting on a pending tree activation.
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 // LayerTreeHostImpl's SetNeedsRedraw(), SetNeedsRedrawRect() and 194 // LayerTreeHostImpl's SetNeedsRedraw(), SetNeedsRedrawRect() and
201 // SetNeedsAnimate(). 195 // SetNeedsAnimate().
202 void SetNeedsRedrawOnImplThread() override; 196 void SetNeedsRedrawOnImplThread() override;
203 void SetNeedsRedrawRectOnImplThread(const gfx::Rect& dirty_rect) override; 197 void SetNeedsRedrawRectOnImplThread(const gfx::Rect& dirty_rect) override;
204 void SetNeedsAnimateOnImplThread() override; 198 void SetNeedsAnimateOnImplThread() override;
205 void SetNeedsPrepareTilesOnImplThread() override; 199 void SetNeedsPrepareTilesOnImplThread() override;
206 void SetNeedsCommitOnImplThread() override; 200 void SetNeedsCommitOnImplThread() override;
207 void SetVideoNeedsBeginFrames(bool needs_begin_frames) override; 201 void SetVideoNeedsBeginFrames(bool needs_begin_frames) override;
208 void PostAnimationEventsToMainThreadOnImplThread( 202 void PostAnimationEventsToMainThreadOnImplThread(
209 scoped_ptr<AnimationEventsVector> queue) override; 203 scoped_ptr<AnimationEventsVector> queue) override;
210 bool ReduceContentsTextureMemoryOnImplThread(size_t limit_bytes,
211 int priority_cutoff) override;
212 bool IsInsideDraw() override; 204 bool IsInsideDraw() override;
213 void RenewTreePriority() override; 205 void RenewTreePriority() override;
214 void PostDelayedAnimationTaskOnImplThread(const base::Closure& task, 206 void PostDelayedAnimationTaskOnImplThread(const base::Closure& task,
215 base::TimeDelta delay) override; 207 base::TimeDelta delay) override;
216 void DidActivateSyncTree() override; 208 void DidActivateSyncTree() override;
217 void DidPrepareTiles() override; 209 void DidPrepareTiles() override;
218 void DidCompletePageScaleAnimationOnImplThread() override; 210 void DidCompletePageScaleAnimationOnImplThread() override;
219 void OnDrawForOutputSurface() override; 211 void OnDrawForOutputSurface() override;
220 // This should only be called by LayerTreeHostImpl::PostFrameTimingEvents. 212 // This should only be called by LayerTreeHostImpl::PostFrameTimingEvents.
221 void PostFrameTimingEventsOnImplThread( 213 void PostFrameTimingEventsOnImplThread(
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 310
319 base::WeakPtr<ThreadProxy> main_thread_weak_ptr_; 311 base::WeakPtr<ThreadProxy> main_thread_weak_ptr_;
320 base::WeakPtr<ThreadProxy> impl_thread_weak_ptr_; 312 base::WeakPtr<ThreadProxy> impl_thread_weak_ptr_;
321 313
322 DISALLOW_COPY_AND_ASSIGN(ThreadProxy); 314 DISALLOW_COPY_AND_ASSIGN(ThreadProxy);
323 }; 315 };
324 316
325 } // namespace cc 317 } // namespace cc
326 318
327 #endif // CC_TREES_THREAD_PROXY_H_ 319 #endif // CC_TREES_THREAD_PROXY_H_
OLDNEW
« no previous file with comments | « cc/trees/single_thread_proxy.cc ('k') | cc/trees/thread_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698