| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ | 5 #ifndef CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ |
| 6 #define CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ | 6 #define CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 | 32 |
| 33 // Adapts a WebGraphicsContext3DCommandBufferImpl into a | 33 // Adapts a WebGraphicsContext3DCommandBufferImpl into a |
| 34 // cc::OutputSurface that also handles vsync parameter updates | 34 // cc::OutputSurface that also handles vsync parameter updates |
| 35 // arriving from the GPU process. | 35 // arriving from the GPU process. |
| 36 class GpuBrowserCompositorOutputSurface | 36 class GpuBrowserCompositorOutputSurface |
| 37 : public BrowserCompositorOutputSurface { | 37 : public BrowserCompositorOutputSurface { |
| 38 public: | 38 public: |
| 39 GpuBrowserCompositorOutputSurface( | 39 GpuBrowserCompositorOutputSurface( |
| 40 scoped_refptr<ContextProviderCommandBuffer> context, | 40 scoped_refptr<ContextProviderCommandBuffer> context, |
| 41 scoped_refptr<ui::CompositorVSyncManager> vsync_manager, | 41 scoped_refptr<ui::CompositorVSyncManager> vsync_manager, |
| 42 cc::SyntheticBeginFrameSource* begin_frame_source, | |
| 43 std::unique_ptr<display_compositor::CompositorOverlayCandidateValidator> | 42 std::unique_ptr<display_compositor::CompositorOverlayCandidateValidator> |
| 44 overlay_candidate_validator); | 43 overlay_candidate_validator); |
| 45 | 44 |
| 46 ~GpuBrowserCompositorOutputSurface() override; | 45 ~GpuBrowserCompositorOutputSurface() override; |
| 47 | 46 |
| 48 // Called when a swap completion is sent from the GPU process. | 47 // Called when a swap completion is sent from the GPU process. |
| 49 // The argument |params_mac| is used to communicate parameters needed on Mac | 48 // The argument |params_mac| is used to communicate parameters needed on Mac |
| 50 // to display the CALayer for the swap in the browser process. | 49 // to display the CALayer for the swap in the browser process. |
| 51 // TODO(ccameron): Remove |params_mac| when the CALayer tree is hosted in the | 50 // TODO(ccameron): Remove |params_mac| when the CALayer tree is hosted in the |
| 52 // browser process. | 51 // browser process. |
| (...skipping 30 matching lines...) Expand all Loading... |
| 83 std::unique_ptr<ReflectorTexture> reflector_texture_; | 82 std::unique_ptr<ReflectorTexture> reflector_texture_; |
| 84 base::WeakPtrFactory<GpuBrowserCompositorOutputSurface> weak_ptr_factory_; | 83 base::WeakPtrFactory<GpuBrowserCompositorOutputSurface> weak_ptr_factory_; |
| 85 | 84 |
| 86 private: | 85 private: |
| 87 DISALLOW_COPY_AND_ASSIGN(GpuBrowserCompositorOutputSurface); | 86 DISALLOW_COPY_AND_ASSIGN(GpuBrowserCompositorOutputSurface); |
| 88 }; | 87 }; |
| 89 | 88 |
| 90 } // namespace content | 89 } // namespace content |
| 91 | 90 |
| 92 #endif // CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ | 91 #endif // CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ |
| OLD | NEW |