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_SOFTWARE_RENDERER_H_ | 5 #ifndef CC_OUTPUT_SOFTWARE_RENDERER_H_ |
6 #define CC_OUTPUT_SOFTWARE_RENDERER_H_ | 6 #define CC_OUTPUT_SOFTWARE_RENDERER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.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 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 gfx::Rect framebuffer_rect) OVERRIDE; | 51 gfx::Rect framebuffer_rect) OVERRIDE; |
52 virtual void SetDrawViewportSize(gfx::Size viewport_size) OVERRIDE; | 52 virtual void SetDrawViewportSize(gfx::Size viewport_size) OVERRIDE; |
53 virtual void SetScissorTestRect(gfx::Rect scissor_rect) OVERRIDE; | 53 virtual void SetScissorTestRect(gfx::Rect scissor_rect) OVERRIDE; |
54 virtual void ClearFramebuffer(DrawingFrame* frame) OVERRIDE; | 54 virtual void ClearFramebuffer(DrawingFrame* frame) OVERRIDE; |
55 virtual void DoDrawQuad(DrawingFrame* frame, const DrawQuad* quad) OVERRIDE; | 55 virtual void DoDrawQuad(DrawingFrame* frame, const DrawQuad* quad) OVERRIDE; |
56 virtual void BeginDrawingFrame(DrawingFrame* frame) OVERRIDE; | 56 virtual void BeginDrawingFrame(DrawingFrame* frame) OVERRIDE; |
57 virtual void FinishDrawingFrame(DrawingFrame* frame) OVERRIDE; | 57 virtual void FinishDrawingFrame(DrawingFrame* frame) OVERRIDE; |
58 virtual bool FlippedFramebuffer() const OVERRIDE; | 58 virtual bool FlippedFramebuffer() const OVERRIDE; |
59 virtual void EnsureScissorTestEnabled() OVERRIDE; | 59 virtual void EnsureScissorTestEnabled() OVERRIDE; |
60 virtual void EnsureScissorTestDisabled() OVERRIDE; | 60 virtual void EnsureScissorTestDisabled() OVERRIDE; |
61 virtual void CopyCurrentRenderPassToBitmap(DrawingFrame* frame, | 61 virtual void CopyCurrentRenderPassToBitmap( |
62 SkBitmap* bitmap) OVERRIDE; | 62 DrawingFrame* frame, |
| 63 const CopyRenderPassCallback& callback) OVERRIDE; |
63 | 64 |
64 private: | 65 private: |
65 SoftwareRenderer( | 66 SoftwareRenderer( |
66 RendererClient* client, | 67 RendererClient* client, |
67 OutputSurface* output_surface, | 68 OutputSurface* output_surface, |
68 ResourceProvider* resource_provider); | 69 ResourceProvider* resource_provider); |
69 | 70 |
70 void ClearCanvas(SkColor color); | 71 void ClearCanvas(SkColor color); |
71 void SetClipRect(gfx::Rect rect); | 72 void SetClipRect(gfx::Rect rect); |
72 bool IsSoftwareResource(ResourceProvider::ResourceId resource_id) const; | 73 bool IsSoftwareResource(ResourceProvider::ResourceId resource_id) const; |
(...skipping 25 matching lines...) Expand all Loading... |
98 scoped_ptr<ResourceProvider::ScopedWriteLockSoftware> | 99 scoped_ptr<ResourceProvider::ScopedWriteLockSoftware> |
99 current_framebuffer_lock_; | 100 current_framebuffer_lock_; |
100 CompositorFrame compositor_frame_; | 101 CompositorFrame compositor_frame_; |
101 | 102 |
102 DISALLOW_COPY_AND_ASSIGN(SoftwareRenderer); | 103 DISALLOW_COPY_AND_ASSIGN(SoftwareRenderer); |
103 }; | 104 }; |
104 | 105 |
105 } // namespace cc | 106 } // namespace cc |
106 | 107 |
107 #endif // CC_OUTPUT_SOFTWARE_RENDERER_H_ | 108 #endif // CC_OUTPUT_SOFTWARE_RENDERER_H_ |
OLD | NEW |