/external/skia/tests/ |
PathOpsConicLineIntersectionTest.cpp | 16 SkDConic conic; member in struct:lineConic 31 static int doIntersect(SkIntersections& intersections, const SkDConic& conic, const SkDLine& line, 42 result = intersections.vertical(conic, top, bottom, line[0].fX, flipped); 50 result = intersections.horizontal(conic, left, right, line[0].fY, flipped); 52 intersections.intersect(conic, line); 59 SkDConic conic; member in struct:oneLineConic 71 const SkDConic& conic = oneOffs[index].conic; local 72 SkASSERT(ValidConic(conic)); 76 int result = doIntersect(intersections, conic, line, flipped) 98 const SkDConic& conic = lineConicTests[index].conic; local [all...] |
GeometryTest.cpp | 72 static void test_conic_eval_pos(skiatest::Reporter* reporter, const SkConic& conic, SkScalar t) { 74 conic.evalAt(t, &p0, NULL); 75 p1 = conic.evalAt(t); 76 check_pairs(reporter, 0, t, "conic-pos", p0.fX, p0.fY, p1.fX, p1.fY); 79 static void test_conic_eval_tan(skiatest::Reporter* reporter, const SkConic& conic, SkScalar t) { 81 conic.evalAt(t, NULL, &v0); 82 v1 = conic.evalTangentAt(t); 83 check_pairs(reporter, 0, t, "conic-tan", v0.fX, v0.fY, v1.fX, v1.fY); 95 SkConic conic(pts, w); 100 test_conic_eval_pos(reporter, conic, t) [all...] |
PathOpsDebug.cpp | 365 SkDConic conic; local 370 SkTSect<SkDConic, SkDQuad> k1q2(conic PATH_OPS_DEBUG_T_SECT_PARAMS(1)); 371 SkTSect<SkDConic, SkDConic> k1k2(conic PATH_OPS_DEBUG_T_SECT_PARAMS(1)); 372 SkTSect<SkDConic, SkDCubic> k1c2(conic PATH_OPS_DEBUG_T_SECT_PARAMS(1)); 395 SkDConic conic; local 400 SkTSect<SkDConic, SkDQuad> k1q2(conic PATH_OPS_DEBUG_T_SECT_PARAMS(1)); 401 SkTSect<SkDConic, SkDConic> k1k2(conic PATH_OPS_DEBUG_T_SECT_PARAMS(1)); 402 SkTSect<SkDConic, SkDCubic> k1c2(conic PATH_OPS_DEBUG_T_SECT_PARAMS(1)); 425 SkDConic conic; local 430 SkTSect<SkDConic, SkDQuad> k1q2(conic PATH_OPS_DEBUG_T_SECT_PARAMS(1)) 455 SkDConic conic; local 485 SkDConic conic; local 515 SkDConic conic; local 545 SkDConic conic; local 575 SkDConic conic; local 605 SkDConic conic; local [all...] |
PathOpsTestCommon.cpp | 268 bool ValidConic(const SkDConic& conic) { 270 if (!ValidPoint(conic[index])) { 274 if (SkDoubleIsNaN(conic.fWeight)) {
|
/external/skia/src/pathops/ |
SkConicLineIntersection.cpp | 30 int SkIntersections::intersectRay(const SkDConic& conic, const SkDLine& line) { 31 LineConicIntersections c(conic, line, this); 34 fPt[index] = conic.ptAtT(fT[0][index]);
|
SkPathOpsConic.h | 65 bool hullIntersects(const SkDConic& conic, bool* isLinear) const { 66 return fPts.hullIntersects(conic.fPts, isLinear); 100 SkDConic conic; local 101 conic.set(a, weight); 102 return conic.subDivide(t1, t2); 111 SkDConic conic; local 112 conic.set(pts, weight); 113 return conic.subDivide(a, c, t1, t2, newWeight);
|
SkPathOpsTSect.cpp | 17 int SkIntersections::intersect(const SkDConic& conic, const SkDQuad& quad) { 18 SkTSect<SkDConic, SkDQuad> sect1(conic PATH_OPS_DEBUG_T_SECT_PARAMS(1)); 38 int SkIntersections::intersect(const SkDCubic& cubic, const SkDConic& conic) { 40 SkTSect<SkDConic, SkDCubic> sect2(conic PATH_OPS_DEBUG_T_SECT_PARAMS(2));
|
SkPathOpsCurve.h | 99 SkDConic conic; local 100 conic.set(a, weight); 101 return conic.ptAtT(t); 155 SkDConic conic; local 156 conic.set(a, weight); 157 return conic.dxdyAtT(t); 213 SkDConic conic; local 214 conic.set(a, weight); 215 SkDConic dst = conic.subDivide(startT, endT); 251 SkDConic conic; local 295 SkDConic conic; local 300 SkDConic conic; local [all...] |
SkIntersections.h | 55 SkDConic conic; local 56 conic.set(a, weight); 58 return horizontal(conic, left, right, y, flipped); 63 SkDConic conic; local 64 conic.set(a, weight); 66 return vertical(conic, top, bottom, x, flipped); 70 SkDConic conic; local 71 conic.set(a, weight); 75 return intersect(conic, line); 239 static int HorizontalIntercept(const SkDConic& conic, SkScalar y, double* roots) [all...] |
SkDConicLineIntersection.cpp | 170 // OPTIMIZE: Functions of the form add .. points are indentical to the conic routines. 195 // FIXME: see if line end is nearly on conic 221 // FIXME: see if line end is nearly on conic 247 // FIXME: see if line end is nearly on conic 304 // check if midway on conic is also same point. If so, discard this 326 int SkIntersections::horizontal(const SkDConic& conic, double left, double right, double y, 329 LineConicIntersections c(conic, line, this); 333 int SkIntersections::vertical(const SkDConic& conic, double top, double bottom, double x, 336 LineConicIntersections c(conic, line, this); 340 int SkIntersections::intersect(const SkDConic& conic, const SkDLine& line) [all...] |
SkPathOpsQuad.cpp | 51 bool SkDQuad::hullIntersects(const SkDConic& conic, bool* isLinear) const { 52 return conic.hullIntersects(*this, isLinear);
|
SkPathOpsCubic.cpp | 209 bool SkDCubic::hullIntersects(const SkDConic& conic, bool* isLinear) const { 211 return hullIntersects(conic.fPts, isLinear);
|
/external/skia/src/core/ |
SkGeometry.h | 253 * return the power-of-2 number of quads needed to approximate this conic 259 * Chop this conic into N quads, stored continguously in pts[], where 272 /** Find the parameter value where the conic takes on its maximum curvature. 293 * Help class to allocate storage for approximating a conic with N quads. 300 * Given a conic and a tolerance, return the array of points for the 311 const SkPoint* computeQuads(const SkConic& conic, SkScalar tol) { 312 int pow2 = conic.computeQuadPOW2(tol); 315 conic.chopIntoQuadsPOW2(pts, pow2); 321 SkConic conic; local 322 conic.set(pts, weight) [all...] |
SkPathMeasure.cpp | 108 SkScalar SkPathMeasure::compute_conic_segs(const SkConic& conic, 110 if (tspan_big_enough(maxt - mint) && quad_too_curvy(conic.fPts)) { 112 conic.chop(tmp); 118 SkScalar d = SkPoint::Distance(conic.fPts[0], conic.fPts[2]); 211 const SkConic conic(pts, fIter.conicWeight()); 213 distance = this->compute_conic_segs(conic, distance, 0, kMaxTValue, ptIndex); 215 // we store the conic weight in our next point, followed by the last 2 pts 216 // thus to reconstitue a conic, you'd need to say 218 fPts.append()->set(conic.fW, 0) [all...] |
SkStroke.cpp | 476 void SkPathStroker::setConicEndNormal(const SkConic& conic, const SkVector& normalAB, 478 setQuadEndNormal(conic.fPts, normalAB, unitNormalAB, normalBC, unitNormalBC); 616 static bool conic_in_line(const SkConic& conic) { 617 return quad_in_line(conic.fPts); 651 SkPathStroker::ReductionType SkPathStroker::CheckConicLinear(const SkConic& conic, 653 bool degenerateAB = degenerate_vector(conic.fPts[1] - conic.fPts[0]); 654 bool degenerateBC = degenerate_vector(conic.fPts[2] - conic.fPts[1]); 661 if (!conic_in_line(conic)) { [all...] |
/external/skia/gm/ |
beziereffects.cpp | 390 // where to chop the conic. If the max curvature is not 392 // dst[0] is the original conic. If it returns 2 the dst[0] 403 SkConic conic; local 404 conic.set(src, weight); 405 conic.chopAt(t, dst); 411 // Calls split_conic on the entire conic and then once more on each subsection. 412 // Most cases will result in either 1 conic (chop point is not within t range)
|
/external/skia/bench/ |
PathBench.cpp | 813 ConicBench_Chop() : fName("conic-chop") { 841 fName.printf("conic-eval-pos%d", useV2); 866 fName.printf("conic-eval-tan%d", useV2); 889 static void rand_conic(SkConic* conic, SkRandom& rand) { 891 conic->fPts[i].set(rand.nextUScalar1() * 100, rand.nextUScalar1() * 100); 894 conic->fW = rand.nextUScalar1(); 896 conic->fW = 1 + rand.nextUScalar1() * 4; 929 return "conic-compute-error"; 951 return "conic-asQuadTol"; 972 return "conic-quadPow2" [all...] |
/external/skia/src/gpu/ |
GrAAHairLinePathRenderer.cpp | 133 // where to chop the conic. If the max curvature is not 135 // dst[0] is the original conic. If it returns 2 the dst[0] 146 SkConic conic; local 147 conic.set(src, weight); 148 conic.chopAt(t, dst); 154 // Calls split_conic on the entire conic and then once more on each subsection. 155 // Most cases will result in either 1 conic (chop point is not within t range) 169 // returns 0 if quad/conic is degen or close to it [all...] |