| OLD | NEW |
| 1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2016 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_VULKAN_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ | 5 #ifndef CONTENT_BROWSER_COMPOSITOR_VULKAN_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ |
| 6 #define CONTENT_BROWSER_COMPOSITOR_VULKAN_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ | 6 #define CONTENT_BROWSER_COMPOSITOR_VULKAN_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 24 matching lines...) Expand all Loading... |
| 35 void BindToClient(cc::OutputSurfaceClient* client) override; | 35 void BindToClient(cc::OutputSurfaceClient* client) override; |
| 36 void EnsureBackbuffer() override; | 36 void EnsureBackbuffer() override; |
| 37 void DiscardBackbuffer() override; | 37 void DiscardBackbuffer() override; |
| 38 void BindFramebuffer() override; | 38 void BindFramebuffer() override; |
| 39 bool IsDisplayedAsOverlayPlane() const override; | 39 bool IsDisplayedAsOverlayPlane() const override; |
| 40 unsigned GetOverlayTextureId() const override; | 40 unsigned GetOverlayTextureId() const override; |
| 41 bool SurfaceIsSuspendForRecycle() const override; | 41 bool SurfaceIsSuspendForRecycle() const override; |
| 42 void Reshape(const gfx::Size& size, | 42 void Reshape(const gfx::Size& size, |
| 43 float device_scale_factor, | 43 float device_scale_factor, |
| 44 const gfx::ColorSpace& color_space, | 44 const gfx::ColorSpace& color_space, |
| 45 bool has_alpha) override; | 45 bool has_alpha, |
| 46 bool use_stencil) override; |
| 46 uint32_t GetFramebufferCopyTextureFormat() override; | 47 uint32_t GetFramebufferCopyTextureFormat() override; |
| 47 void SwapBuffers(cc::OutputSurfaceFrame frame) override; | 48 void SwapBuffers(cc::OutputSurfaceFrame frame) override; |
| 48 | 49 |
| 49 private: | 50 private: |
| 50 void SwapBuffersAck(); | 51 void SwapBuffersAck(); |
| 51 | 52 |
| 52 std::unique_ptr<gpu::VulkanSurface> surface_; | 53 std::unique_ptr<gpu::VulkanSurface> surface_; |
| 53 cc::OutputSurfaceClient* client_ = nullptr; | 54 cc::OutputSurfaceClient* client_ = nullptr; |
| 54 base::WeakPtrFactory<VulkanBrowserCompositorOutputSurface> weak_ptr_factory_; | 55 base::WeakPtrFactory<VulkanBrowserCompositorOutputSurface> weak_ptr_factory_; |
| 55 | 56 |
| 56 DISALLOW_COPY_AND_ASSIGN(VulkanBrowserCompositorOutputSurface); | 57 DISALLOW_COPY_AND_ASSIGN(VulkanBrowserCompositorOutputSurface); |
| 57 }; | 58 }; |
| 58 | 59 |
| 59 } // namespace content | 60 } // namespace content |
| 60 | 61 |
| 61 #endif // CONTENT_BROWSER_COMPOSITOR_VULKAN_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H
_ | 62 #endif // CONTENT_BROWSER_COMPOSITOR_VULKAN_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H
_ |
| OLD | NEW |