aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/gl/GrGLProgram.h
diff options
context:
space:
mode:
authorGravatar commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-09-06 20:19:56 +0000
committerGravatar commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-09-06 20:19:56 +0000
commita91f03165335267bda7cf04ae5ffb60c1362f017 (patch)
tree64d7c0e9a4cc83b0b1e9725dd97e55361f497ed9 /src/gpu/gl/GrGLProgram.h
parente65d76f0fce19bcff44e1179ef1eec5874a2a145 (diff)
Add a requiresVertexShader method to GrGLEffect
Adds requiresVertexShader to GrGLEffect and updates the necessary effects to override it and return true. Also reworks GrGLProgram and GrGLShaderBuilder so the program creates all the GL effects at the beginning, and determines if it needs a vertex shader before creating the shader builder. R=bsalomon@google.com Author: cdalton@nvidia.com Review URL: https://chromiumcodereview.appspot.com/23471008 git-svn-id: http://skia.googlecode.com/svn/trunk@11140 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/gpu/gl/GrGLProgram.h')
-rw-r--r--src/gpu/gl/GrGLProgram.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gpu/gl/GrGLProgram.h b/src/gpu/gl/GrGLProgram.h
index 4a16b0cf4c..bef2ecf544 100644
--- a/src/gpu/gl/GrGLProgram.h
+++ b/src/gpu/gl/GrGLProgram.h
@@ -178,6 +178,14 @@ private:
void genGeometryShader(GrGLShaderBuilder::VertexBuilder* vertexBuilder) const;
+ // Creates a set of GrGLEffects and GrGLDrawEffects.
+ void buildGLEffects(SkTArray<EffectAndSamplers> GrGLProgram::* effectSet,
+ const GrEffectStage* stages[],
+ int count,
+ bool hasExplicitLocalCoords,
+ SkTArray<GrDrawEffect>* drawEffects,
+ bool* hasVertexShaderEffects);
+
// Creates a GL program ID, binds shader attributes to GL vertex attrs, and links the program
bool bindOutputsAttribsAndLinkProgram(const GrGLShaderBuilder& builder,
bool bindColorOut,