Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Macros | Functions | Variables
GrGLProgramBuilder.cpp File Reference
#include "src/gpu/ganesh/gl/builders/GrGLProgramBuilder.h"
#include "include/gpu/GrDirectContext.h"
#include "src/base/SkAutoMalloc.h"
#include "src/core/SkReadBuffer.h"
#include "src/core/SkTraceEvent.h"
#include "src/core/SkWriteBuffer.h"
#include "src/gpu/PipelineUtils.h"
#include "src/gpu/Swizzle.h"
#include "src/gpu/ganesh/GrAutoLocaleSetter.h"
#include "src/gpu/ganesh/GrDirectContextPriv.h"
#include "src/gpu/ganesh/GrFragmentProcessor.h"
#include "src/gpu/ganesh/GrGeometryProcessor.h"
#include "src/gpu/ganesh/GrPersistentCacheUtils.h"
#include "src/gpu/ganesh/GrProgramDesc.h"
#include "src/gpu/ganesh/GrShaderCaps.h"
#include "src/gpu/ganesh/GrXferProcessor.h"
#include "src/gpu/ganesh/gl/GrGLGpu.h"
#include "src/gpu/ganesh/gl/GrGLProgram.h"
#include "src/sksl/SkSLProgramKind.h"
#include "src/sksl/SkSLProgramSettings.h"
#include "src/utils/SkShaderUtils.h"
#include <memory>
#include "src/gpu/ganesh/gl/builders/GrGLShaderStringBuilder.h"
#include "src/gpu/ganesh/glsl/GrGLSLProgramDataManager.h"

Go to the source code of this file.

Macros

#define GL_CALL(X)   GR_GL_CALL(this->gpu()->glInterface(), X)
 
#define GL_CALL_RET(R, X)   GR_GL_CALL_RET(this->gpu()->glInterface(), R, X)
 

Functions

static void cleanup_shaders (GrGLGpu *gpu, const SkTDArray< GrGLuint > &shaderIDs)
 
static void cleanup_program (GrGLGpu *gpu, GrGLuint programID, const SkTDArray< GrGLuint > &shaderIDs)
 

Variables

static constexpr SkFourByteTag kSKSL_Tag = SkSetFourByteTag('S', 'K', 'S', 'L')
 
static constexpr SkFourByteTag kGLSL_Tag = SkSetFourByteTag('G', 'L', 'S', 'L')
 
static constexpr SkFourByteTag kGLPB_Tag = SkSetFourByteTag('G', 'L', 'P', 'B')
 

Macro Definition Documentation

◆ GL_CALL

#define GL_CALL (   X)    GR_GL_CALL(this->gpu()->glInterface(), X)

Definition at line 36 of file GrGLProgramBuilder.cpp.

◆ GL_CALL_RET

#define GL_CALL_RET (   R,
  X 
)    GR_GL_CALL_RET(this->gpu()->glInterface(), R, X)

Definition at line 37 of file GrGLProgramBuilder.cpp.

Function Documentation

◆ cleanup_program()

static void cleanup_program ( GrGLGpu gpu,
GrGLuint  programID,
const SkTDArray< GrGLuint > &  shaderIDs 
)
static

Definition at line 45 of file GrGLProgramBuilder.cpp.

46 {
47 GR_GL_CALL(gpu->glInterface(), DeleteProgram(programID));
48 cleanup_shaders(gpu, shaderIDs);
49}
static void cleanup_shaders(GrGLGpu *gpu, const SkTDArray< GrGLuint > &shaderIDs)
#define GR_GL_CALL(IFACE, X)
Definition GrGLUtil.h:381
const GrGLInterface * glInterface() const
Definition GrGLGpu.h:103

◆ cleanup_shaders()

static void cleanup_shaders ( GrGLGpu gpu,
const SkTDArray< GrGLuint > &  shaderIDs 
)
static

Definition at line 39 of file GrGLProgramBuilder.cpp.

39 {
40 for (int i = 0; i < shaderIDs.size(); ++i) {
41 GR_GL_CALL(gpu->glInterface(), DeleteShader(shaderIDs[i]));
42 }
43}
int size() const
Definition SkTDArray.h:138

Variable Documentation

◆ kGLPB_Tag

constexpr SkFourByteTag kGLPB_Tag = SkSetFourByteTag('G', 'L', 'P', 'B')
staticconstexpr

Definition at line 160 of file GrGLProgramBuilder.cpp.

◆ kGLSL_Tag

constexpr SkFourByteTag kGLSL_Tag = SkSetFourByteTag('G', 'L', 'S', 'L')
staticconstexpr

Definition at line 159 of file GrGLProgramBuilder.cpp.

◆ kSKSL_Tag

constexpr SkFourByteTag kSKSL_Tag = SkSetFourByteTag('S', 'K', 'S', 'L')
staticconstexpr

Definition at line 158 of file GrGLProgramBuilder.cpp.