aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/gpu
diff options
context:
space:
mode:
authorGravatar bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-10-29 16:25:04 +0000
committerGravatar bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-10-29 16:25:04 +0000
commit484ee2a5fe47c204d9dda6acba54f9789d1cf69f (patch)
tree9c0d911b2345db347a7736f0f83710b214834b3d /include/gpu
parentae5ef113ebd7f20f1bea952a0ed9bb6d47cbda92 (diff)
Make GrEffectStage keep a const ptr (rather than non-const) to GrEffect.
R=robertphillips@google.com Review URL: https://codereview.appspot.com/6811045 git-svn-id: http://skia.googlecode.com/svn/branches/gpu_dev@6166 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'include/gpu')
-rw-r--r--include/gpu/GrEffectStage.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/gpu/GrEffectStage.h b/include/gpu/GrEffectStage.h
index 23b629a166..bf7215e536 100644
--- a/include/gpu/GrEffectStage.h
+++ b/include/gpu/GrEffectStage.h
@@ -70,7 +70,7 @@ public:
class SavedCoordChange {
private:
GrMatrix fCoordChangeMatrix;
- GR_DEBUGCODE(mutable SkAutoTUnref<GrEffect> fEffect;)
+ GR_DEBUGCODE(mutable SkAutoTUnref<const GrEffect> fEffect;)
friend class GrEffectStage;
};
@@ -123,7 +123,7 @@ public:
GrSafeSetNull(fEffect);
}
- GrEffect* setEffect(GrEffect* effect) {
+ const GrEffect* setEffect(const GrEffect* effect) {
GrAssert(0 == fSavedCoordChangeCnt);
GrSafeAssign(fEffect, effect);
fMatrix.reset();
@@ -131,7 +131,7 @@ public:
return effect;
}
- GrEffect* setEffect(GrEffect* effect, const GrMatrix& matrix) {
+ const GrEffect* setEffect(const GrEffect* effect, const GrMatrix& matrix) {
GrAssert(0 == fSavedCoordChangeCnt);
GrSafeAssign(fEffect, effect);
fMatrix = matrix;
@@ -144,7 +144,7 @@ public:
private:
GrMatrix fCoordChangeMatrix;
GrMatrix fMatrix; // TODO: remove this, store in GrEffect
- GrEffect* fEffect;
+ const GrEffect* fEffect;
GR_DEBUGCODE(mutable int fSavedCoordChangeCnt;)
};