| Index: src/gpu/GrStrokeInfo.h
|
| diff --git a/src/gpu/GrStrokeInfo.h b/src/gpu/GrStrokeInfo.h
|
| index dd942c52e96be8ba39fd2f1f3e14c20cd80bdd87..f008dc6a5d27183cb7da349a0cc22daddd21b9ba 100644
|
| --- a/src/gpu/GrStrokeInfo.h
|
| +++ b/src/gpu/GrStrokeInfo.h
|
| @@ -38,7 +38,6 @@ public:
|
| this->init(paint);
|
| }
|
|
|
| -
|
| explicit GrStrokeInfo(const SkPaint& paint) :
|
| fStroke(paint), fDashType(SkPathEffect::kNone_DashType) {
|
| this->init(paint);
|
| @@ -78,6 +77,24 @@ public:
|
| return false;
|
| }
|
|
|
| + /*
|
| + * Like the above, but sets with an explicit SkPathEffect::DashInfo
|
| + */
|
| + bool setDashInfo(const SkPathEffect::DashInfo& info) {
|
| + if (!fStroke.isFillStyle()) {
|
| + SkASSERT(!fStroke.isFillStyle());
|
| + fDashInfo.fCount = info.fCount;
|
| + fDashInfo.fPhase = info.fPhase;
|
| + fIntervals.reset(info.fCount);
|
| + for (int i = 0; i < info.fCount; i++) {
|
| + fIntervals[i] = info.fIntervals[i];
|
| + }
|
| + fDashInfo.fIntervals = fIntervals.get();
|
| + return true;
|
| + }
|
| + return false;
|
| + }
|
| +
|
| bool isDashed() const {
|
| return (!fStroke.isFillStyle() && SkPathEffect::kDash_DashType == fDashType);
|
| }
|
|
|