Lines Matching refs:programID
43 static void cleanup_program(GrGLGpu* gpu, GrGLuint programID, in cleanup_program() argument
45 GR_GL_CALL(gpu->glInterface(), DeleteProgram(programID)); in cleanup_program()
119 void GrGLProgramBuilder::computeCountsAndStrides(GrGLuint programID, in computeCountsAndStrides() argument
133 GL_CALL(BindAttribLocation(programID, i, a.name())); in computeCountsAndStrides()
159 void GrGLProgramBuilder::storeShaderInCache(const SkSL::Program::Inputs& inputs, GrGLuint programID, in storeShaderInCache() argument
170 GL_CALL(GetProgramiv(programID, GL_PROGRAM_BINARY_LENGTH, &length)); in storeShaderInCache()
180 GL_CALL(GetProgramBinary(programID, length, &length, &binaryFormat, binary.get())); in storeShaderInCache()
212 GrGLuint programID; in finalize() local
214 programID = precompiledProgram->fProgramID; in finalize()
216 GL_CALL_RET(programID, CreateProgram()); in finalize()
218 if (0 == programID) { in finalize()
226 GL_CALL(ProgramParameteri(programID, GR_GL_PROGRAM_BINARY_RETRIEVABLE_HINT, GR_GL_TRUE)); in finalize()
258 this->computeCountsAndStrides(programID, geomProc, false); in finalize()
282 ProgramBinary(programID, binaryFormat, in finalize()
286 cached = this->checkLinkStatus(programID, errorHandler, nullptr, nullptr); in finalize()
290 this->computeCountsAndStrides(programID, geomProc, false); in finalize()
341 cleanup_program(fGpu, programID, shadersToDelete); in finalize()
348 if (!this->compileAndAttachShaders(glsl[kFragment_GrShaderType], programID, in finalize()
350 cleanup_program(fGpu, programID, shadersToDelete); in finalize()
366 cleanup_program(fGpu, programID, shadersToDelete); in finalize()
370 if (!this->compileAndAttachShaders(glsl[kVertex_GrShaderType], programID, in finalize()
372 cleanup_program(fGpu, programID, shadersToDelete); in finalize()
377 this->computeCountsAndStrides(programID, geomProc, true); in finalize()
395 if (!this->compileAndAttachShaders(tessControlShader.c_str(), programID, in finalize()
398 cleanup_program(fGpu, programID, shadersToDelete); in finalize()
405 if (!this->compileAndAttachShaders(tessEvaluationShader.c_str(), programID, in finalize()
408 cleanup_program(fGpu, programID, shadersToDelete); in finalize()
427 cleanup_program(fGpu, programID, shadersToDelete); in finalize()
431 if (!this->compileAndAttachShaders(glsl[kGeometry_GrShaderType], programID, in finalize()
434 cleanup_program(fGpu, programID, shadersToDelete); in finalize()
438 this->bindProgramResourceLocations(programID); in finalize()
442 GL_CALL(LinkProgram(programID)); in finalize()
444 if (!this->checkLinkStatus(programID, errorHandler, sksl, glsl)) { in finalize()
445 cleanup_program(fGpu, programID, shadersToDelete); in finalize()
451 this->resolveProgramResourceLocations(programID, usedProgramBinaries); in finalize()
471 this->storeShaderInCache(inputs, programID, glsl, isSkSL, &settings); in finalize()
473 return this->createProgram(programID); in finalize()
476 void GrGLProgramBuilder::bindProgramResourceLocations(GrGLuint programID) { in bindProgramResourceLocations() argument
477 fUniformHandler.bindUniformLocations(programID, fGpu->glCaps()); in bindProgramResourceLocations()
481 GL_CALL(BindFragDataLocation(programID, 0, in bindProgramResourceLocations()
485 GL_CALL(BindFragDataLocationIndexed(programID, 0, 1, in bindProgramResourceLocations()
490 bool GrGLProgramBuilder::checkLinkStatus(GrGLuint programID, in checkLinkStatus() argument
494 GL_CALL(GetProgramiv(programID, GR_GL_LINK_STATUS, &linked)); in checkLinkStatus()
512 GL_CALL(GetProgramiv(programID, GR_GL_INFO_LOG_LENGTH, &infoLen)); in checkLinkStatus()
518 GL_CALL(GetProgramInfoLog(programID, infoLen+1, &length, (char*)log.get())); in checkLinkStatus()
525 void GrGLProgramBuilder::resolveProgramResourceLocations(GrGLuint programID, bool force) { in resolveProgramResourceLocations() argument
526 fUniformHandler.getUniformLocations(programID, fGpu->glCaps(), force); in resolveProgramResourceLocations()
529 sk_sp<GrGLProgram> GrGLProgramBuilder::createProgram(GrGLuint programID) { in createProgram() argument
532 programID, in createProgram()
571 GrGLuint programID; in PrecompileProgram() local
572 GR_GL_CALL_RET(gl, programID, CreateProgram()); in PrecompileProgram()
573 if (0 == programID) { in PrecompileProgram()
586 if (GrGLuint shaderID = GrGLCompileAndAttachShader(glGpu->glContext(), programID, type, in PrecompileProgram()
606 cleanup_program(glGpu, programID, shadersToDelete); in PrecompileProgram()
611 GR_GL_CALL(glGpu->glInterface(), BindAttribLocation(programID, i, in PrecompileProgram()
618 BindFragDataLocation(programID, 0, in PrecompileProgram()
623 BindFragDataLocationIndexed(programID, 0, 1, in PrecompileProgram()
627 GR_GL_CALL(glGpu->glInterface(), LinkProgram(programID)); in PrecompileProgram()
629 GR_GL_CALL(glGpu->glInterface(), GetProgramiv(programID, GR_GL_LINK_STATUS, &linked)); in PrecompileProgram()
631 cleanup_program(glGpu, programID, shadersToDelete); in PrecompileProgram()
637 precompiledProgram->fProgramID = programID; in PrecompileProgram()