#ifndef GrGLBackendSurface_DEFINED
#define GrGLBackendSurface_DEFINED
#include "include/gpu/ganesh/gl/GrGLTypes.h"
#include "include/private/base/SkAPI.h"
#include <string_view>
class GrBackendFormat;
class GrBackendTexture;
class GrBackendRenderTarget;
namespace skgpu { enum class Mipmapped : bool; }
namespace GrBackendFormats {
SK_API GrBackendFormat MakeGL(GrGLenum format, GrGLenum target);
SK_API GrGLFormat AsGLFormat(const GrBackendFormat&);
SK_API GrGLenum AsGLFormatEnum(const GrBackendFormat&);
}
namespace GrBackendTextures {
SK_API GrBackendTexture MakeGL(int width,
int height,
skgpu::Mipmapped,
const GrGLTextureInfo& glInfo,
std::string_view label = { … };
SK_API bool GetGLTextureInfo(const GrBackendTexture&, GrGLTextureInfo*);
SK_API void GLTextureParametersModified(GrBackendTexture*);
}
namespace GrBackendRenderTargets {
SK_API GrBackendRenderTarget MakeGL(int width,
int height,
int sampleCnt,
int stencilBits,
const GrGLFramebufferInfo& glInfo);
SK_API bool GetGLFramebufferInfo(const GrBackendRenderTarget&, GrGLFramebufferInfo*);
}
#endif