OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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_OUTPUT_DELEGATING_RENDERER_H_ | 5 #ifndef CC_OUTPUT_DELEGATING_RENDERER_H_ |
6 #define CC_OUTPUT_DELEGATING_RENDERER_H_ | 6 #define CC_OUTPUT_DELEGATING_RENDERER_H_ |
7 | 7 |
8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
9 #include "cc/base/cc_export.h" | 9 #include "cc/base/cc_export.h" |
10 #include "cc/output/compositor_frame.h" | 10 #include "cc/output/compositor_frame.h" |
(...skipping 14 matching lines...) Expand all Loading... |
25 virtual ~DelegatingRenderer(); | 25 virtual ~DelegatingRenderer(); |
26 | 26 |
27 virtual const RendererCapabilities& Capabilities() const OVERRIDE; | 27 virtual const RendererCapabilities& Capabilities() const OVERRIDE; |
28 | 28 |
29 virtual bool CanReadPixels() const OVERRIDE; | 29 virtual bool CanReadPixels() const OVERRIDE; |
30 | 30 |
31 virtual void DrawFrame(RenderPassList* render_passes_in_draw_order) OVERRIDE; | 31 virtual void DrawFrame(RenderPassList* render_passes_in_draw_order) OVERRIDE; |
32 | 32 |
33 virtual void Finish() OVERRIDE {} | 33 virtual void Finish() OVERRIDE {} |
34 | 34 |
35 virtual void SwapBuffers(const ui::LatencyInfo& latency_info) OVERRIDE; | 35 virtual void SwapBuffers() OVERRIDE; |
| 36 virtual void ReceiveSwapBuffersAck(const CompositorFrameAck&) OVERRIDE; |
36 | 37 |
37 virtual void GetFramebufferPixels(void* pixels, gfx::Rect rect) OVERRIDE; | 38 virtual void GetFramebufferPixels(void* pixels, gfx::Rect rect) OVERRIDE; |
38 | 39 |
39 virtual void ReceiveCompositorFrameAck(const CompositorFrameAck&) OVERRIDE; | |
40 | |
41 virtual bool IsContextLost() OVERRIDE; | 40 virtual bool IsContextLost() OVERRIDE; |
42 | 41 |
43 virtual void SetVisible(bool visible) OVERRIDE; | 42 virtual void SetVisible(bool visible) OVERRIDE; |
44 | 43 |
45 virtual void SendManagedMemoryStats(size_t bytes_visible, | 44 virtual void SendManagedMemoryStats(size_t bytes_visible, |
46 size_t bytes_visible_and_nearby, | 45 size_t bytes_visible_and_nearby, |
47 size_t bytes_allocated) OVERRIDE {} | 46 size_t bytes_allocated) OVERRIDE {} |
48 | 47 |
49 private: | 48 private: |
50 DelegatingRenderer(RendererClient* client, | 49 DelegatingRenderer(RendererClient* client, |
51 OutputSurface* output_surface, | 50 OutputSurface* output_surface, |
52 ResourceProvider* resource_provider); | 51 ResourceProvider* resource_provider); |
53 bool Initialize(); | 52 bool Initialize(); |
54 | 53 |
55 OutputSurface* output_surface_; | 54 OutputSurface* output_surface_; |
56 ResourceProvider* resource_provider_; | 55 ResourceProvider* resource_provider_; |
57 RendererCapabilities capabilities_; | 56 RendererCapabilities capabilities_; |
58 CompositorFrame frame_for_swap_buffers_; | 57 CompositorFrame frame_for_swap_buffers_; |
59 bool visible_; | 58 bool visible_; |
60 | 59 |
61 DISALLOW_COPY_AND_ASSIGN(DelegatingRenderer); | 60 DISALLOW_COPY_AND_ASSIGN(DelegatingRenderer); |
62 }; | 61 }; |
63 | 62 |
64 } // namespace cc | 63 } // namespace cc |
65 | 64 |
66 #endif // CC_OUTPUT_DELEGATING_RENDERER_H_ | 65 #endif // CC_OUTPUT_DELEGATING_RENDERER_H_ |
OLD | NEW |