Flutter Engine
The Flutter Engine
GrGLBackendSurface.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 GrGLBackendSurface_DEFINED
9#define GrGLBackendSurface_DEFINED
10
13
14#include <string_view>
15
16class GrBackendFormat;
19
20namespace skgpu { enum class Mipmapped : bool; }
21
24
27} // namespace GrBackendFormats
28
30// The GrGLTextureInfo must have a valid fFormat.
32 int height,
34 const GrGLTextureInfo& glInfo,
35 std::string_view label = {});
36
37// If the backend API is GL, copies a snapshot of the GrGLTextureInfo struct into the passed in
38// pointer and returns true. Otherwise returns false if the backend API is not GL.
40
41// Call this to indicate that the texture parameters have been modified in the GL context
42// externally to GrContext.
44} // namespace GrBackendTextures
45
47// The GrGLTextureInfo must have a valid fFormat. If wrapping in an SkSurface we require the
48// stencil bits to be either 0, 8 or 16.
50 int height,
51 int sampleCnt,
52 int stencilBits,
53 const GrGLFramebufferInfo& glInfo);
54
56} // namespace GrBackendRenderTargets
57
58#endif
GrGLFormat
Definition: GrGLTypes.h:59
unsigned int GrGLenum
Definition: GrGLTypes.h:102
#define SK_API
Definition: SkAPI.h:35
uint32_t uint32_t * format
uint32_t * target
SK_API GrGLFormat AsGLFormat(const GrBackendFormat &)
SK_API GrGLenum AsGLFormatEnum(const GrBackendFormat &)
SK_API GrBackendFormat MakeGL(GrGLenum format, GrGLenum target)
SK_API GrBackendRenderTarget MakeGL(int width, int height, int sampleCnt, int stencilBits, const GrGLFramebufferInfo &glInfo)
SK_API bool GetGLFramebufferInfo(const GrBackendRenderTarget &, GrGLFramebufferInfo *)
SK_API GrBackendTexture MakeGL(int width, int height, skgpu::Mipmapped, const GrGLTextureInfo &glInfo, std::string_view label={})
SK_API void GLTextureParametersModified(GrBackendTexture *)
SK_API bool GetGLTextureInfo(const GrBackendTexture &, GrGLTextureInfo *)
Definition: GpuTools.h:21
Mipmapped
Definition: GpuTypes.h:53
int32_t height
int32_t width