import { type PathConstructorAndFactory } from "https://deno.land/x/canvas@v1.3.0/mod.ts";
Contains the ways to create an Path.
Methods
Creates a new path from the given list of path commands. If this fails, null will be returned instead.
Creates a new path by combining the given paths according to op. If this fails, null will be returned instead.
Creates a new path from the provided SVG string. If this fails, null will be returned instead.
Creates a new path using the provided verbs and associated points and weights. The process reads the first verb from verbs and then the appropriate number of points from the FlattenedPointArray (e.g. 2 points for moveTo, 4 points for quadTo, etc). If the verb is a conic, a weight will be read from the WeightList. If the data is malformed (e.g. not enough points), the resulting path will be incomplete.