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

Unified Diff: src/effects/SkMatrixConvolutionImageFilter.cpp

Issue 197013003: Clean up SkImageFilter. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 9 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 | « gm/matrixconvolution.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/SkMatrixConvolutionImageFilter.cpp
diff --git a/src/effects/SkMatrixConvolutionImageFilter.cpp b/src/effects/SkMatrixConvolutionImageFilter.cpp
index 9e4ad63e081b4580cc18b807274fcff655872c70..679764a8122fdfd2c957c7f35423575f2b3e0046 100644
--- a/src/effects/SkMatrixConvolutionImageFilter.cpp
+++ b/src/effects/SkMatrixConvolutionImageFilter.cpp
@@ -412,7 +412,7 @@ private:
UniformHandle fBoundsUni;
UniformHandle fKernelUni;
UniformHandle fImageIncrementUni;
- UniformHandle fTargetUni;
+ UniformHandle fKernelOffsetUni;
UniformHandle fGainUni;
UniformHandle fBiasUni;
@@ -467,15 +467,15 @@ void GrGLMatrixConvolutionEffect::emitCode(GrGLShaderBuilder* builder,
kFloat_GrSLType,
"Kernel",
fKernelSize.width() * fKernelSize.height());
- fTargetUni = builder->addUniform(GrGLShaderBuilder::kFragment_Visibility,
- kVec2f_GrSLType, "Target");
+ fKernelOffsetUni = builder->addUniform(GrGLShaderBuilder::kFragment_Visibility,
+ kVec2f_GrSLType, "KernelOffset");
fGainUni = builder->addUniform(GrGLShaderBuilder::kFragment_Visibility,
kFloat_GrSLType, "Gain");
fBiasUni = builder->addUniform(GrGLShaderBuilder::kFragment_Visibility,
kFloat_GrSLType, "Bias");
const char* bounds = builder->getUniformCStr(fBoundsUni);
- const char* kernelOffset = builder->getUniformCStr(fTargetUni);
+ const char* kernelOffset = builder->getUniformCStr(fKernelOffsetUni);
const char* imgInc = builder->getUniformCStr(fImageIncrementUni);
const char* kernel = builder->getUniformCStr(fKernelUni);
const char* gain = builder->getUniformCStr(fGainUni);
@@ -545,7 +545,7 @@ void GrGLMatrixConvolutionEffect::setData(const GrGLUniformManager& uman,
imageIncrement[0] = 1.0f / texture.width();
imageIncrement[1] = ySign / texture.height();
uman.set2fv(fImageIncrementUni, 1, imageIncrement);
- uman.set2fv(fTargetUni, 1, conv.kernelOffset());
+ uman.set2fv(fKernelOffsetUni, 1, conv.kernelOffset());
uman.set1fv(fKernelUni, fKernelSize.width() * fKernelSize.height(), conv.kernel());
uman.set1f(fGainUni, conv.gain());
uman.set1f(fBiasUni, conv.bias());
« no previous file with comments | « gm/matrixconvolution.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698