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

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

Issue 365853002: Rename GrGLUniformManager to GrGLProgramResourceManager (Closed) Base URL: https://skia.googlesource.com/skia.git@02-path-program-fragment
Patch Set: rebase Created 6 years, 5 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
Index: src/gpu/effects/GrConvexPolyEffect.cpp
diff --git a/src/gpu/effects/GrConvexPolyEffect.cpp b/src/gpu/effects/GrConvexPolyEffect.cpp
index 11109f7ed837c0bddd695998b21f84d4e4f09a73..50eb7af6660ad3e402aa1b97a505e182960693ab 100644
--- a/src/gpu/effects/GrConvexPolyEffect.cpp
+++ b/src/gpu/effects/GrConvexPolyEffect.cpp
@@ -99,10 +99,10 @@ public:
static inline void GenKey(const GrDrawEffect&, const GrGLCaps&, GrEffectKeyBuilder*);
- virtual void setData(const GrGLUniformManager&, const GrDrawEffect&) SK_OVERRIDE;
+ virtual void setData(const GrGLProgramResourceManager&, const GrDrawEffect&) SK_OVERRIDE;
private:
- GrGLUniformManager::UniformHandle fRectUniform;
+ GrGLProgramResourceManager::UniformHandle fRectUniform;
SkRect fPrevRect;
typedef GrGLEffect INHERITED;
};
@@ -155,11 +155,11 @@ void GLAARectEffect::emitCode(GrGLShaderBuilder* builder,
(GrGLSLExpr4(inputColor) * GrGLSLExpr1("alpha")).c_str());
}
-void GLAARectEffect::setData(const GrGLUniformManager& uman, const GrDrawEffect& drawEffect) {
+void GLAARectEffect::setData(const GrGLProgramResourceManager& prman, const GrDrawEffect& drawEffect) {
const AARectEffect& aare = drawEffect.castEffect<AARectEffect>();
const SkRect& rect = aare.getRect();
if (rect != fPrevRect) {
- uman.set4f(fRectUniform, rect.fLeft + 0.5f, rect.fTop + 0.5f,
+ prman.set4f(fRectUniform, rect.fLeft + 0.5f, rect.fTop + 0.5f,
rect.fRight - 0.5f, rect.fBottom - 0.5f);
fPrevRect = rect;
}
@@ -191,10 +191,10 @@ public:
static inline void GenKey(const GrDrawEffect&, const GrGLCaps&, GrEffectKeyBuilder*);
- virtual void setData(const GrGLUniformManager&, const GrDrawEffect&) SK_OVERRIDE;
+ virtual void setData(const GrGLProgramResourceManager&, const GrDrawEffect&) SK_OVERRIDE;
private:
- GrGLUniformManager::UniformHandle fEdgeUniform;
+ GrGLProgramResourceManager::UniformHandle fEdgeUniform;
SkScalar fPrevEdges[3 * GrConvexPolyEffect::kMaxEdges];
typedef GrGLEffect INHERITED;
};
@@ -246,11 +246,11 @@ void GrGLConvexPolyEffect::emitCode(GrGLShaderBuilder* builder,
(GrGLSLExpr4(inputColor) * GrGLSLExpr1("alpha")).c_str());
}
-void GrGLConvexPolyEffect::setData(const GrGLUniformManager& uman, const GrDrawEffect& drawEffect) {
+void GrGLConvexPolyEffect::setData(const GrGLProgramResourceManager& prman, const GrDrawEffect& drawEffect) {
const GrConvexPolyEffect& cpe = drawEffect.castEffect<GrConvexPolyEffect>();
size_t byteSize = 3 * cpe.getEdgeCount() * sizeof(SkScalar);
if (0 != memcmp(fPrevEdges, cpe.getEdges(), byteSize)) {
- uman.set3fv(fEdgeUniform, cpe.getEdgeCount(), cpe.getEdges());
+ prman.set3fv(fEdgeUniform, cpe.getEdgeCount(), cpe.getEdges());
memcpy(fPrevEdges, cpe.getEdges(), byteSize);
}
}

Powered by Google App Engine
This is Rietveld 408576698