Flutter Engine
 
Loading...
Searching...
No Matches
vulkan_backbuffer.h
Go to the documentation of this file.
1// Copyright 2013 The Flutter Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef FLUTTER_VULKAN_VULKAN_BACKBUFFER_H_
6#define FLUTTER_VULKAN_VULKAN_BACKBUFFER_H_
7
8#include <array>
9
10#include "flutter/fml/macros.h"
12#include "third_party/skia/include/core/SkSize.h"
13#include "third_party/skia/include/core/SkSurface.h"
15
16namespace vulkan {
17
19 public:
22 const VulkanHandle<VkCommandPool>& pool);
23
25
26 bool IsValid() const;
27
28 [[nodiscard]] bool WaitFences();
29
30 [[nodiscard]] bool ResetFences();
31
33
35
37
39
41
43
44 private:
45 const VulkanProcTable& vk_;
46 const VulkanHandle<VkDevice>& device_;
47 std::array<VulkanHandle<VkSemaphore>, 2> semaphores_;
48 std::array<VulkanHandle<VkFence>, 2> use_fences_;
49 VulkanCommandBuffer usage_command_buffer_;
50 VulkanCommandBuffer render_command_buffer_;
51 bool valid_;
52
53 bool CreateSemaphores();
54
55 bool CreateFences();
56
58};
59
60} // namespace vulkan
61
62#endif // FLUTTER_VULKAN_VULKAN_BACKBUFFER_H_
VulkanCommandBuffer & GetUsageCommandBuffer()
const VulkanHandle< VkSemaphore > & GetUsageSemaphore() const
const VulkanHandle< VkFence > & GetUsageFence() const
const VulkanHandle< VkSemaphore > & GetRenderSemaphore() const
VulkanCommandBuffer & GetRenderCommandBuffer()
const VulkanHandle< VkFence > & GetRenderFence() const
VkDevice device
Definition main.cc:69
#define FML_DISALLOW_COPY_AND_ASSIGN(TypeName)
Definition macros.h:27