Flutter Engine
Loading...
Searching...
No Matches
vulkan_surface.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_SURFACE_H_
6
#define FLUTTER_VULKAN_VULKAN_SURFACE_H_
7
8
#include <memory>
9
10
#include "
flutter/fml/macros.h
"
11
#include "
flutter/vulkan/procs/vulkan_handle.h
"
12
#include "third_party/skia/include/core/SkSize.h"
13
14
namespace
vulkan
{
15
16
class
VulkanProcTable;
17
class
VulkanApplication;
18
class
VulkanNativeSurface;
19
20
class
VulkanSurface
{
21
public
:
22
VulkanSurface
(
VulkanProcTable
& vk,
23
VulkanApplication
& application,
24
std::unique_ptr<VulkanNativeSurface> native_surface);
25
26
~VulkanSurface
();
27
28
bool
IsValid
()
const
;
29
30
/// Returns the current size of the surface or (0, 0) if invalid.
31
SkISize
GetSize
()
const
;
32
33
const
VulkanHandle<VkSurfaceKHR>
&
Handle
()
const
;
34
35
const
VulkanNativeSurface
&
GetNativeSurface
()
const
;
36
37
private
:
38
VulkanProcTable
& vk;
39
VulkanApplication
& application_;
40
std::unique_ptr<VulkanNativeSurface> native_surface_;
41
VulkanHandle<VkSurfaceKHR>
surface_;
42
bool
valid_;
43
44
FML_DISALLOW_COPY_AND_ASSIGN
(
VulkanSurface
);
45
};
46
47
}
// namespace vulkan
48
49
#endif
// FLUTTER_VULKAN_VULKAN_SURFACE_H_
vulkan::VulkanApplication
Definition
vulkan_application.h:25
vulkan::VulkanHandle
Definition
vulkan_handle.h:17
vulkan::VulkanNativeSurface
Definition
vulkan_native_surface.h:15
vulkan::VulkanProcTable
Definition
vulkan_proc_table.h:17
vulkan::VulkanSurface
Definition
vulkan_surface.h:20
vulkan::VulkanSurface::~VulkanSurface
~VulkanSurface()
vulkan::VulkanSurface::GetSize
SkISize GetSize() const
Returns the current size of the surface or (0, 0) if invalid.
Definition
vulkan_surface.cc:55
vulkan::VulkanSurface::GetNativeSurface
const VulkanNativeSurface & GetNativeSurface() const
Definition
vulkan_surface.cc:51
vulkan::VulkanSurface::IsValid
bool IsValid() const
Definition
vulkan_surface.cc:43
vulkan::VulkanSurface::Handle
const VulkanHandle< VkSurfaceKHR > & Handle() const
Definition
vulkan_surface.cc:47
macros.h
FML_DISALLOW_COPY_AND_ASSIGN
#define FML_DISALLOW_COPY_AND_ASSIGN(TypeName)
Definition
macros.h:27
vulkan
Definition
vulkan_handle.cc:7
vulkan_handle.h
vulkan
vulkan_surface.h
Generated on Thu Nov 6 2025 16:11:30 for Flutter Engine by
1.9.8