aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar bsalomon <bsalomon@google.com>2014-10-15 18:34:46 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2014-10-15 18:34:46 -0700
commitf2765410ba8adfe934b8d92e52ccc2a847934c61 (patch)
tree171303dc7d83d840cbdb701ba1164734a77f480d /include
parent498bc5f03685c48bee1bfa6b61fb62cd1d2ade50 (diff)
Last round of effect->processor (for now)
R=joshualitt@google.com Review URL: https://codereview.chromium.org/659803005
Diffstat (limited to 'include')
-rw-r--r--include/gpu/GrBackendProcessorFactory.h16
-rw-r--r--include/gpu/GrCoordTransform.h18
2 files changed, 17 insertions, 17 deletions
diff --git a/include/gpu/GrBackendProcessorFactory.h b/include/gpu/GrBackendProcessorFactory.h
index 6544b307a7..3e4f133147 100644
--- a/include/gpu/GrBackendProcessorFactory.h
+++ b/include/gpu/GrBackendProcessorFactory.h
@@ -111,22 +111,22 @@ public:
* processor's key. This allows keys generated by getGLProcessorKey() to only be unique within a
* GrProcessor subclass and not necessarily across subclasses.
*/
- uint32_t effectClassID() const { return fEffectClassID; }
+ uint32_t classID() const { return fProcessorClassID; }
protected:
- GrBackendProcessorFactory() : fEffectClassID(GenID()) {}
+ GrBackendProcessorFactory() : fProcessorClassID(GenClassID()) {}
virtual ~GrBackendProcessorFactory() {}
private:
enum {
- kIllegalEffectClassID = 0,
+ kIllegalProcessorClassID = 0,
};
- static uint32_t GenID() {
- // fCurrEffectClassID has been initialized to kIllegalEffectClassID. The
+ static uint32_t GenClassID() {
+ // fCurrProcessorClassID has been initialized to kIllegalProcessorClassID. The
// atomic inc returns the old value not the incremented value. So we add
// 1 to the returned value.
- uint32_t id = static_cast<uint32_t>(sk_atomic_inc(&fCurrEffectClassID)) + 1;
+ uint32_t id = static_cast<uint32_t>(sk_atomic_inc(&fCurrProcessorClassID)) + 1;
if (!id) {
SkFAIL("This should never wrap as it should only be called once for each GrProcessor "
"subclass.");
@@ -134,8 +134,8 @@ private:
return id;
}
- const uint32_t fEffectClassID;
- static int32_t fCurrEffectClassID;
+ const uint32_t fProcessorClassID;
+ static int32_t fCurrProcessorClassID;
};
class GrFragmentProcessor;
diff --git a/include/gpu/GrCoordTransform.h b/include/gpu/GrCoordTransform.h
index 718bbe774f..db71ff1158 100644
--- a/include/gpu/GrCoordTransform.h
+++ b/include/gpu/GrCoordTransform.h
@@ -41,13 +41,13 @@ enum GrCoordSet {
*/
class GrCoordTransform : SkNoncopyable {
public:
- GrCoordTransform() { SkDEBUGCODE(fInEffect = false); }
+ GrCoordTransform() { SkDEBUGCODE(fInProcessor = false); }
/**
* Create a transformation that maps [0, 1] to a texture's boundaries.
*/
GrCoordTransform(GrCoordSet sourceCoords, const GrTexture* texture) {
- SkDEBUGCODE(fInEffect = false);
+ SkDEBUGCODE(fInProcessor = false);
this->reset(sourceCoords, texture);
}
@@ -57,25 +57,25 @@ public:
* coord convention.
*/
GrCoordTransform(GrCoordSet sourceCoords, const SkMatrix& m, const GrTexture* texture = NULL) {
- SkDEBUGCODE(fInEffect = false);
+ SkDEBUGCODE(fInProcessor = false);
this->reset(sourceCoords, m, texture);
}
void reset(GrCoordSet sourceCoords, const GrTexture* texture) {
- SkASSERT(!fInEffect);
+ SkASSERT(!fInProcessor);
SkASSERT(texture);
this->reset(sourceCoords, MakeDivByTextureWHMatrix(texture), texture);
}
void reset(GrCoordSet sourceCoords, const SkMatrix& m, const GrTexture* texture = NULL) {
- SkASSERT(!fInEffect);
+ SkASSERT(!fInProcessor);
fSourceCoords = sourceCoords;
fMatrix = m;
fReverseY = texture && kBottomLeft_GrSurfaceOrigin == texture->origin();
}
GrCoordTransform& operator= (const GrCoordTransform& other) {
- SkASSERT(!fInEffect);
+ SkASSERT(!fInProcessor);
fSourceCoords = other.fSourceCoords;
fMatrix = other.fMatrix;
fReverseY = other.fReverseY;
@@ -87,7 +87,7 @@ public:
* effect, since effects are immutable.
*/
SkMatrix* accessMatrix() {
- SkASSERT(!fInEffect);
+ SkASSERT(!fInProcessor);
return &fMatrix;
}
@@ -119,9 +119,9 @@ private:
#ifdef SK_DEBUG
public:
- void setInEffect() const { fInEffect = true; }
+ void setInProcessor() const { fInProcessor = true; }
private:
- mutable bool fInEffect;
+ mutable bool fInProcessor;
#endif
};