diff options
Diffstat (limited to 'src/gpu/gl/GrGLProgramDesc.h')
-rw-r--r-- | src/gpu/gl/GrGLProgramDesc.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/gpu/gl/GrGLProgramDesc.h b/src/gpu/gl/GrGLProgramDesc.h index e160438e08..0c7c8cf629 100644 --- a/src/gpu/gl/GrGLProgramDesc.h +++ b/src/gpu/gl/GrGLProgramDesc.h @@ -113,6 +113,17 @@ private: kColorInputCnt }; + static GrSLConstantVec KnownColorInputValue(ColorInput ci) { + switch (ci) { + case GrGLProgramDesc::kTransBlack_ColorInput: + return kZeros_GrSLConstantVec; + case GrGLProgramDesc::kSolidWhite_ColorInput: + return kOnes_GrSLConstantVec; + default: + return kNone_GrSLConstantVec; + } + } + enum CoverageOutput { // modulate color and coverage, write result as the color output. kModulate_CoverageOutput, @@ -221,6 +232,7 @@ private: // code generation to GrGLShaderBuilder (and maybe add getters rather than friending). friend class GrGLProgram; friend class GrGLShaderBuilder; + friend class GrGLFullShaderBuilder; }; #endif |