diff options
author | 2015-04-15 14:38:09 -0700 | |
---|---|---|
committer | 2015-04-15 14:38:09 -0700 | |
commit | 639a82855b94b93c4fa45560e67df8ec4a8bbb3a (patch) | |
tree | 6a640af81f07013b7ae04eef650f557228d24480 /src/core/SkGeometry.h | |
parent | bed83a66f5fa5821a3a08da32157a6155960b15e (diff) |
Revert of Speeup hairline curves (quads and cubics) (patchset #7 id:120001 of https://codereview.chromium.org/1078413003/)
Reason for revert:
Crazy failings in chrome tests
http://build.chromium.org/p/client.skia/builders/Linux%20Tests/builds/1862
Original issue's description:
> Speeup hairline curves (quads and cubics)
>
> /skia/trunk> cat ../old.txt
> maxrss loops min median mean max stddev samples config bench
> 9M 1 4.28ms 4.32ms 4.36ms 4.67ms 3% ▄▁▁▃▂▂▁▁▂█ 8888 path_hairline_small_AA_cubic
> 9M 1 743µs 767µs 770µs 825µs 4% ▃▃▇▃▁▁▅▁█▁ 8888 path_hairline_small_AA_conic
> 9M 1 533µs 606µs 598µs 680µs 9% ▁▂▂█▆▇▇▄▂▂ 8888 path_hairline_small_AA_quad
> 9M 1 451µs 452µs 456µs 495µs 3% ▁▁▁▁█▁▁▁▁▁ 8888 path_hairline_small_AA_line
>
> /skia/trunk> cat ../new.txt
> maxrss loops min median mean max stddev samples config bench
> 9M 1 827µs 827µs 831µs 869µs 2% ▁▁▁▁▁▁▁█▁▁ 8888 path_hairline_small_AA_cubic
> 9M 1 515µs 517µs 517µs 518µs 0% ▇█▆▅▃▃▁▁▁▅ 8888 path_hairline_small_AA_conic
> 9M 1 310µs 311µs 315µs 332µs 2% ▂▁█▆▁▁▁▁▁▁ 8888 path_hairline_small_AA_quad
> 9M 1 254µs 254µs 258µs 276µs 3% ▁▁▁▁▁▁▁█▇▂ 8888 path_hairline_small_AA_line
>
> Edited revert of https://codereview.chromium.org/1085013003
>
> TBR=
>
> Expectations:
> - no effect on chrome, as it is guarded
> - lots of tiny rebaselines for skia
TBR=
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.chromium.org/1092483003
Diffstat (limited to 'src/core/SkGeometry.h')
-rw-r--r-- | src/core/SkGeometry.h | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/src/core/SkGeometry.h b/src/core/SkGeometry.h index 9ddd91f750..bafde61155 100644 --- a/src/core/SkGeometry.h +++ b/src/core/SkGeometry.h @@ -9,22 +9,6 @@ #define SkGeometry_DEFINED #include "SkMatrix.h" -#include "SkNx.h" - -static inline Sk2s from_point(const SkPoint& point) { - return Sk2s::Load(&point.fX); -} - -static inline SkPoint to_point(const Sk2s& x) { - SkPoint point; - x.store(&point.fX); - return point; -} - -static inline Sk2s sk2s_cubic_eval(const Sk2s& A, const Sk2s& B, const Sk2s& C, const Sk2s& D, - const Sk2s& t) { - return ((A * t + B) * t + C) * t + D; -} /** Given a quadratic equation Ax^2 + Bx + C = 0, return 0, 1, 2 roots for the equation. @@ -41,16 +25,6 @@ SkPoint SkEvalQuadTangentAt(const SkPoint src[3], SkScalar t); */ void SkEvalQuadAt(const SkPoint src[3], SkScalar t, SkPoint* pt, SkVector* tangent = NULL); -/** - * output is : eval(t) == coeff[0] * t^2 + coeff[1] * t + coeff[2] - */ -void SkQuadToCoeff(const SkPoint pts[3], SkPoint coeff[3]); - -/** - * output is : eval(t) == coeff[0] * t^3 + coeff[1] * t^2 + coeff[2] * t + coeff[3] - */ -void SkCubicToCoeff(const SkPoint pts[4], SkPoint coeff[4]); - /** Given a src quadratic bezier, chop it at the specified t value, where 0 < t < 1, and return the two new quadratics in dst: dst[0..2] and dst[2..4] |