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

Unified Diff: src/core/SkPath.cpp

Issue 2012233002: Make SkPath::isOval() and SkPath::isRRect return the orientation and starting index. (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: record mod'ed start indices Created 4 years, 7 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
« no previous file with comments | « include/core/SkPathRef.h ('k') | src/core/SkPathRef.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkPath.cpp
diff --git a/src/core/SkPath.cpp b/src/core/SkPath.cpp
index fbda7e8772f6770ee71de6748869f1e049d21a18..03bc3170d832015eb12614df5baffc5e90250e2e 100644
--- a/src/core/SkPath.cpp
+++ b/src/core/SkPath.cpp
@@ -1161,7 +1161,7 @@ void SkPath::addRRect(const SkRRect &rrect, Direction dir, unsigned startIndex)
this->close();
SkPathRef::Editor ed(&fPathRef);
- ed.setIsRRect(isRRect);
+ ed.setIsRRect(isRRect, dir, startIndex % 8);
SkASSERT(this->countVerbs() == initialVerbCount + kVerbs);
}
@@ -1259,7 +1259,7 @@ void SkPath::addOval(const SkRect &oval, Direction dir, unsigned startPointIndex
SkPathRef::Editor ed(&fPathRef);
- ed.setIsOval(isOval);
+ ed.setIsOval(isOval, kCCW_Direction == dir, startPointIndex % 4);
}
void SkPath::addCircle(SkScalar x, SkScalar y, SkScalar r, Direction dir) {
« no previous file with comments | « include/core/SkPathRef.h ('k') | src/core/SkPathRef.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698