aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/pathops/SkReduceOrder.h
diff options
context:
space:
mode:
authorGravatar caryclark <caryclark@google.com>2016-09-23 05:47:20 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-09-23 05:47:20 -0700
commit27c015dfcf4e2b8fb1abe327cc40204e2a4f452a (patch)
tree1fab83dc8286a4f1900871c69e80e624203e7e3e /src/pathops/SkReduceOrder.h
parent5a9c2f110e4f1a78d9bfedcf708168909706d7fd (diff)
split tight quads and conics
Tight quads and conics may nearly fold over on themselves, confusing coincidence against other curves. Split them at their max curvature early on to avoid complicating later logic. TBR=reed@google.com BUG=skia:5131 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2357353002 Review-Url: https://codereview.chromium.org/2357353002
Diffstat (limited to 'src/pathops/SkReduceOrder.h')
-rw-r--r--src/pathops/SkReduceOrder.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/pathops/SkReduceOrder.h b/src/pathops/SkReduceOrder.h
index e9e4090deb..7efb71d4fe 100644
--- a/src/pathops/SkReduceOrder.h
+++ b/src/pathops/SkReduceOrder.h
@@ -11,6 +11,8 @@
#include "SkPathOpsLine.h"
#include "SkPathOpsQuad.h"
+struct SkConic;
+
union SkReduceOrder {
enum Quadratics {
kNo_Quadratics,
@@ -21,7 +23,7 @@ union SkReduceOrder {
int reduce(const SkDLine& line);
int reduce(const SkDQuad& quad);
- static SkPath::Verb Conic(const SkPoint pts[3], SkScalar weight, SkPoint* reducePts);
+ static SkPath::Verb Conic(const SkConic& conic, SkPoint* reducePts);
static SkPath::Verb Cubic(const SkPoint pts[4], SkPoint* reducePts);
static SkPath::Verb Quad(const SkPoint pts[3], SkPoint* reducePts);