Chromium Code Reviews| Index: src/gpu/gl/builders/GrGLFragmentShaderBuilder.h |
| diff --git a/src/gpu/gl/builders/GrGLFragmentShaderBuilder.h b/src/gpu/gl/builders/GrGLFragmentShaderBuilder.h |
| index 1637d25612e75ba592d8fd5bbdbb1449d2994986..1ea727790c3956eafaf91e54b162672fa429d2eb 100644 |
| --- a/src/gpu/gl/builders/GrGLFragmentShaderBuilder.h |
| +++ b/src/gpu/gl/builders/GrGLFragmentShaderBuilder.h |
| @@ -10,6 +10,8 @@ |
| #include "GrGLShaderBuilder.h" |
| +class GrGLVarying; |
| + |
| /* |
| * This base class encapsulates the functionality which the GP uses to build fragment shaders |
| */ |
| @@ -91,6 +93,16 @@ public: |
| virtual const char* fragmentPosition() SK_OVERRIDE; |
| virtual const char* dstColor() SK_OVERRIDE; |
| + // As GLProcessors emit code, there are some conditions we need to verify. We use the below |
| + // state to track this. The reset call is called per processor emitted. |
| + bool hasReadDstColor() const { return fHasReadDstColor; } |
| + bool hasReadFragmentPosition() const { return fHasReadFragmentPosition; } |
| + void reset() { |
| + fHasReadDstColor = false; |
| + fHasReadFragmentPosition = false; |
| + } |
| + |
|
joshualitt
2014/10/23 20:08:22
whoops, I'll make this private
|
| +private: |
| // Private public interface, used by GrGLProgramBuilder to build a fragment shader |
| void emitCodeToReadDstTexture(); |
| void enableCustomOutput(); |
| @@ -105,21 +117,9 @@ public: |
| /* |
| * An internal call for GrGLProgramBuilder to use to add varyings to the vertex shader |
| */ |
| - void addVarying(GrSLType type, |
| - const char* name, |
| - const char** fsInName, |
| - GrGLShaderVar::Precision fsPrecision = GrGLShaderVar::kDefault_Precision); |
| + void addVarying(GrGLVarying* v, |
| + GrGLShaderVar::Precision fsPrec = GrGLShaderVar::kDefault_Precision); |
| - // As GLProcessors emit code, there are some conditions we need to verify. We use the below |
| - // state to track this. The reset call is called per processor emitted. |
| - bool hasReadDstColor() const { return fHasReadDstColor; } |
| - bool hasReadFragmentPosition() const { return fHasReadFragmentPosition; } |
| - void reset() { |
| - fHasReadDstColor = false; |
| - fHasReadFragmentPosition = false; |
| - } |
| - |
| -private: |
| /** |
| * Features that should only be enabled by GrGLFragmentShaderBuilder itself. |
| */ |