Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
GrVkBackendSurface.h
Go to the documentation of this file.
1/*
2 * Copyright 2023 Google LLC
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8#ifndef GrVkBackendSurface_DEFINED
9#define GrVkBackendSurface_DEFINED
10
13
14#include <string_view>
15
16class GrBackendFormat;
19
20
21namespace GrBackendFormats {
22
23SK_API GrBackendFormat MakeVk(VkFormat format, bool willUseDRMFormatModifiers = false);
25 bool willUseDRMFormatModifiers = false);
26
29
30} // namespace GrBackendFormats
31
32
33namespace GrBackendTextures {
34
36 int height,
37 const GrVkImageInfo&,
38 std::string_view label = {});
39
40// If the backend API is Vulkan, copies a snapshot of the GrVkImageInfo struct into the passed
41// in pointer and returns true. This snapshot will set the fImageLayout to the current layout
42// state. Otherwise returns false if the backend API is not Vulkan.
44
45// Anytime the client changes the VkImageLayout of the VkImage captured by this
46// GrBackendTexture, they must call this function to notify Skia of the changed layout.
48
49} // namespace GrBackendTextures
50
51
52namespace GrBackendRenderTargets {
53
55
56// If the backend API is Vulkan, copies a snapshot of the GrVkImageInfo struct into the passed
57// in pointer and returns true. This snapshot will set the fImageLayout to the current layout
58// state. Otherwise returns false if the backend API is not Vulkan.
60
61// Anytime the client changes the VkImageLayout of the VkImage captured by this
62// GrBackendRenderTarget, they must call this function to notify Skia of the changed layout.
64
65} // namespace GrBackendRenderTargets
66
67#endif
#define SK_API
Definition SkAPI.h:35
uint32_t uint32_t * format
SK_API bool AsVkFormat(const GrBackendFormat &, VkFormat *)
SK_API GrBackendFormat MakeVk(VkFormat format, bool willUseDRMFormatModifiers=false)
SK_API const GrVkYcbcrConversionInfo * GetVkYcbcrConversionInfo(const GrBackendFormat &)
SK_API bool GetVkImageInfo(const GrBackendRenderTarget &, GrVkImageInfo *)
SK_API void SetVkImageLayout(GrBackendRenderTarget *, VkImageLayout)
SK_API GrBackendRenderTarget MakeVk(int width, int height, const GrVkImageInfo &)
SK_API void SetVkImageLayout(GrBackendTexture *, VkImageLayout)
SK_API GrBackendTexture MakeVk(int width, int height, const GrVkImageInfo &, std::string_view label={})
SK_API bool GetVkImageInfo(const GrBackendTexture &, GrVkImageInfo *)
int32_t height
int32_t width
VkImageLayout
VkFormat