/third_party/skia/include/core/ |
H A D | SkPath.h | 26 /** \class SkPath 27 SkPath contain geometry. SkPath may be empty, or contain one or more verbs that 28 outline a figure. SkPath always starts with a move verb to a Cartesian coordinate, 31 SkPath may contain any number of contours, each beginning with a move verb. 33 SkPath contours may contain only a move verb, or may also contain lines, 34 quadratic beziers, conics, and cubic beziers. SkPath contours may be open or 37 When used to draw a filled area, SkPath describes whether the fill is inside or 38 outside the geometry. SkPath also describes the winding rule used to fill 41 Internally, SkPath lazil 44 class SK_API SkPath { global() class [all...] |
/third_party/skia/src/core/ |
H A D | SkPathPriv.h | 53 static SkPathFirstDirection ComputeFirstDirection(const SkPath&); 55 static bool IsClosedSingleContour(const SkPath& path) { in IsClosedSingleContour() 63 case SkPath::Verb::kMove_Verb: in IsClosedSingleContour() 69 case SkPath::Verb::kClose_Verb: in IsClosedSingleContour() 81 // irrelevant to behavior). SkPath::injectMoveToIfNeeded should ensure that this is always at 83 static int LeadingMoveToCount(const SkPath& path) { in LeadingMoveToCount() 87 if (verbs[i] != SkPath::Verb::kMove_Verb) { in LeadingMoveToCount() 94 static void AddGenIDChangeListener(const SkPath& path, sk_sp<SkIDChangeListener> listener) { in AddGenIDChangeListener() 103 static bool IsSimpleRect(const SkPath& path, bool isSimpleFill, SkRect* rect, 110 static void CreateDrawArcPath(SkPath* pat [all...] |
H A D | HMSymbol.cpp | 19 void HMSymbol::PathOutlineDecompose(const SkPath& path, std::vector<SkPath>& paths) in PathOutlineDecompose() 21 SkPath::RawIter iter = SkPath::RawIter(path); in PathOutlineDecompose() 23 SkPath::Verb verb; in PathOutlineDecompose() 24 SkPath path_stemp; in PathOutlineDecompose() 25 while ((verb = iter.next(pts)) != SkPath::kDone_Verb) { in PathOutlineDecompose() 27 case SkPath::kMove_Verb: in PathOutlineDecompose() 34 case SkPath::kLine_Verb: in PathOutlineDecompose() 37 case SkPath in PathOutlineDecompose() [all...] |
H A D | SkPath.cpp | 8 #include "include/core/SkPath.h" 38 static_assert(sizeof(SkPath) == sizeof(SkPath_Storage_Equivalent), 39 "Please keep an eye on SkPath packing."); 63 static bool is_degenerate(const SkPath& path) { in is_degenerate() 69 SkAutoDisableDirectionCheck(SkPath* path) : fPath(path) { in SkAutoDisableDirectionCheck() 78 SkPath* fPath; 96 SkAutoPathBoundsUpdate(SkPath* path, const SkRect& r) : fPath(path), fRect(r) { in SkAutoPathBoundsUpdate() 118 SkPath* fPath; 146 SkPath::SkPath() in SkPath() function in SkPath 152 SkPath::SkPath(sk_sp<SkPathRef> pr, SkPathFillType ft, bool isVolatile, SkPathConvexity ct, SkPath() function in SkPath 173 SkPath::SkPath(const SkPath& that) SkPath() function in SkPath [all...] |
H A D | SkPathRef.cpp | 10 #include "include/core/SkPath.h" 43 void SkPath::shrinkToFit() { in shrinkToFit() 366 SkPoint* SkPathRef::growForRepeatedVerb(int /*SkPath::Verb*/ verb, 372 case SkPath::kMove_Verb: 375 case SkPath::kLine_Verb: 376 fSegmentMask |= SkPath::kLine_SegmentMask; 379 case SkPath::kQuad_Verb: 380 fSegmentMask |= SkPath::kQuad_SegmentMask; 383 case SkPath::kConic_Verb: 384 fSegmentMask |= SkPath [all...] |
H A D | SkScan.h | 19 class SkPath; 42 static void FillPath(const SkPath&, const SkIRect&, SkBlitter*); 57 static void FillPath(const SkPath&, const SkRasterClip&, SkBlitter*); 58 static void AntiFillPath(const SkPath&, const SkRasterClip&, SkBlitter*); 68 static void HairPath(const SkPath&, const SkRasterClip&, SkBlitter*); 69 static void AntiHairPath(const SkPath&, const SkRasterClip&, SkBlitter*); 70 static void HairSquarePath(const SkPath&, const SkRasterClip&, SkBlitter*); 71 static void AntiHairSquarePath(const SkPath&, const SkRasterClip&, SkBlitter*); 72 static void HairRoundPath(const SkPath&, const SkRasterClip&, SkBlitter*); 73 static void AntiHairRoundPath(const SkPath [all...] |
/third_party/skia/tests/ |
H A D | PathOpsExtendedTest.h | 11 #include "include/core/SkPath.h" 23 //extern int comparePaths(const SkPath& one, const SkPath& two); 25 const SkPath& one, const SkPath& two, SkBitmap& bitmap); 28 const SkPath& one, const SkPath& two) { in comparePaths() 33 extern bool drawAsciiPaths(const SkPath& one, const SkPath& two, bool drawPaths); 36 extern bool testPathOp(skiatest::Reporter* reporter, const SkPath [all...] |
H A D | TriangulatingPathRendererTests.cpp | 10 #include "include/core/SkPath.h" 27 using CreatePathFn = SkPath(*)(); 33 []() -> SkPath { 34 SkPath path; 47 []() -> SkPath { 48 SkPath path; 60 []() -> SkPath { 61 SkPath path; 75 []() -> SkPath { 76 SkPath pat [all...] |
H A D | PathTest.cpp | 44 SkPath path; in test_add_rrect() 51 SkPath path; in test_skbug_3469() 76 static void make_path_crbug364224(SkPath* path) { in make_path_crbug364224() 100 static void make_path_crbug364224_simplified(SkPath* path) { in make_path_crbug364224_simplified() 109 SkPath path; in test_sect_with_horizontal_needs_pinning() 121 SkPath path; in test_path_crbug364224() 133 static void test_draw_AA_path(int width, int height, const SkPath& path) { in test_draw_AA_path() 143 SkPath path; in test_fuzz_crbug_638223() 152 SkPath path; in test_fuzz_crbug_643933() 167 SkPath pat in test_fuzz_crbug_647922() [all...] |
H A D | PathOpsExtendedTest.cpp | 43 bool OpDebug(const SkPath& one, const SkPath& two, SkPathOp op, SkPath* result 47 bool SimplifyDebug(const SkPath& one, SkPath* result 116 static void scaleMatrix(const SkPath& one, const SkPath& two, SkMatrix& scale) { in scaleMatrix() 142 static int pathsDrawTheSame(SkBitmap& bits, const SkPath& scaledOne, const SkPath& scaledTwo, 180 static int pathsDrawTheSame(const SkPath [all...] |
H A D | PathOpsAsWindingTest.cpp | 12 static SkPath build_squircle(SkPath::Verb verb, const SkRect& rect, SkPathDirection dir) { in build_squircle() 13 SkPath path; in build_squircle() 16 case SkPath::kLine_Verb: in build_squircle() 20 case SkPath::kQuad_Verb: in build_squircle() 27 case SkPath::kConic_Verb: in build_squircle() 31 case SkPath::kCubic_Verb: { in build_squircle() 46 SkPath temp; in build_squircle() 54 SkPath test, result; in DEF_TEST() 111 SkPath cop in DEF_TEST() [all...] |
H A D | SubsetPath.h | 10 #include "include/core/SkPath.h" 24 SkPath minimal; 38 SubsetPath(const SkPath& path); 40 bool subset(bool testFailed, SkPath* sub); 43 virtual SkPath getSubsetPath() const = 0; 45 const SkPath& fPath; 54 SubsetContours(const SkPath& path); 56 SkPath getSubsetPath() const override; 61 SubsetVerbs(const SkPath& path); 63 SkPath getSubsetPat [all...] |
H A D | PathOpsBuilderTest.cpp | 15 SkPath result; in DEF_TEST() 27 SkPath rectPath; in DEF_TEST() 54 SkPath rect2, rect3; in DEF_TEST() 67 SkPath circle1, circle2, circle3; in DEF_TEST() 71 SkPath opCompare; in DEF_TEST() 83 SkPath path; in DEF_TEST() 96 SkPath path2; in DEF_TEST() 105 SkPath path; in DEF_TEST() 112 SkPath result; in DEF_TEST() 119 SkPath pat in DEF_TEST() [all...] |
/third_party/skia/modules/pathkit/ |
H A D | pathkit_wasm_bindings.cpp | 11 #include "include/core/SkPath.h" 37 // SkPath, but in an error case, something of type null (which is val) could also be 48 JSArray EMSCRIPTEN_KEEPALIVE ToCmds(const SkPath& path) { in ToCmds() 86 // SkPath or SkOpBuilder. 94 SkPath path; in FromCmds() 150 SkPath EMSCRIPTEN_KEEPALIVE NewPath() { in NewPath() 151 return SkPath(); in NewPath() 154 SkPath EMSCRIPTEN_KEEPALIVE CopyPath(const SkPath& a) { in CopyPath() 155 SkPath cop in CopyPath() [all...] |
H A D | externs.js | 40 SkPath: { 89 PathKit.SkPath.prototype.addPath = function() {}; 90 PathKit.SkPath.prototype.arc = function(x, y, radius, startAngle, endAngle, ccw) {}; 91 PathKit.SkPath.prototype.arcTo = function(x1, y1, x2, y2, radius) {}; 92 PathKit.SkPath.prototype.bezierCurveTo = function(cp1x, cp1y, cp2x, cp2y, x, y) {}; 93 PathKit.SkPath.prototype.close = function() {}; 94 PathKit.SkPath.prototype.closePath = function() {}; 95 PathKit.SkPath.prototype.conicTo = function(x1, y1, x2, y2, w) {}; 96 PathKit.SkPath.prototype.cubicTo = function(cp1x, cp1y, cp2x, cp2y, x, y) {}; 97 PathKit.SkPath [all...] |
H A D | chaining.js | 4 // when onRuntimeInitialized is called, PathKit.SkPath is defined with many 9 PathKit.SkPath.prototype.addPath = function() { 52 PathKit.SkPath.prototype.arc = function(x, y, radius, startAngle, endAngle, ccw) { 57 PathKit.SkPath.prototype.arcTo = function(x1, y1, x2, y2, radius) { 62 PathKit.SkPath.prototype.bezierCurveTo = function(cp1x, cp1y, cp2x, cp2y, x, y) { 67 PathKit.SkPath.prototype.close = function() { 73 // superset of Path2D and also work like the original SkPath C++ object. 74 PathKit.SkPath.prototype.closePath = function() { 79 PathKit.SkPath.prototype.conicTo = function(x1, y1, x2, y2, w) { 84 PathKit.SkPath [all...] |
/third_party/skia/include/pathops/ |
H A D | SkPathOps.h | 14 class SkPath; 18 // FIXME: move everything below into the SkPath class 46 bool SK_API Op(const SkPath& one, const SkPath& two, SkPathOp op, SkPath* result); 60 bool SK_API Simplify(const SkPath& path, SkPath* result); 68 bool SK_API TightBounds(const SkPath& path, SkRect* result); 82 bool SK_API AsWinding(const SkPath& path, SkPath* resul [all...] |
/third_party/skia/fuzz/ |
H A D | FuzzPathop.cpp | 10 #include "include/core/SkPath.h" 26 SkPath path; in DEF_FUZZ() 27 FuzzEvilPath(fuzz, &path, SkPath::Verb::kDone_Verb); in DEF_FUZZ() 37 SkPath result; in DEF_FUZZ() 42 SkPath path; in DEF_FUZZ() 43 FuzzEvilPath(fuzz, &path, SkPath::Verb::kDone_Verb); in DEF_FUZZ() 48 SkPath result; in DEF_FUZZ() 58 SkPath path; in DEF_FUZZ() 59 FuzzEvilPath(fuzz, &path, SkPath::Verb::kDone_Verb); in DEF_FUZZ() 64 SkPath path in DEF_FUZZ() [all...] |
/third_party/skia/src/pathops/ |
H A D | SkOpEdgeBuilder.cpp | 33 static bool can_add_curve(SkPath::Verb verb, SkPoint* curve) { in can_add_curve() 34 if (SkPath::kMove_Verb == verb) { in can_add_curve() 40 return SkPath::kLine_Verb != verb || !SkDPoint::ApproximatelyEqual(curve[0], curve[1]); in can_add_curve() 43 void SkOpEdgeBuilder::addOperand(const SkPath& path) { in addOperand() 44 SkASSERT(fPathVerbs.count() > 0 && fPathVerbs.end()[-1] == SkPath::kDone_Verb); in addOperand() 67 *fPathVerbs.append() = SkPath::kLine_Verb; in closeContour() 72 if (SkPath::kLine_Verb == fPathVerbs[verbCount - 1] in closeContour() 80 *fPathVerbs.append() = SkPath::kClose_Verb; in closeContour() 92 auto verb = static_cast<SkPath::Verb>(pathVerb); in preFetch() 94 case SkPath in preFetch() [all...] |
/third_party/skia/gm/ |
H A D | patharcto.cpp | 18 // The fix was to use doubles for this part of the calc in SkPath::arcTo(). 46 SkPath path; in DEF_SIMPLE_GM() 50 SkPath path2; in DEF_SIMPLE_GM() 60 static SkPath old_school_polygon(const SkPoint pts[], size_t count, bool isClosed) { in old_school_polygon() 61 SkPath path; in old_school_polygon() 66 static SkPath new_school_polygon(const SkPoint pts[], size_t count, bool isClosed) { in new_school_polygon() 67 return SkPath::Polygon(pts, count, isClosed); in new_school_polygon() 78 const SkPath path1 = SkPath::Polygon(p1, SK_ARRAY_COUNT(p1), false); in DEF_SIMPLE_GM() 95 SkPath path in DEF_SIMPLE_GM() [all...] |
H A D | overstroke.cpp | 59 SkPath quad_path() { in quad_path() 67 SkPath cubic_path() { in cubic_path() 68 SkPath path; in cubic_path() 77 SkPath oval_path() { in oval_path() 83 SkPath ribs_path(SkPath path, SkScalar radius) { in ribs_path() 84 SkPath ribs; in ribs_path() 107 void draw_ribs(SkCanvas *canvas, SkPath path) { in draw_ribs() 108 SkPath ribs = ribs_path(path, OVERSTROKE_WIDTH/2.0f); in draw_ribs() 124 SkPath pat in draw_small_quad() [all...] |
/third_party/skia/src/effects/ |
H A D | Sk1DPathEffect.cpp | 23 bool onFilterPath(SkPath* dst, const SkPath& src, SkStrokeRec*, const SkRect*, 50 virtual SkScalar next(SkPath* dst, SkScalar dist, SkPathMeasure&) const = 0; 63 SkPath1DPathEffectImpl(const SkPath& path, SkScalar advance, SkScalar phase, in SkPath1DPathEffectImpl() 95 bool onFilterPath(SkPath* dst, const SkPath& src, SkStrokeRec* rec, 105 SkScalar next(SkPath*, SkScalar, SkPathMeasure&) const override; 109 SkPath path; in CreateProc() 127 SkPath fPath; // copied from constructor 166 static void morphpath(SkPath* ds [all...] |
H A D | SkCornerPathEffect.cpp | 9 #include "include/core/SkPath.h" 36 bool onFilterPath(SkPath* dst, const SkPath& src, SkStrokeRec*, const SkRect*, 42 SkPath::Iter iter(src, false); 43 SkPath::Verb verb, prevVerb = SkPath::kDone_Verb; 59 case SkPath::kMove_Verb: 61 if (SkPath::kLine_Verb == prevVerb) { 73 case SkPath::kLine_Verb: { 90 case SkPath [all...] |
H A D | Sk2DPathEffect.cpp | 8 #include "include/core/SkPath.h" 30 virtual void begin(const SkIRect& uvBounds, SkPath* dst) const {} in begin() 31 virtual void next(const SkPoint& loc, int u, int v, SkPath* dst) const {} in next() 32 virtual void end(SkPath* dst) const {} in end() 38 virtual void nextSpan(int x, int y, int ucount, SkPath* path) const { in nextSpan() 66 bool onFilterPath(SkPath* dst, const SkPath& src, SkStrokeRec* rec, 72 SkPath tmp; 117 bool onFilterPath(SkPath* dst, const SkPath [all...] |
/third_party/skia/docs/examples/ |
H A D | ChromeMDRefreshTab.cpp | 5 SkPath GetBorderPath(float scale, in REG_FIDDLE() 15 SkPath path; in REG_FIDDLE() 18 path.arcTo(scaled_endcap_radius - 1, scaled_endcap_radius - 1, 90, SkPath::kSmall_ArcSize, in REG_FIDDLE() 27 path.arcTo(scaled_endcap_radius + 1, scaled_endcap_radius + 1, 90, SkPath::kSmall_ArcSize, in REG_FIDDLE() 49 path.arcTo(scaled_endcap_radius + 1, scaled_endcap_radius + 1, 90, SkPath::kSmall_ArcSize, in REG_FIDDLE() 61 path.arcTo(scaled_endcap_radius - 1, scaled_endcap_radius - 1, 90, SkPath::kSmall_ArcSize, in REG_FIDDLE() 71 SkPath GetInteriorPath( in REG_FIDDLE() 86 SkPath right_path; in REG_FIDDLE() 91 right_path.arcTo(scaled_endcap_radius, scaled_endcap_radius, 90, SkPath::kSmall_ArcSize, in REG_FIDDLE() 102 right_path.arcTo(scaled_endcap_radius, scaled_endcap_radius, 90, SkPath in REG_FIDDLE() [all...] |