Simplify drawloopers and drawfilters. This allows the canvas to keep its
promise that const SkPaint& stay const (so we don't have bugs if a const paint
is referenced from two threads in pictures)
git-svn-id: http://skia.googlecode.com/svn/trunk@1074 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/include/effects/SkBlurDrawLooper.h b/include/effects/SkBlurDrawLooper.h
index 101d24e..846048c 100644
--- a/include/effects/SkBlurDrawLooper.h
+++ b/include/effects/SkBlurDrawLooper.h
@@ -48,9 +48,8 @@
virtual ~SkBlurDrawLooper();
// overrides from SkDrawLooper
- virtual void init(SkCanvas*, SkPaint*);
- virtual bool next();
- virtual void restore();
+ virtual void init(SkCanvas*);
+ virtual bool next(SkCanvas*, SkPaint* paint);
static SkFlattenable* CreateProc(SkFlattenableReadBuffer& buffer) {
return SkNEW_ARGS(SkBlurDrawLooper, (buffer));
@@ -64,14 +63,10 @@
virtual Factory getFactory() { return CreateProc; }
private:
- SkCanvas* fCanvas;
- SkPaint* fPaint;
SkMaskFilter* fBlur;
SkColorFilter* fColorFilter;
SkScalar fDx, fDy;
SkColor fBlurColor;
- SkColor fSavedColor; // remember the original
- int fSaveCount;
uint32_t fBlurFlags;
enum State {