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

Unified Diff: src/gpu/gl/builders/GrGLLegacyNvprProgramBuilder.cpp

Issue 637003003: Opt state takes a GP instead of a GeometryStage (Closed) Base URL: https://skia.googlesource.com/skia.git@builder_cleanup
Patch Set: memory leaks fixed 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/gl/builders/GrGLLegacyNvprProgramBuilder.h ('k') | src/gpu/gl/builders/GrGLNvprProgramBuilder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gl/builders/GrGLLegacyNvprProgramBuilder.cpp
diff --git a/src/gpu/gl/builders/GrGLLegacyNvprProgramBuilder.cpp b/src/gpu/gl/builders/GrGLLegacyNvprProgramBuilder.cpp
index acb4af10be10e3dcdcc0ec104eae58b0fd8d1f70..1c1cb421223b366747058be5cd3775d8cd9e0e67 100644
--- a/src/gpu/gl/builders/GrGLLegacyNvprProgramBuilder.cpp
+++ b/src/gpu/gl/builders/GrGLLegacyNvprProgramBuilder.cpp
@@ -24,20 +24,17 @@ int GrGLLegacyNvprProgramBuilder::addTexCoordSets(int count) {
return firstFreeCoordSet;
}
-void GrGLLegacyNvprProgramBuilder::emitTransforms(const GrProcessorStage& processorStage,
+void GrGLLegacyNvprProgramBuilder::emitTransforms(const GrFragmentStage& processorStage,
GrGLProcessor::TransformedCoordsArray* outCoords,
- GrGLInstalledProcessors* installedProcessors) {
+ GrGLInstalledFragProc* ifp) {
int numTransforms = processorStage.getProcessor()->numTransforms();
int texCoordIndex = this->addTexCoordSets(numTransforms);
- SkTArray<GrGLInstalledProcessors::Transform, true>& transforms =
- installedProcessors->addTransforms();
-
// Use the first uniform location as the texcoord index. This may seem a bit hacky but it
// allows us to use one program effects object for all of our programs which really simplifies
// the code overall
- transforms.push_back_n(1);
- transforms[0].fHandle = GrGLInstalledProcessors::ShaderVarHandle(texCoordIndex);
+ ifp->fTransforms.push_back_n(1);
+ ifp->fTransforms[0].fHandle = GrGLInstalledFragProc::ShaderVarHandle(texCoordIndex);
SkString name;
for (int t = 0; t < numTransforms; ++t) {
@@ -51,5 +48,5 @@ void GrGLLegacyNvprProgramBuilder::emitTransforms(const GrProcessorStage& proces
GrGLProgram* GrGLLegacyNvprProgramBuilder::createProgram(GrGLuint programID) {
return SkNEW_ARGS(GrGLLegacyNvprProgram, (fGpu, fDesc, fUniformHandles, programID, fUniforms,
- fColorEffects, fCoverageEffects, fTexCoordSetCnt));
+ fFragmentProcessors.get(), fTexCoordSetCnt));
}
« no previous file with comments | « src/gpu/gl/builders/GrGLLegacyNvprProgramBuilder.h ('k') | src/gpu/gl/builders/GrGLNvprProgramBuilder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698