| 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 GPU_VULKAN_VULKAN_SURFACE_H_ | 5 #ifndef GPU_VULKAN_VULKAN_SURFACE_H_ |
| 6 #define GPU_VULKAN_VULKAN_SURFACE_H_ | 6 #define GPU_VULKAN_VULKAN_SURFACE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "gpu/vulkan/vulkan_export.h" | 10 #include "gpu/vulkan/vulkan_export.h" |
| 11 #include "ui/gfx/geometry/size.h" | 11 #include "ui/gfx/geometry/size.h" |
| 12 #include "ui/gfx/native_widget_types.h" | 12 #include "ui/gfx/native_widget_types.h" |
| 13 #include "ui/gfx/swap_result.h" | 13 #include "ui/gfx/swap_result.h" |
| 14 | 14 |
| 15 namespace gpu { | 15 namespace gpu { |
| 16 | 16 |
| 17 class VulkanDeviceQueue; | 17 class VulkanDeviceQueue; |
| 18 class VulkanSwapChain; | 18 class VulkanSwapChain; |
| 19 | 19 |
| 20 class VULKAN_EXPORT VulkanSurface { | 20 class VULKAN_EXPORT VulkanSurface { |
| 21 public: | 21 public: |
| 22 static bool InitializeOneOff(); | |
| 23 | |
| 24 // Minimum bit depth of surface. | 22 // Minimum bit depth of surface. |
| 25 enum Format { | 23 enum Format { |
| 26 FORMAT_BGRA8888, | 24 FORMAT_BGRA8888, |
| 27 FORMAT_RGB565, | 25 FORMAT_RGB565, |
| 28 | 26 |
| 29 NUM_SURFACE_FORMATS, | 27 NUM_SURFACE_FORMATS, |
| 30 DEFAULT_SURFACE_FORMAT = FORMAT_BGRA8888 | 28 DEFAULT_SURFACE_FORMAT = FORMAT_BGRA8888 |
| 31 }; | 29 }; |
| 32 | 30 |
| 33 virtual ~VulkanSurface() = 0; | 31 virtual ~VulkanSurface() = 0; |
| (...skipping 15 matching lines...) Expand all Loading... |
| 49 protected: | 47 protected: |
| 50 VulkanSurface(); | 48 VulkanSurface(); |
| 51 | 49 |
| 52 private: | 50 private: |
| 53 DISALLOW_COPY_AND_ASSIGN(VulkanSurface); | 51 DISALLOW_COPY_AND_ASSIGN(VulkanSurface); |
| 54 }; | 52 }; |
| 55 | 53 |
| 56 } // namespace gpu | 54 } // namespace gpu |
| 57 | 55 |
| 58 #endif // GPU_VULKAN_VULKAN_SURFACE_H_ | 56 #endif // GPU_VULKAN_VULKAN_SURFACE_H_ |
| OLD | NEW |