OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 CONTENT_RENDERER_GPU_RENDER_WIDGET_COMPOSITOR_H_ | 5 #ifndef CONTENT_RENDERER_GPU_RENDER_WIDGET_COMPOSITOR_H_ |
6 #define CONTENT_RENDERER_GPU_RENDER_WIDGET_COMPOSITOR_H_ | 6 #define CONTENT_RENDERER_GPU_RENDER_WIDGET_COMPOSITOR_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/memory/weak_ptr.h" | 9 #include "base/memory/weak_ptr.h" |
10 #include "base/time/time.h" | 10 #include "base/time/time.h" |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
59 // Calling CreateLatencyInfoSwapPromiseMonitor() to get a scoped | 59 // Calling CreateLatencyInfoSwapPromiseMonitor() to get a scoped |
60 // LatencyInfoSwapPromiseMonitor. During the life time of the | 60 // LatencyInfoSwapPromiseMonitor. During the life time of the |
61 // LatencyInfoSwapPromiseMonitor, if SetNeedsCommit() or | 61 // LatencyInfoSwapPromiseMonitor, if SetNeedsCommit() or |
62 // SetNeedsUpdateLayers() is called on LayerTreeHost, the original latency | 62 // SetNeedsUpdateLayers() is called on LayerTreeHost, the original latency |
63 // info will be turned into a LatencyInfoSwapPromise. | 63 // info will be turned into a LatencyInfoSwapPromise. |
64 scoped_ptr<cc::SwapPromiseMonitor> CreateLatencyInfoSwapPromiseMonitor( | 64 scoped_ptr<cc::SwapPromiseMonitor> CreateLatencyInfoSwapPromiseMonitor( |
65 ui::LatencyInfo* latency); | 65 ui::LatencyInfo* latency); |
66 // Calling QueueSwapPromise() to directly queue a SwapPromise into | 66 // Calling QueueSwapPromise() to directly queue a SwapPromise into |
67 // LayerTreeHost. | 67 // LayerTreeHost. |
68 void QueueSwapPromise(scoped_ptr<cc::SwapPromise> swap_promise); | 68 void QueueSwapPromise(scoped_ptr<cc::SwapPromise> swap_promise); |
69 int GetLayerTreeId() const; | |
70 int GetSourceFrameNumber() const; | 69 int GetSourceFrameNumber() const; |
71 void SetNeedsUpdateLayers(); | 70 void SetNeedsUpdateLayers(); |
72 void SetNeedsCommit(); | 71 void SetNeedsCommit(); |
73 void NotifyInputThrottledUntilCommit(); | 72 void NotifyInputThrottledUntilCommit(); |
74 const cc::Layer* GetRootLayer() const; | 73 const cc::Layer* GetRootLayer() const; |
75 int ScheduleMicroBenchmark( | 74 int ScheduleMicroBenchmark( |
76 const std::string& name, | 75 const std::string& name, |
77 scoped_ptr<base::Value> value, | 76 scoped_ptr<base::Value> value, |
78 const base::Callback<void(scoped_ptr<base::Value>)>& callback); | 77 const base::Callback<void(scoped_ptr<base::Value>)>& callback); |
79 bool SendMessageToMicroBenchmark(int id, scoped_ptr<base::Value> value); | 78 bool SendMessageToMicroBenchmark(int id, scoped_ptr<base::Value> value); |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
180 scoped_ptr<cc::LayerTreeHost> layer_tree_host_; | 179 scoped_ptr<cc::LayerTreeHost> layer_tree_host_; |
181 | 180 |
182 scoped_ptr<cc::CopyOutputRequest> temporary_copy_output_request_; | 181 scoped_ptr<cc::CopyOutputRequest> temporary_copy_output_request_; |
183 | 182 |
184 base::WeakPtrFactory<RenderWidgetCompositor> weak_factory_; | 183 base::WeakPtrFactory<RenderWidgetCompositor> weak_factory_; |
185 }; | 184 }; |
186 | 185 |
187 } // namespace content | 186 } // namespace content |
188 | 187 |
189 #endif // CONTENT_RENDERER_GPU_RENDER_WIDGET_COMPOSITOR_H_ | 188 #endif // CONTENT_RENDERER_GPU_RENDER_WIDGET_COMPOSITOR_H_ |
OLD | NEW |