Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
open val area: Double
Link copied to clipboard
open val center: Point
Link copied to clipboard
open val closed: Boolean
Link copied to clipboard
open val perimeter: Double

Functions

Link copied to clipboard

open fun containsPoint(ml: Matrix, p: Point, mr: Matrix): Boolean

ml transformation matrix of this Shape2D, mr transformation matrix of the point p

Link copied to clipboard
open fun distance(p: Point): Double

Compute the distance to the shortest point to the edge (SDF). Negative inside. Positive outside.

open fun distance(ml: Matrix, p: Point, mr: Matrix): Double

ml transformation matrix of this Shape2D, mr transformation matrix of the point p

Link copied to clipboard
open fun getBounds(): Rectangle
Link copied to clipboard

open fun intersectionsWith(ml: Matrix, that: Shape2D, mr: Matrix): PointList

ml transformation matrix of this Shape2D, mr transformation matrix of the shape that

Link copied to clipboard
open fun intersectsWith(that: Shape2D): Boolean
open fun intersectsWith(ml: Matrix, that: Shape2D, mr: Matrix): Boolean
Link copied to clipboard
abstract fun normalVectorAt(p: Point): Vector2D

Returns the normal vector to the shortest point to the edge

open fun normalVectorAt(ml: Matrix, p: Point, mr: Matrix): Point

ml transformation matrix of this Shape2D, mr transformation matrix of the point p

Link copied to clipboard
abstract fun projectedPoint(p: Point): Point

Point projected to the closest edge

open fun projectedPoint(ml: Matrix, p: Point, mr: Matrix): Point

ml transformation matrix of this Shape2D, mr transformation matrix of the point p

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract fun toVectorPath(): VectorPath