Index: src/gpu/effects/GrDistanceFieldTextureEffect.h |
diff --git a/src/gpu/effects/GrCustomCoordsTextureEffect.h b/src/gpu/effects/GrDistanceFieldTextureEffect.h |
old mode 100644 |
new mode 100755 |
similarity index 63% |
copy from src/gpu/effects/GrCustomCoordsTextureEffect.h |
copy to src/gpu/effects/GrDistanceFieldTextureEffect.h |
index 1caecf2f6d6e96285feb6ed618c4d7d68e792456..34d4ae536347e07691de69c52ece3cb67cef3834 |
--- a/src/gpu/effects/GrCustomCoordsTextureEffect.h |
+++ b/src/gpu/effects/GrDistanceFieldTextureEffect.h |
@@ -5,38 +5,39 @@ |
* found in the LICENSE file. |
*/ |
-#ifndef GrCustomCoordsTextureEffect_DEFINED |
-#define GrCustomCoordsTextureEffect_DEFINED |
+#ifndef GrDistanceFieldTextureEffect_DEFINED |
+#define GrDistanceFieldTextureEffect_DEFINED |
#include "GrEffect.h" |
#include "GrVertexEffect.h" |
-class GrGLCustomCoordsTextureEffect; |
+class GrGLDistanceFieldTextureEffect; |
/** |
- * The output color of this effect is a modulation of the input color and a sample from a texture. |
+ * The output color of this effect is a modulation of the input color and a sample from a |
+ * distance field texture (using a smoothed step function near 0.5). |
* It allows explicit specification of the filtering and wrap modes (GrTextureParams). The input |
* coords are a custom attribute. |
*/ |
-class GrCustomCoordsTextureEffect : public GrVertexEffect { |
+class GrDistanceFieldTextureEffect : public GrVertexEffect { |
public: |
static GrEffectRef* Create(GrTexture* tex, const GrTextureParams& p) { |
- AutoEffectUnref effect(SkNEW_ARGS(GrCustomCoordsTextureEffect, (tex, p))); |
+ AutoEffectUnref effect(SkNEW_ARGS(GrDistanceFieldTextureEffect, (tex, p))); |
return CreateEffectRef(effect); |
} |
- virtual ~GrCustomCoordsTextureEffect() {} |
+ virtual ~GrDistanceFieldTextureEffect() {} |
static const char* Name() { return "Texture"; } |
virtual void getConstantColorComponents(GrColor* color, uint32_t* validFlags) const SK_OVERRIDE; |
- typedef GrGLCustomCoordsTextureEffect GLEffect; |
+ typedef GrGLDistanceFieldTextureEffect GLEffect; |
virtual const GrBackendEffectFactory& getFactory() const SK_OVERRIDE; |
private: |
- GrCustomCoordsTextureEffect(GrTexture* texture, const GrTextureParams& params); |
+ GrDistanceFieldTextureEffect(GrTexture* texture, const GrTextureParams& params); |
virtual bool onIsEqual(const GrEffect& other) const SK_OVERRIDE; |