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

Unified Diff: src/gpu/effects/GrDashingEffect.cpp

Issue 611653002: Cleanup of shader building system (Closed) Base URL: https://skia.googlesource.com/skia.git@solo_gp
Patch Set: Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/effects/GrCustomCoordsTextureEffect.cpp ('k') | src/gpu/effects/GrDistanceFieldTextureEffect.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/effects/GrDashingEffect.cpp
diff --git a/src/gpu/effects/GrDashingEffect.cpp b/src/gpu/effects/GrDashingEffect.cpp
index 4df1f02558e9a1d5ea1cc629c09b87f66fb388a6..d7a2f402da06424cbeb076976b2e7eb53fc5999b 100644
--- a/src/gpu/effects/GrDashingEffect.cpp
+++ b/src/gpu/effects/GrDashingEffect.cpp
@@ -10,7 +10,7 @@
#include "../GrAARectRenderer.h"
#include "GrGeometryProcessor.h"
-#include "gl/builders/GrGLFullProgramBuilder.h"
+#include "gl/builders/GrGLProgramBuilder.h"
#include "gl/GrGLProcessor.h"
#include "gl/GrGLGeometryProcessor.h"
#include "gl/GrGLSL.h"
@@ -482,7 +482,7 @@ class GLDashingCircleEffect : public GrGLGeometryProcessor {
public:
GLDashingCircleEffect(const GrBackendProcessorFactory&, const GrProcessor&);
- virtual void emitCode(GrGLFullProgramBuilder* builder,
+ virtual void emitCode(GrGLGPBuilder* builder,
const GrGeometryProcessor& geometryProcessor,
const GrProcessorKey& key,
const char* outputColor,
@@ -510,7 +510,7 @@ GLDashingCircleEffect::GLDashingCircleEffect(const GrBackendProcessorFactory& fa
fPrevIntervalLength = SK_ScalarMax;
}
-void GLDashingCircleEffect::emitCode(GrGLFullProgramBuilder* builder,
+void GLDashingCircleEffect::emitCode(GrGLGPBuilder* builder,
const GrGeometryProcessor& geometryProcessor,
const GrProcessorKey& key,
const char* outputColor,
@@ -529,11 +529,11 @@ void GLDashingCircleEffect::emitCode(GrGLFullProgramBuilder* builder,
const char *vsCoordName, *fsCoordName;
builder->addVarying(kVec2f_GrSLType, "Coord", &vsCoordName, &fsCoordName);
- GrGLVertexShaderBuilder* vsBuilder = builder->getVertexShaderBuilder();
+ GrGLVertexBuilder* vsBuilder = builder->getVertexShaderBuilder();
vsBuilder->codeAppendf("\t%s = %s;\n", vsCoordName, dce.inCoord().c_str());
// transforms all points so that we can compare them to our test circle
- GrGLProcessorFragmentShaderBuilder* fsBuilder = builder->getFragmentShaderBuilder();
+ GrGLGPFragmentBuilder* fsBuilder = builder->getFragmentShaderBuilder();
fsBuilder->codeAppendf("\t\tfloat xShifted = %s.x - floor(%s.x / %s.z) * %s.z;\n",
fsCoordName, fsCoordName, paramName, paramName);
fsBuilder->codeAppendf("\t\tvec2 fragPosShifted = vec2(xShifted, %s.y);\n", fsCoordName);
@@ -694,7 +694,7 @@ class GLDashingLineEffect : public GrGLGeometryProcessor {
public:
GLDashingLineEffect(const GrBackendProcessorFactory&, const GrProcessor&);
- virtual void emitCode(GrGLFullProgramBuilder* builder,
+ virtual void emitCode(GrGLGPBuilder* builder,
const GrGeometryProcessor& geometryProcessor,
const GrProcessorKey& key,
const char* outputColor,
@@ -721,7 +721,7 @@ GLDashingLineEffect::GLDashingLineEffect(const GrBackendProcessorFactory& factor
fPrevIntervalLength = SK_ScalarMax;
}
-void GLDashingLineEffect::emitCode(GrGLFullProgramBuilder* builder,
+void GLDashingLineEffect::emitCode(GrGLGPBuilder* builder,
const GrGeometryProcessor& geometryProcessor,
const GrProcessorKey& key,
const char* outputColor,
@@ -745,11 +745,11 @@ void GLDashingLineEffect::emitCode(GrGLFullProgramBuilder* builder,
const char *vsCoordName, *fsCoordName;
builder->addVarying(kVec2f_GrSLType, "Coord", &vsCoordName, &fsCoordName);
- GrGLVertexShaderBuilder* vsBuilder = builder->getVertexShaderBuilder();
+ GrGLVertexBuilder* vsBuilder = builder->getVertexShaderBuilder();
vsBuilder->codeAppendf("\t%s = %s;\n", vsCoordName, de.inCoord().c_str());
// transforms all points so that we can compare them to our test rect
- GrGLProcessorFragmentShaderBuilder* fsBuilder = builder->getFragmentShaderBuilder();
+ GrGLGPFragmentBuilder* fsBuilder = builder->getFragmentShaderBuilder();
fsBuilder->codeAppendf("\t\tfloat xShifted = %s.x - floor(%s.x / %s) * %s;\n",
fsCoordName, fsCoordName, intervalName, intervalName);
fsBuilder->codeAppendf("\t\tvec2 fragPosShifted = vec2(xShifted, %s.y);\n", fsCoordName);
« no previous file with comments | « src/gpu/effects/GrCustomCoordsTextureEffect.cpp ('k') | src/gpu/effects/GrDistanceFieldTextureEffect.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698