aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkEdgeBuilder.h
diff options
context:
space:
mode:
authorGravatar stephana <stephana@google.com>2016-10-04 09:56:08 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-10-04 09:56:08 -0700
commitd36baa7a4a5ae3cc94cc4a45379f55658f80c0a6 (patch)
treed70c97848f983c8f8d6bac4e120784fbc47221c5 /src/core/SkEdgeBuilder.h
parent7795822807478143120c33228b68d2ab3918af2c (diff)
Revert of Analytic AntiAlias for Convex Shapes (patchset #14 id:260001 of https://codereview.chromium.org/2221103002/ )
Reason for revert: Breaks iOS build. Original issue's description: > Implement AnalyticAA for convex shapes. > > Design doc: go/analyticAA > > A performance test can be found here: https://docs.google.com/a/google.com/spreadsheets/d/1n9LSjFzrQzx0hovFddWey0GSMXNRjl1oFuSypMlHWZk/edit?usp=sharing > > Our best case is filling big triangles, which according to our experiment has ~2.9x speedup. Our worst case is filling small ovals/circles, which has a ~1.06x slowdown. > > To see how our new algorithm changes the DM images, see: https://x20web.corp.google.com/~liyuqian/dmdiff/index.html > The most significant changes are in convexpaths and analytic_antialias_convex > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2221103002 > > Committed: https://skia.googlesource.com/skia/+/7795822807478143120c33228b68d2ab3918af2c TBR=reed@google.com,caryclark@google.com,liyuqian@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review-Url: https://codereview.chromium.org/2388213003
Diffstat (limited to 'src/core/SkEdgeBuilder.h')
-rw-r--r--src/core/SkEdgeBuilder.h18
1 files changed, 5 insertions, 13 deletions
diff --git a/src/core/SkEdgeBuilder.h b/src/core/SkEdgeBuilder.h
index 097e796de7..59f62870e7 100644
--- a/src/core/SkEdgeBuilder.h
+++ b/src/core/SkEdgeBuilder.h
@@ -12,7 +12,6 @@
#include "SkTDArray.h"
struct SkEdge;
-struct SkAnalyticEdge;
class SkEdgeClipper;
class SkPath;
@@ -22,11 +21,9 @@ public:
// returns the number of built edges. The array of those edge pointers
// is returned from edgeList().
- int build(const SkPath& path, const SkIRect* clip, int shiftUp, bool clipToTheRight,
- bool analyticAA = false);
+ int build(const SkPath& path, const SkIRect* clip, int shiftUp, bool clipToTheRight);
- SkEdge** edgeList() { return (SkEdge**)fEdgeList; }
- SkAnalyticEdge** analyticEdgeList() { return (SkAnalyticEdge**)fEdgeList; }
+ SkEdge** edgeList() { return fEdgeList; }
private:
enum Combine {
@@ -35,15 +32,11 @@ private:
kTotal_Combine
};
- Combine CombineVertical(const SkEdge* edge, SkEdge* last);
- Combine CombineVertical(const SkAnalyticEdge* edge, SkAnalyticEdge* last);
+ static Combine CombineVertical(const SkEdge* edge, SkEdge* last);
Combine checkVertical(const SkEdge* edge, SkEdge** edgePtr);
- Combine checkVertical(const SkAnalyticEdge* edge, SkAnalyticEdge** edgePtr);
- bool vertical_line(const SkEdge* edge);
- bool vertical_line(const SkAnalyticEdge* edge);
SkChunkAlloc fAlloc;
- SkTDArray<void*> fList;
+ SkTDArray<SkEdge*> fList;
/*
* If we're in general mode, we allcoate the pointers in fList, and this
@@ -51,10 +44,9 @@ private:
* empty, as we will have preallocated room for the pointers in fAlloc's
* block, and fEdgeList will point into that.
*/
- void** fEdgeList;
+ SkEdge** fEdgeList;
int fShiftUp;
- bool fAnalyticAA;
public:
void addLine(const SkPoint pts[]);