Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(351)

Unified Diff: include/effects/SkDashPathEffect.h

Issue 212103010: Add asADash entry point into SkPathEffect to allow extracting Dash info from PathEffects (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Flatten Updates Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: include/effects/SkDashPathEffect.h
diff --git a/include/effects/SkDashPathEffect.h b/include/effects/SkDashPathEffect.h
index a1c548265367cd0b0eac1d963070799ac6652b5d..01c7dc4c6856f9278fc2398e7ef702de6c87d070 100644
--- a/include/effects/SkDashPathEffect.h
+++ b/include/effects/SkDashPathEffect.h
@@ -49,6 +49,8 @@ public:
const SkStrokeRec&, const SkMatrix&,
const SkRect*) const SK_OVERRIDE;
+ virtual DashType asADash(DashInfo* info) const SK_OVERRIDE;
+
virtual Factory getFactory() const SK_OVERRIDE;
static SkFlattenable* CreateProc(SkReadBuffer&);
@@ -64,8 +66,11 @@ public:
bool scaleToFit = false);
private:
+ void setInternalMembers(SkScalar phase);
+
SkScalar* fIntervals;
int32_t fCount;
+ SkScalar fPhase;
// computed from phase
SkScalar fInitialDashLength;
int32_t fInitialDashIndex;

Powered by Google App Engine
This is Rietveld 408576698