Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(268)

Side by Side Diff: src/gpu/gl/builders/GrGLFragmentShaderBuilder.h

Issue 901663007: Revert of Move DstCopy on gpu into the GrXferProcessor. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/gpu/gl/GrGLXferProcessor.cpp ('k') | src/gpu/gl/builders/GrGLFragmentShaderBuilder.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2014 Google Inc. 2 * Copyright 2014 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef GrGLFragmentShaderBuilder_DEFINED 8 #ifndef GrGLFragmentShaderBuilder_DEFINED
9 #define GrGLFragmentShaderBuilder_DEFINED 9 #define GrGLFragmentShaderBuilder_DEFINED
10 10
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 90
91 // true public interface, defined explicitly in the abstract interfaces abov e 91 // true public interface, defined explicitly in the abstract interfaces abov e
92 bool enableFeature(GLSLFeature) SK_OVERRIDE; 92 bool enableFeature(GLSLFeature) SK_OVERRIDE;
93 virtual SkString ensureFSCoords2D(const GrGLProcessor::TransformedCoordsArra y& coords, 93 virtual SkString ensureFSCoords2D(const GrGLProcessor::TransformedCoordsArra y& coords,
94 int index) SK_OVERRIDE; 94 int index) SK_OVERRIDE;
95 const char* fragmentPosition() SK_OVERRIDE; 95 const char* fragmentPosition() SK_OVERRIDE;
96 const char* dstColor() SK_OVERRIDE; 96 const char* dstColor() SK_OVERRIDE;
97 97
98 private: 98 private:
99 // Private public interface, used by GrGLProgramBuilder to build a fragment shader 99 // Private public interface, used by GrGLProgramBuilder to build a fragment shader
100 void emitCodeToReadDstTexture();
100 void enableCustomOutput(); 101 void enableCustomOutput();
101 void enableSecondaryOutput(); 102 void enableSecondaryOutput();
102 const char* getPrimaryColorOutputName() const; 103 const char* getPrimaryColorOutputName() const;
103 const char* getSecondaryColorOutputName() const; 104 const char* getSecondaryColorOutputName() const;
104 bool compileAndAttachShaders(GrGLuint programId, SkTDArray<GrGLuint>* shader Ids) const; 105 bool compileAndAttachShaders(GrGLuint programId, SkTDArray<GrGLuint>* shader Ids) const;
105 void bindFragmentShaderLocations(GrGLuint programID); 106 void bindFragmentShaderLocations(GrGLuint programID);
106 107
107 // As GLProcessors emit code, there are some conditions we need to verify. We use the below 108 // As GLProcessors emit code, there are some conditions we need to verify. We use the below
108 // state to track this. The reset call is called per processor emitted. 109 // state to track this. The reset call is called per processor emitted.
109 bool hasReadDstColor() const { return fHasReadDstColor; } 110 bool hasReadDstColor() const { return fHasReadDstColor; }
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 // the program creator 154 // the program creator
154 bool fHasReadDstColor; 155 bool fHasReadDstColor;
155 bool fHasReadFragmentPosition; 156 bool fHasReadFragmentPosition;
156 157
157 friend class GrGLProgramBuilder; 158 friend class GrGLProgramBuilder;
158 159
159 typedef GrGLFPFragmentBuilder INHERITED; 160 typedef GrGLFPFragmentBuilder INHERITED;
160 }; 161 };
161 162
162 #endif 163 #endif
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGLXferProcessor.cpp ('k') | src/gpu/gl/builders/GrGLFragmentShaderBuilder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698