diff options
author | Derek Sollenberger <djsollen@google.com> | 2011-02-24 11:04:57 -0500 |
---|---|---|
committer | Derek Sollenberger <djsollen@google.com> | 2011-02-24 13:10:51 -0500 |
commit | 71531ca1f484da5837be8017a0c83e5bff701587 (patch) | |
tree | 36512f8dbc615cd9e80b20eff47c0400eb1aa52b /include/core/SkCanvas.h | |
parent | 7157c81e3a5c916ab44a02273b140e1cd8a6d1bb (diff) | |
download | external_skia-71531ca1f484da5837be8017a0c83e5bff701587.zip external_skia-71531ca1f484da5837be8017a0c83e5bff701587.tar.gz external_skia-71531ca1f484da5837be8017a0c83e5bff701587.tar.bz2 |
Skia Merge (revision 842)
This merge picks up the fixed width font updates and improved
blur code from the Skia repository.
Change-Id: Iad2301a353c31da27ca214527cf4ed8f24641749
Diffstat (limited to 'include/core/SkCanvas.h')
-rw-r--r-- | include/core/SkCanvas.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/include/core/SkCanvas.h b/include/core/SkCanvas.h index b2a9fa9..103507c 100644 --- a/include/core/SkCanvas.h +++ b/include/core/SkCanvas.h @@ -20,6 +20,7 @@ #include "SkTypes.h" #include "SkBitmap.h" #include "SkDeque.h" +#include "SkClipStack.h" #include "SkPaint.h" #include "SkRefCnt.h" #include "SkPath.h" @@ -789,6 +790,7 @@ protected: private: class MCRec; + SkClipStack fClipStack; SkDeque fMCStack; // points to top of stack MCRec* fMCRec; @@ -848,6 +850,23 @@ private: SkMatrix fExternalMatrix, fExternalInverse; bool fUseExternalMatrix; + + class AutoValidateClip : ::SkNoncopyable { + public: + explicit AutoValidateClip(SkCanvas* canvas) : fCanvas(canvas) { + fCanvas->validateClip(); + } + ~AutoValidateClip() { fCanvas->validateClip(); } + + private: + const SkCanvas* fCanvas; + }; + +#ifdef SK_DEBUG + void validateClip() const; +#else + void validateClip() const {} +#endif }; /** Stack helper class to automatically call restoreToCount() on the canvas |