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

Unified Diff: src/gpu/GrPath.cpp

Issue 1461913002: Revert of Fix NVPR assert for equivalent ovals (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Created 5 years, 1 month 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 | « src/gpu/GrPath.h ('k') | tests/GpuDrawPathTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrPath.cpp
diff --git a/src/gpu/GrPath.cpp b/src/gpu/GrPath.cpp
index 8ac356dd2d2f8845c347987754b77c5256041a7c..4e1119dfbb45036f2a38cd9135006454364c29e2 100644
--- a/src/gpu/GrPath.cpp
+++ b/src/gpu/GrPath.cpp
@@ -36,8 +36,7 @@
inline static bool compute_key_for_oval_path(const SkPath& path, const GrStrokeInfo& stroke,
GrUniqueKey* key) {
SkRect rect;
- // Point order is significant when dashing, so we cannot devolve to a rect key.
- if (stroke.isDashed() || !path.isOval(&rect)) {
+ if (!path.isOval(&rect)) {
return false;
}
static_assert((sizeof(rect) % sizeof(uint32_t)) == 0 && sizeof(rect) > sizeof(uint32_t),
@@ -172,20 +171,3 @@
*outIsVolatile = path.isVolatile();
}
-#ifdef SK_DEBUG
-bool GrPath::isEqualTo(const SkPath& path, const GrStrokeInfo& stroke) const {
- if (!fStroke.hasEqualEffect(stroke)) {
- return false;
- }
-
- // We treat same-rect ovals as identical - but only when not dashing.
- SkRect ovalBounds;
- if (!fStroke.isDashed() && fSkPath.isOval(&ovalBounds)) {
- SkRect otherOvalBounds;
- return path.isOval(&otherOvalBounds) && ovalBounds == otherOvalBounds;
- }
-
- return fSkPath == path;
-}
-#endif
-
« no previous file with comments | « src/gpu/GrPath.h ('k') | tests/GpuDrawPathTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698