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

Unified Diff: src/gpu/effects/GrRRectEffect.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
« no previous file with comments | « src/gpu/effects/GrOvalEffect.cpp ('k') | src/gpu/effects/GrTextureDomain.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/effects/GrRRectEffect.cpp
diff --git a/src/gpu/effects/GrRRectEffect.cpp b/src/gpu/effects/GrRRectEffect.cpp
index 277f6df1a7df39b49440b1451b4edb9ad169214c..5a2b0c3d59d75a5944794b74c489fe31efb55673 100644
--- a/src/gpu/effects/GrRRectEffect.cpp
+++ b/src/gpu/effects/GrRRectEffect.cpp
@@ -144,12 +144,12 @@ public:
static inline void GenKey(const GrDrawEffect&, const GrGLCaps&, GrEffectKeyBuilder*);
- virtual void setData(const GrGLUniformManager&, const GrDrawEffect&) SK_OVERRIDE;
+ virtual void setData(const GrGLProgramDataManager&, const GrDrawEffect&) SK_OVERRIDE;
private:
- GrGLUniformManager::UniformHandle fInnerRectUniform;
- GrGLUniformManager::UniformHandle fRadiusPlusHalfUniform;
- SkRRect fPrevRRect;
+ GrGLProgramDataManager::UniformHandle fInnerRectUniform;
+ GrGLProgramDataManager::UniformHandle fRadiusPlusHalfUniform;
+ SkRRect fPrevRRect;
typedef GrGLEffect INHERITED;
};
@@ -298,7 +298,7 @@ void GLCircularRRectEffect::GenKey(const GrDrawEffect& drawEffect, const GrGLCap
b->add32((crre.getCircularCornerFlags() << 3) | crre.getEdgeType());
}
-void GLCircularRRectEffect::setData(const GrGLUniformManager& uman,
+void GLCircularRRectEffect::setData(const GrGLProgramDataManager& pdman,
const GrDrawEffect& drawEffect) {
const CircularRRectEffect& crre = drawEffect.castEffect<CircularRRectEffect>();
const SkRRect& rrect = crre.getRRect();
@@ -371,8 +371,8 @@ void GLCircularRRectEffect::setData(const GrGLUniformManager& uman,
default:
SkFAIL("Should have been one of the above cases.");
}
- uman.set4f(fInnerRectUniform, rect.fLeft, rect.fTop, rect.fRight, rect.fBottom);
- uman.set1f(fRadiusPlusHalfUniform, radius + 0.5f);
+ pdman.set4f(fInnerRectUniform, rect.fLeft, rect.fTop, rect.fRight, rect.fBottom);
+ pdman.set1f(fRadiusPlusHalfUniform, radius + 0.5f);
fPrevRRect = rrect;
}
}
@@ -496,12 +496,12 @@ public:
static inline void GenKey(const GrDrawEffect&, const GrGLCaps&, GrEffectKeyBuilder*);
- virtual void setData(const GrGLUniformManager&, const GrDrawEffect&) SK_OVERRIDE;
+ virtual void setData(const GrGLProgramDataManager&, const GrDrawEffect&) SK_OVERRIDE;
private:
- GrGLUniformManager::UniformHandle fInnerRectUniform;
- GrGLUniformManager::UniformHandle fInvRadiiSqdUniform;
- SkRRect fPrevRRect;
+ GrGLProgramDataManager::UniformHandle fInnerRectUniform;
+ GrGLProgramDataManager::UniformHandle fInvRadiiSqdUniform;
+ SkRRect fPrevRRect;
typedef GrGLEffect INHERITED;
};
@@ -593,7 +593,7 @@ void GLEllipticalRRectEffect::GenKey(const GrDrawEffect& drawEffect, const GrGLC
b->add32(erre.getRRect().getType() | erre.getEdgeType() << 3);
}
-void GLEllipticalRRectEffect::setData(const GrGLUniformManager& uman,
+void GLEllipticalRRectEffect::setData(const GrGLProgramDataManager& pdman,
const GrDrawEffect& drawEffect) {
const EllipticalRRectEffect& erre = drawEffect.castEffect<EllipticalRRectEffect>();
const SkRRect& rrect = erre.getRRect();
@@ -605,7 +605,7 @@ void GLEllipticalRRectEffect::setData(const GrGLUniformManager& uman,
switch (erre.getRRect().getType()) {
case SkRRect::kSimple_Type:
rect.inset(r0.fX, r0.fY);
- uman.set2f(fInvRadiiSqdUniform, 1.f / (r0.fX * r0.fX),
+ pdman.set2f(fInvRadiiSqdUniform, 1.f / (r0.fX * r0.fX),
1.f / (r0.fY * r0.fY));
break;
case SkRRect::kNinePatch_Type: {
@@ -616,7 +616,7 @@ void GLEllipticalRRectEffect::setData(const GrGLUniformManager& uman,
rect.fTop += r0.fY;
rect.fRight -= r1.fX;
rect.fBottom -= r1.fY;
- uman.set4f(fInvRadiiSqdUniform, 1.f / (r0.fX * r0.fX),
+ pdman.set4f(fInvRadiiSqdUniform, 1.f / (r0.fX * r0.fX),
1.f / (r0.fY * r0.fY),
1.f / (r1.fX * r1.fX),
1.f / (r1.fY * r1.fY));
@@ -625,7 +625,7 @@ void GLEllipticalRRectEffect::setData(const GrGLUniformManager& uman,
default:
SkFAIL("RRect should always be simple or nine-patch.");
}
- uman.set4f(fInnerRectUniform, rect.fLeft, rect.fTop, rect.fRight, rect.fBottom);
+ pdman.set4f(fInnerRectUniform, rect.fLeft, rect.fTop, rect.fRight, rect.fBottom);
fPrevRRect = rrect;
}
}
« no previous file with comments | « src/gpu/effects/GrOvalEffect.cpp ('k') | src/gpu/effects/GrTextureDomain.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698