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_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_OUTPUT_SURFACE
_H_ | 5 #ifndef CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_OUTPUT_SURFACE
_H_ |
6 #define CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_OUTPUT_SURFACE
_H_ | 6 #define CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_OUTPUT_SURFACE
_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 // OutputSurface. | 56 // OutputSurface. |
57 virtual bool ForcedDrawToSoftwareDevice() const OVERRIDE; | 57 virtual bool ForcedDrawToSoftwareDevice() const OVERRIDE; |
58 virtual bool BindToClient(cc::OutputSurfaceClient* surface_client) OVERRIDE; | 58 virtual bool BindToClient(cc::OutputSurfaceClient* surface_client) OVERRIDE; |
59 virtual void Reshape(gfx::Size size, float scale_factor) OVERRIDE; | 59 virtual void Reshape(gfx::Size size, float scale_factor) OVERRIDE; |
60 virtual void SetNeedsBeginFrame(bool enable) OVERRIDE; | 60 virtual void SetNeedsBeginFrame(bool enable) OVERRIDE; |
61 virtual void SwapBuffers(cc::CompositorFrame* frame) OVERRIDE; | 61 virtual void SwapBuffers(cc::CompositorFrame* frame) OVERRIDE; |
62 | 62 |
63 // Partial SynchronousCompositor API implementation. | 63 // Partial SynchronousCompositor API implementation. |
64 bool InitializeHwDraw( | 64 bool InitializeHwDraw( |
65 scoped_refptr<gfx::GLSurface> surface, | 65 scoped_refptr<gfx::GLSurface> surface, |
66 scoped_refptr<cc::ContextProvider> offscreen_context); | 66 scoped_refptr<cc::ContextProvider> offscreen_context_provider); |
67 void ReleaseHwDraw(); | 67 void ReleaseHwDraw(); |
68 bool DemandDrawHw(gfx::Size surface_size, | 68 bool DemandDrawHw(gfx::Size surface_size, |
69 const gfx::Transform& transform, | 69 const gfx::Transform& transform, |
70 gfx::Rect clip, | 70 gfx::Rect clip, |
71 bool stencil_enabled); | 71 bool stencil_enabled); |
72 bool DemandDrawSw(SkCanvas* canvas); | 72 bool DemandDrawSw(SkCanvas* canvas); |
73 | 73 |
74 private: | 74 private: |
75 class SoftwareDevice; | 75 class SoftwareDevice; |
76 friend class SoftwareDevice; | 76 friend class SoftwareDevice; |
(...skipping 12 matching lines...) Expand all Loading... |
89 | 89 |
90 // Only valid (non-NULL) during a DemandDrawSw() call. | 90 // Only valid (non-NULL) during a DemandDrawSw() call. |
91 SkCanvas* current_sw_canvas_; | 91 SkCanvas* current_sw_canvas_; |
92 | 92 |
93 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorOutputSurface); | 93 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorOutputSurface); |
94 }; | 94 }; |
95 | 95 |
96 } // namespace content | 96 } // namespace content |
97 | 97 |
98 #endif // CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_OUTPUT_SURF
ACE_H_ | 98 #endif // CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_OUTPUT_SURF
ACE_H_ |
OLD | NEW |