All notable changes to PGS will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning. Dates are YYYY-MM-DD.
polygonizeLines()
toPGS_Processing
. Computes the polygonal faces formed by a set of intersecting line segments.- Additional method signature for
PGS_Processing.generateRandomGridPoints()
that accepts a random seed. fieldWarp()
toPGS_Morphology
. Warps a shape by displacing vertices according to a 2D noise vector field.radialWarp()
toPGS_Morphology
. Warps a shape by displacing vertices along a line between each vertex and the shape centroid.- Expand PGS_Conversion to support conversion between:
TRIANGLES
PShape➜JTSMultiPolygon
QUADS
PShape➜JTSMultiPolygon
- Issue with negative rotation values in
PGS_Transformation.rotateAroundCenter()
.
voronoiCells()
toPGS_Voronoi
. Generates Voronoi diagrams from shapes or point sets, outputting the diagram as polygonal cells (rather than lines only, as before).- Additional method signature for
voronoiDiagram()
that accepts a list of points (rather than PShapes only, as before). findContainedPoints()
toPGS_ShapePredicates
. Tests each point in a given point set whether it is contained in a shape, returning only those points that are contained.
- Constrained Voronoi diagrams are now constrained to envelope of input shape, rather than a arbitrarily large area.
- Refactored
List<PVector>
method arguments toCollection<PVector>
where possible.
generateRandomPoints()
no longer skips over small subsections of shapes when generating random points.
PGS_CirclePacking
— a class for circle packings of shapes, subject to varying constraints and patterns of tangenciesclosestPointPair()
toPGS_Optimisation
. Efficiently computes the closest pair of points in a set of points.farthestPointPair()
toPGS_Optimisation
. Efficiently computes the farthest pair of points in a set of points.chaikinCut()
toPGS_Morphology
. Smoothes shapes via iterated corner cuts.createHeart()
toPGS_Construction
. Generates heart-shaped PShapes.urquhartFaces()
toPGS_Triangulation
. Tessellates a triangulation into polygons corresponding to the faces of an Urquhart graph.gabrielFaces()
toPGS_Triangulation
. Tessellates a triangulation into polygons corresponding to the faces of an Gabriel graph.- Additional method signature for
earCutTriangulation()
accepts a PShape argument (previously it accepted a list of points only) - Additional method signature for
generateRandomPoints()
that accepts a random seed. - Additional method signature for each of the existing 3 Delaunay Triangulation methods, accepting a collection of points only.
- Expand
PGS_Conversion
to support conversion between:PATH
PShape⟷JTSLineString
POINTS
PShape⟷JTSMultiPoint
LINES
PShape⟷JTSMultiLineString
- Split
PGS_Processing.concaveHull()
intoconcaveHullDFS()
andconcaveHullBFS()
(the method previously used the BFS approach only). - Compute (rather than ignore) circle sites of radius 0 (these are effectively points) in
PGS_Voronoi.voronoiCirclesDiagram()
- Replaced the algorithm used by
PGS_Processing.generateRandomPoints()
with a triangulation-based approach. The new approach is ~10x faster! - Renamed
delaunayTriangulationTin()
todelaunayTriangulationMesh()
. - Renamed
poissonTriangulation()
topoissonTriangulationPoints()
(the method of the same original name now outputs a PShape).
- Error when
concaveHull2()
was called with alpha > 1. - Concave hull methods no longer mutate the input point set.
- PShapes marked as closed and having less than 3 vertices could cause an error during conversion (#22).
PGS_Conversion.toPVector()
now handles primitive PShapes- Constrained Delaunay triangulations now respect shape holes
PGS_Processing.concaveHull()
(see Changed)