http://www.w3.org/TR/SVG/filters.html#feTurbulenceElement
*/
class SK_API SkPerlinNoiseShader : public SkShader {
- struct PaintingData;
public:
struct StitchData;
+ struct PaintingData;
/**
* About the noise types : the difference between the 2 is just minor tweaks to the algorithm,
class PerlinNoiseShaderContext : public SkShader::Context {
public:
PerlinNoiseShaderContext(const SkPerlinNoiseShader& shader, const ContextRec&);
- virtual ~PerlinNoiseShaderContext() {}
+ virtual ~PerlinNoiseShaderContext();
virtual void shadeSpan(int x, int y, SkPMColor[], int count) SK_OVERRIDE;
virtual void shadeSpan16(int x, int y, uint16_t[], int count) SK_OVERRIDE;
private:
SkPMColor shade(const SkPoint& point, StitchData& stitchData) const;
SkScalar calculateTurbulenceValueForPoint(
- int channel, const PaintingData& paintingData,
+ int channel,
StitchData& stitchData, const SkPoint& point) const;
- SkScalar noise2D(int channel, const PaintingData& paintingData,
+ SkScalar noise2D(int channel,
const StitchData& stitchData, const SkPoint& noiseVector) const;
SkMatrix fMatrix;
+ PaintingData* fPaintingData;
typedef SkShader::Context INHERITED;
};
virtual bool asNewEffect(GrContext* context, const SkPaint&, const SkMatrix*, GrColor*,
- GrEffectRef**) const SK_OVERRIDE;
+ GrEffect**) const SK_OVERRIDE;
SK_TO_STRING_OVERRIDE()
SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkPerlinNoiseShader)
/*const*/ SkISize fTileSize;
/*const*/ bool fStitchTiles;
- PaintingData* fPaintingData;
-
typedef SkShader INHERITED;
};