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

Unified Diff: src/effects/SkLightingImageFilter.cpp

Issue 22340010: Refactor GrGLUniformManager::UniformHandle to initialize itself by default (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: description Created 7 years, 4 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/effects/SkColorMatrixFilter.cpp ('k') | src/effects/SkMagnifierImageFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/SkLightingImageFilter.cpp
diff --git a/src/effects/SkLightingImageFilter.cpp b/src/effects/SkLightingImageFilter.cpp
index 7a74f73624bc89411c12d79c8e149417f2e50852..ccb1dc5127357da4df535069bd3af6d8a1b2c247 100644
--- a/src/effects/SkLightingImageFilter.cpp
+++ b/src/effects/SkLightingImageFilter.cpp
@@ -25,7 +25,6 @@ class GrGLSpecularLightingEffect;
// For brevity
typedef GrGLUniformManager::UniformHandle UniformHandle;
-static const UniformHandle kInvalidUniformHandle = GrGLUniformManager::kInvalidUniformHandle;
#endif
namespace {
@@ -1150,8 +1149,6 @@ GrEffectRef* GrDiffuseLightingEffect::TestCreate(SkMWCRandom* random,
GrGLLightingEffect::GrGLLightingEffect(const GrBackendEffectFactory& factory,
const GrDrawEffect& drawEffect)
: INHERITED(factory)
- , fImageIncrementUni(kInvalidUniformHandle)
- , fSurfaceScaleUni(kInvalidUniformHandle)
, fEffectMatrix(drawEffect.castEffect<GrLightingEffect>().coordsType()) {
const GrLightingEffect& m = drawEffect.castEffect<GrLightingEffect>();
fLight = m.light()->createGLLight();
@@ -1294,8 +1291,7 @@ void GrGLLightingEffect::setData(const GrGLUniformManager& uman,
GrGLDiffuseLightingEffect::GrGLDiffuseLightingEffect(const GrBackendEffectFactory& factory,
const GrDrawEffect& drawEffect)
- : INHERITED(factory, drawEffect)
- , fKDUni(kInvalidUniformHandle) {
+ : INHERITED(factory, drawEffect) {
}
void GrGLDiffuseLightingEffect::emitLightFunc(GrGLShaderBuilder* builder, SkString* funcName) {
@@ -1372,9 +1368,7 @@ GrEffectRef* GrSpecularLightingEffect::TestCreate(SkMWCRandom* random,
GrGLSpecularLightingEffect::GrGLSpecularLightingEffect(const GrBackendEffectFactory& factory,
const GrDrawEffect& drawEffect)
- : GrGLLightingEffect(factory, drawEffect)
- , fKSUni(kInvalidUniformHandle)
- , fShininessUni(kInvalidUniformHandle) {
+ : INHERITED(factory, drawEffect) {
}
void GrGLSpecularLightingEffect::emitLightFunc(GrGLShaderBuilder* builder, SkString* funcName) {
« no previous file with comments | « src/effects/SkColorMatrixFilter.cpp ('k') | src/effects/SkMagnifierImageFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698