aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkEdge.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/SkEdge.cpp')
-rw-r--r--src/core/SkEdge.cpp19
1 files changed, 3 insertions, 16 deletions
diff --git a/src/core/SkEdge.cpp b/src/core/SkEdge.cpp
index 216604b551..d91c3e6bce 100644
--- a/src/core/SkEdge.cpp
+++ b/src/core/SkEdge.cpp
@@ -172,7 +172,8 @@ static inline int diff_to_shift(SkFDot6 dx, SkFDot6 dy)
return (32 - SkCLZ(dist)) >> 1;
}
-bool SkQuadraticEdge::setQuadraticWithoutUpdate(const SkPoint pts[3], int shift) {
+int SkQuadraticEdge::setQuadratic(const SkPoint pts[3], int shift)
+{
SkFDot6 x0, y0, x1, y1, x2, y2;
{
@@ -265,13 +266,6 @@ bool SkQuadraticEdge::setQuadraticWithoutUpdate(const SkPoint pts[3], int shift)
fQLastX = SkFDot6ToFixed(x2);
fQLastY = SkFDot6ToFixed(y2);
- return true;
-}
-
-int SkQuadraticEdge::setQuadratic(const SkPoint pts[3], int shift) {
- if (!setQuadraticWithoutUpdate(pts, shift)) {
- return 0;
- }
return this->updateQuadratic();
}
@@ -338,7 +332,7 @@ static SkFDot6 cubic_delta_from_line(SkFDot6 a, SkFDot6 b, SkFDot6 c, SkFDot6 d)
return SkMax32(SkAbs32(oneThird), SkAbs32(twoThird));
}
-bool SkCubicEdge::setCubicWithoutUpdate(const SkPoint pts[4], int shift) {
+int SkCubicEdge::setCubic(const SkPoint pts[4], int shift) {
SkFDot6 x0, y0, x1, y1, x2, y2, x3, y3;
{
@@ -434,13 +428,6 @@ bool SkCubicEdge::setCubicWithoutUpdate(const SkPoint pts[4], int shift) {
fCLastX = SkFDot6ToFixed(x3);
fCLastY = SkFDot6ToFixed(y3);
- return true;
-}
-
-int SkCubicEdge::setCubic(const SkPoint pts[4], int shift) {
- if (!this->setCubicWithoutUpdate(pts, shift)) {
- return 0;
- }
return this->updateCubic();
}