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

Unified Diff: src/gpu/gl/GrGLProgramDataManager.cpp

Issue 1462123003: Create GrGLSLVaryingHandler class for program building (Closed) Base URL: https://skia.googlesource.com/skia.git@putCapsOnArgs
Patch Set: fix release builder Created 5 years, 1 month 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/GrGLProgramDataManager.h ('k') | src/gpu/gl/GrGLVaryingHandler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gl/GrGLProgramDataManager.cpp
diff --git a/src/gpu/gl/GrGLProgramDataManager.cpp b/src/gpu/gl/GrGLProgramDataManager.cpp
index 7320b2dd8a44fa0b7b84310a7d5b027b7f69e7e3..a61e6974b64742b81bf8b1472c53503070814dbd 100644
--- a/src/gpu/gl/GrGLProgramDataManager.cpp
+++ b/src/gpu/gl/GrGLProgramDataManager.cpp
@@ -15,7 +15,7 @@
GrGLProgramDataManager::GrGLProgramDataManager(GrGLGpu* gpu, GrGLuint programID,
const UniformInfoArray& uniforms,
- const SeparableVaryingInfoArray& separableVaryings)
+ const VaryingInfoArray& pathProcVaryings)
: fGpu(gpu)
, fProgramID(programID) {
int count = uniforms.count();
@@ -44,19 +44,19 @@ GrGLProgramDataManager::GrGLProgramDataManager(GrGLGpu* gpu, GrGLuint programID,
}
// NVPR programs have separable varyings
- count = separableVaryings.count();
- fSeparableVaryings.push_back_n(count);
+ count = pathProcVaryings.count();
+ fPathProcVaryings.push_back_n(count);
for (int i = 0; i < count; i++) {
SkASSERT(fGpu->glCaps().shaderCaps()->pathRenderingSupport());
- SeparableVarying& separableVarying = fSeparableVaryings[i];
- const SeparableVaryingInfo& builderSeparableVarying = separableVaryings[i];
- SkASSERT(GrGLSLShaderVar::kNonArray == builderSeparableVarying.fVariable.getArrayCount() ||
- builderSeparableVarying.fVariable.getArrayCount() > 0);
+ PathProcVarying& pathProcVarying = fPathProcVaryings[i];
+ const VaryingInfo& builderPathProcVarying = pathProcVaryings[i];
+ SkASSERT(GrGLSLShaderVar::kNonArray == builderPathProcVarying.fVariable.getArrayCount() ||
+ builderPathProcVarying.fVariable.getArrayCount() > 0);
SkDEBUGCODE(
- separableVarying.fArrayCount = builderSeparableVarying.fVariable.getArrayCount();
- separableVarying.fType = builderSeparableVarying.fVariable.getType();
+ pathProcVarying.fArrayCount = builderPathProcVarying.fVariable.getArrayCount();
+ pathProcVarying.fType = builderPathProcVarying.fVariable.getType();
);
- separableVarying.fLocation = builderSeparableVarying.fLocation;
+ pathProcVarying.fLocation = builderPathProcVarying.fLocation;
}
}
@@ -276,11 +276,11 @@ void GrGLProgramDataManager::setSkMatrix(UniformHandle u, const SkMatrix& matrix
this->setMatrix3f(u, mt);
}
-void GrGLProgramDataManager::setPathFragmentInputTransform(SeparableVaryingHandle u,
+void GrGLProgramDataManager::setPathFragmentInputTransform(VaryingHandle u,
int components,
const SkMatrix& matrix) const {
SkASSERT(fGpu->glCaps().shaderCaps()->pathRenderingSupport());
- const SeparableVarying& fragmentInput = fSeparableVaryings[u.toIndex()];
+ const PathProcVarying& fragmentInput = fPathProcVaryings[u.toIndex()];
SkASSERT((components == 2 && fragmentInput.fType == kVec2f_GrSLType) ||
(components == 3 && fragmentInput.fType == kVec3f_GrSLType));
« no previous file with comments | « src/gpu/gl/GrGLProgramDataManager.h ('k') | src/gpu/gl/GrGLVaryingHandler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698