| 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_DIRECT_RENDERER_H_ | 5 #ifndef CC_OUTPUT_DIRECT_RENDERER_H_ |
| 6 #define CC_OUTPUT_DIRECT_RENDERER_H_ | 6 #define CC_OUTPUT_DIRECT_RENDERER_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <unordered_map> | 9 #include <unordered_map> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 void DrawFrame(RenderPassList* render_passes_in_draw_order, | 56 void DrawFrame(RenderPassList* render_passes_in_draw_order, |
| 57 float device_scale_factor, | 57 float device_scale_factor, |
| 58 const gfx::ColorSpace& device_color_space, | 58 const gfx::ColorSpace& device_color_space, |
| 59 const gfx::Size& device_viewport_size); | 59 const gfx::Size& device_viewport_size); |
| 60 | 60 |
| 61 // Public interface implemented by subclasses. | 61 // Public interface implemented by subclasses. |
| 62 virtual void SwapBuffers(std::vector<ui::LatencyInfo> latency_info) = 0; | 62 virtual void SwapBuffers(std::vector<ui::LatencyInfo> latency_info) = 0; |
| 63 virtual void SwapBuffersComplete() {} | 63 virtual void SwapBuffersComplete() {} |
| 64 virtual void DidReceiveTextureInUseResponses( | 64 virtual void DidReceiveTextureInUseResponses( |
| 65 const gpu::TextureInUseResponses& responses) {} | 65 const gpu::TextureInUseResponses& responses) {} |
| 66 virtual void ReadbackSwappedOverlayTextures( |
| 67 std::vector<SkBitmap>* bitmaps, |
| 68 const base::Callback<void(bool)>& callback); |
| 66 | 69 |
| 67 // Allow tests to enlarge the texture size of non-root render passes to | 70 // Allow tests to enlarge the texture size of non-root render passes to |
| 68 // verify cases where the texture doesn't match the render pass size. | 71 // verify cases where the texture doesn't match the render pass size. |
| 69 void SetEnlargePassTextureAmountForTesting(const gfx::Size& amount) { | 72 void SetEnlargePassTextureAmountForTesting(const gfx::Size& amount) { |
| 70 enlarge_pass_texture_amount_ = amount; | 73 enlarge_pass_texture_amount_ = amount; |
| 71 } | 74 } |
| 72 | 75 |
| 73 // Public for tests that poke at internals. | 76 // Public for tests that poke at internals. |
| 74 struct CC_EXPORT DrawingFrame { | 77 struct CC_EXPORT DrawingFrame { |
| 75 DrawingFrame(); | 78 DrawingFrame(); |
| (...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 224 gfx::ColorSpace reshape_device_color_space_; | 227 gfx::ColorSpace reshape_device_color_space_; |
| 225 bool reshape_has_alpha_ = false; | 228 bool reshape_has_alpha_ = false; |
| 226 bool reshape_use_stencil_ = false; | 229 bool reshape_use_stencil_ = false; |
| 227 | 230 |
| 228 DISALLOW_COPY_AND_ASSIGN(DirectRenderer); | 231 DISALLOW_COPY_AND_ASSIGN(DirectRenderer); |
| 229 }; | 232 }; |
| 230 | 233 |
| 231 } // namespace cc | 234 } // namespace cc |
| 232 | 235 |
| 233 #endif // CC_OUTPUT_DIRECT_RENDERER_H_ | 236 #endif // CC_OUTPUT_DIRECT_RENDERER_H_ |
| OLD | NEW |