OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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_ANDROID_SYNCHRONOUS_COMPOSITOR_FRAME_SINK_H_ | 5 #ifndef CONTENT_RENDERER_ANDROID_SYNCHRONOUS_COMPOSITOR_FRAME_SINK_H_ |
6 #define CONTENT_RENDERER_ANDROID_SYNCHRONOUS_COMPOSITOR_FRAME_SINK_H_ | 6 #define CONTENT_RENDERER_ANDROID_SYNCHRONOUS_COMPOSITOR_FRAME_SINK_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 // |delegate_|) which represent the consumers of the two roles in plays. | 64 // |delegate_|) which represent the consumers of the two roles in plays. |
65 // This class can be created only on the main thread, but then becomes pinned | 65 // This class can be created only on the main thread, but then becomes pinned |
66 // to a fixed thread when BindToClient is called. | 66 // to a fixed thread when BindToClient is called. |
67 class SynchronousCompositorFrameSink | 67 class SynchronousCompositorFrameSink |
68 : NON_EXPORTED_BASE(public cc::CompositorFrameSink), | 68 : NON_EXPORTED_BASE(public cc::CompositorFrameSink), |
69 public cc::SurfaceFactoryClient { | 69 public cc::SurfaceFactoryClient { |
70 public: | 70 public: |
71 SynchronousCompositorFrameSink( | 71 SynchronousCompositorFrameSink( |
72 scoped_refptr<cc::ContextProvider> context_provider, | 72 scoped_refptr<cc::ContextProvider> context_provider, |
73 scoped_refptr<cc::ContextProvider> worker_context_provider, | 73 scoped_refptr<cc::ContextProvider> worker_context_provider, |
| 74 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager, |
74 int routing_id, | 75 int routing_id, |
75 uint32_t compositor_frame_sink_id, | 76 uint32_t compositor_frame_sink_id, |
76 std::unique_ptr<cc::BeginFrameSource> begin_frame_source, | 77 std::unique_ptr<cc::BeginFrameSource> begin_frame_source, |
77 SynchronousCompositorRegistry* registry, | 78 SynchronousCompositorRegistry* registry, |
78 scoped_refptr<FrameSwapMessageQueue> frame_swap_message_queue); | 79 scoped_refptr<FrameSwapMessageQueue> frame_swap_message_queue); |
79 ~SynchronousCompositorFrameSink() override; | 80 ~SynchronousCompositorFrameSink() override; |
80 | 81 |
81 void SetSyncClient(SynchronousCompositorFrameSinkClient* compositor); | 82 void SetSyncClient(SynchronousCompositorFrameSinkClient* compositor); |
82 bool OnMessageReceived(const IPC::Message& message); | 83 bool OnMessageReceived(const IPC::Message& message); |
83 | 84 |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
161 gfx::Rect sw_viewport_for_current_draw_; | 162 gfx::Rect sw_viewport_for_current_draw_; |
162 | 163 |
163 base::ThreadChecker thread_checker_; | 164 base::ThreadChecker thread_checker_; |
164 | 165 |
165 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorFrameSink); | 166 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorFrameSink); |
166 }; | 167 }; |
167 | 168 |
168 } // namespace content | 169 } // namespace content |
169 | 170 |
170 #endif // CONTENT_RENDERER_ANDROID_SYNCHRONOUS_COMPOSITOR_FRAME_SINK_H_ | 171 #endif // CONTENT_RENDERER_ANDROID_SYNCHRONOUS_COMPOSITOR_FRAME_SINK_H_ |
OLD | NEW |