Monitor

interface Monitor

Implementation of this interface will receive calls with internal data at each step of the triangulation algorithm. This is of use for debugging complex cases, as well as gaining insight into the way the algorithm works. Data provided includes a status string containing the current mode, list of points representing the current linked-list of internal nodes used for triangulation, and a list of triangles so far created by the algorithm.

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
abstract fun currentState(status: String, points: MutableList<Point>?, tessellation: MutableList<Tessellator.Triangle>)

Each loop of the main earclip algorithm will call this with the current state

Link copied to clipboard
abstract fun endSplit(status: String)

When a polygon split is completed, this is called.

Link copied to clipboard
abstract fun startSplit(status: String, leftPolygon: MutableList<Point>, rightPolygon: MutableList<Point>)

When a new polygon split is entered for mode=SPLIT, this is called.