Index: src/gpu/gl/GrGLProgramDesc.cpp |
diff --git a/src/gpu/gl/GrGLProgramDesc.cpp b/src/gpu/gl/GrGLProgramDesc.cpp |
index e1a319104d1d66b2b215cab22fc5457170ef00ac..90365f768bd81f5df18a075174175982a027e828 100644 |
--- a/src/gpu/gl/GrGLProgramDesc.cpp |
+++ b/src/gpu/gl/GrGLProgramDesc.cpp |
@@ -102,9 +102,10 @@ bool GrGLProgramDesc::Build(const GrDrawState& drawState, |
bool readsDst = false; |
bool readFragPosition = false; |
- // We use vertexshader-less shader programs only when drawing paths. |
- bool hasVertexCode = !(GrGpu::kDrawPath_DrawType == drawType || |
- GrGpu::kDrawPaths_DrawType == drawType); |
+ |
+ // Provide option for shader programs without vertex shader only when drawing paths. |
+ bool hasVertexCode = !GrGpu::IsPathRenderingDrawType(drawType); |
+ |
int numStages = 0; |
if (!skipColor) { |
numStages += drawState.numColorStages() - firstEffectiveColorStage; |
@@ -118,7 +119,6 @@ bool GrGLProgramDesc::Build(const GrDrawState& drawState, |
desc->fKey.push_back_n(kEffectKeyOffsetsAndLengthOffset + 2 * sizeof(uint16_t) * numStages); |
int offsetAndSizeIndex = 0; |
- |
bool effectKeySuccess = true; |
if (!skipColor) { |
for (int s = firstEffectiveColorStage; s < drawState.numColorStages(); ++s) { |