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> |
11 | 11 |
12 #include "base/callback.h" | 12 #include "base/callback.h" |
13 #include "base/cancelable_callback.h" | 13 #include "base/cancelable_callback.h" |
14 #include "base/compiler_specific.h" | 14 #include "base/compiler_specific.h" |
15 #include "base/macros.h" | 15 #include "base/macros.h" |
16 #include "base/memory/ref_counted.h" | 16 #include "base/memory/ref_counted.h" |
17 #include "base/threading/thread_checker.h" | 17 #include "base/threading/thread_checker.h" |
18 #include "cc/output/compositor_frame.h" | 18 #include "cc/output/compositor_frame.h" |
19 #include "cc/output/compositor_frame_sink.h" | 19 #include "cc/output/compositor_frame_sink.h" |
20 #include "cc/output/managed_memory_policy.h" | 20 #include "cc/output/managed_memory_policy.h" |
21 #include "cc/surfaces/display_client.h" | 21 #include "cc/surfaces/display_client.h" |
22 #include "cc/surfaces/surface_factory_client.h" | 22 #include "cc/surfaces/surface_factory_client.h" |
23 #include "ipc/ipc_message.h" | 23 #include "ipc/ipc_message.h" |
24 #include "ui/gfx/transform.h" | 24 #include "ui/gfx/transform.h" |
25 | 25 |
26 class SkCanvas; | 26 class SkCanvas; |
27 | 27 |
28 namespace cc { | 28 namespace cc { |
29 class ContextProvider; | 29 class ContextProvider; |
30 class CompositorFrameMetadata; | |
31 class Display; | 30 class Display; |
32 class SurfaceFactory; | 31 class SurfaceFactory; |
33 class SurfaceIdAllocator; | 32 class SurfaceIdAllocator; |
34 class SurfaceManager; | 33 class SurfaceManager; |
35 } | 34 } |
36 | 35 |
37 namespace IPC { | 36 namespace IPC { |
38 class Message; | 37 class Message; |
39 class Sender; | 38 class Sender; |
40 } | 39 } |
41 | 40 |
42 namespace content { | 41 namespace content { |
43 | 42 |
44 class FrameSwapMessageQueue; | 43 class FrameSwapMessageQueue; |
45 class SynchronousCompositorRegistry; | 44 class SynchronousCompositorRegistry; |
46 class WebGraphicsContext3DCommandBufferImpl; | |
47 | 45 |
48 class SynchronousCompositorFrameSinkClient { | 46 class SynchronousCompositorFrameSinkClient { |
49 public: | 47 public: |
50 virtual void DidActivatePendingTree() = 0; | 48 virtual void DidActivatePendingTree() = 0; |
51 virtual void Invalidate() = 0; | 49 virtual void Invalidate() = 0; |
52 virtual void SubmitCompositorFrame(uint32_t compositor_frame_sink_id, | 50 virtual void SubmitCompositorFrame(uint32_t compositor_frame_sink_id, |
53 cc::CompositorFrame frame) = 0; | 51 cc::CompositorFrame frame) = 0; |
54 | 52 |
55 protected: | 53 protected: |
56 virtual ~SynchronousCompositorFrameSinkClient() {} | 54 virtual ~SynchronousCompositorFrameSinkClient() {} |
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
162 gfx::Rect sw_viewport_for_current_draw_; | 160 gfx::Rect sw_viewport_for_current_draw_; |
163 | 161 |
164 base::ThreadChecker thread_checker_; | 162 base::ThreadChecker thread_checker_; |
165 | 163 |
166 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorFrameSink); | 164 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorFrameSink); |
167 }; | 165 }; |
168 | 166 |
169 } // namespace content | 167 } // namespace content |
170 | 168 |
171 #endif // CONTENT_RENDERER_ANDROID_SYNCHRONOUS_COMPOSITOR_FRAME_SINK_H_ | 169 #endif // CONTENT_RENDERER_ANDROID_SYNCHRONOUS_COMPOSITOR_FRAME_SINK_H_ |
OLD | NEW |