Port an upstream Skia fix.

This commit is contained in:
Fedor 2019-06-12 13:44:10 +03:00
parent 96e20cdf0e
commit 37d1650b5a
1 changed files with 3 additions and 2 deletions

View File

@ -1620,10 +1620,10 @@ void SkPath::reverseAddPath(const SkPath& srcPath) {
src = tmp.set(srcPath);
}
SkPathRef::Editor ed(&fPathRef, src->fPathRef->countPoints(), src->fPathRef->countVerbs());
SkPathRef::Editor ed(&fPathRef, src->countPoints(), src->countVerbs());
const SkPoint* pts = src->fPathRef->pointsEnd();
// we will iterator through src's verbs backwards
// we will iterate through src's verbs backwards
const uint8_t* verbs = src->fPathRef->verbsMemBegin(); // points at the last verb
const uint8_t* verbsEnd = src->fPathRef->verbs(); // points just past the first verb
const SkScalar* conicWeights = src->fPathRef->conicWeightsEnd();
@ -1743,6 +1743,7 @@ void SkPath::transform(const SkMatrix& matrix, SkPath* dst) const {
SkPathRef::CreateTransformedCopy(&dst->fPathRef, *fPathRef.get(), matrix);
if (this != dst) {
dst->fLastMoveToIndex = fLastMoveToIndex;
dst->fFillType = fFillType;
dst->fConvexity = kUnknown_Convexity;
dst->fIsVolatile = fIsVolatile;