interface GeometricShape<S : Vector<S>, A : GeometricTransformation<S>> : Serializable
Models a generic shape.
Parameters
Parameters
centroid |
The geometric center. abstract val centroid: S |
diameter |
The largest distance between any pair of vertices. abstract val diameter: Double |
contains |
Check if the shape contains a vector. abstract fun contains(vector: S): Boolean |
intersects |
A shape intersects another if any of its points is contained in the other one. abstract fun intersects(other: GeometricShape<S, A>): Boolean |
transformed |
Transforms the shape. abstract fun transformed(transformation: A.() -> Unit): GeometricShape<S, A> |