Decrease the tolerance for classifying degenerate cubics

Bug: skia:
Change-Id: I118f52301146ed7a7333d4f6bd2297d500a0df97
Reviewed-on: https://skia-review.googlesource.com/21187
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
This commit is contained in:
Chris Dalton 2017-06-28 16:42:50 -06:00 committed by Skia Commit-Bot
parent 5fb30566b4
commit 4a80f5eec4

View File

@ -603,7 +603,7 @@ static void sort_and_orient_t_s(double t[2], double s[2]) {
static SkCubicType classify_cubic(const double d[4], double t[2], double s[2]) {
double tolerance = SkTMax(fabs(d[1]), fabs(d[2]));
tolerance = SkTMax(tolerance, fabs(d[3]));
tolerance = tolerance * 1e-5;
tolerance = tolerance * 1e-4;
if (fabs(d[1]) > tolerance) {
const double discr = 3 * d[2] * d[2] - 4 * d[1] * d[3];
if (discr > 0) {