2.0
PGS now uses Java 17+.
And you can now install PGS through the Processing contribution manager!

Added
findShortestTour()toPGS_PointSet. Computes an approximate Traveling Salesman path for a set of points.pruneSparsePoints()toPGS_PointSet. Prunes a list of points by removing points that are considered not sufficiently dense (far away from their nearest neighbours); a counterpart toprunePointsWithinDistance().- Additional method signature for
PGS_Morphology.variableBuffer()that accepts a callback function to define the buffer value at each vertex. boundsCenter()toPGS_Transformation. Computes the center of the bounding box of a shape.- Additional method signature for
delaunayTriangulation(points)that supports a boundary constraint. fix()toPGS_Processing. Attempts to fix shapes with invalid geometry.- Additional method signature for
frontChainPack()that accepts a random seed. isClockwise()toPGS_ShapePredicates. Determines if the vertices of the specified shape form a clockwise loop.extractInnerVertices()toPGS_Meshing. Extracts all inner vertices from a mesh.thomasClusters()toPGS_PointSet. Generates random points having clustered properties using the Thomas Point Process.transform()andtransformWithIndex()* toPGS_Processing. Applies a specified transformation function to each child of the given PShape and returns a new PShape containing the transformed children (*additionally with child's index).apply()andapplyWithIndex()* toPGS_Processing. Applies a specified function to each child of the given PShape (*additionally with child's index).toContours()toPGS_Conversion. Extracts the contours from a POLYGON or PATH PShape, represented as lists of PVector points.segmentsOnExterior()toPGS_Processing. Extracts evenly spaced dashed line segments along the perimeter of a shape.multiplicativelyWeightedVoronoi()toPGS_Voronoi. Generates a Multiplicatively Weighted Voronoi Diagrams diagram for a set of weighted sites.applyRandomWeights()toPGS_PointSet. Applies random weights within a specified range to a list of points.findContainingFace()toPGS_Meshing. Finds the single face from the mesh that contains the query point.findBreaks()toPGS_Meshing. Returns the locations of invalid mesh face boundary segments if found.pinchWarp()toPGS_Morphology. Applies a pinch warping effect to a shape, distorting vertices towards a specified point.
Changes
- Packed circles from
PGS_CirclePacking.stochasticPack()will now always lie within shape bounds. PGS_Processing.pointsOnExterior()methods now respect GROUP shapes and holes (inner rings) and will populate them with points.PGS_Morphology.simplifyDCE()now supports GROUP shapes and polygon holes.PGS_Morphology.interpolate()is much faster on shapes with many vertices.- Removed superfluous
heightargument fromPGS.createSupercircle()method signature. - Renamed
fromPVector(shell, holes)inPGS_ConversiontofromContours(shell, holes). - Moved
PGS_Processing.cleanCoverage()toPGS_Meshingand renamed tofixBreaks().
Fixed
urquhartFaces(),relativeNeighborFaces(),gabrielFaces()andspannerFaces()fromPGS_Meshingnow preserve holes from the input.- The output of
PGS_Morphology.smoothGaussian()is no longer (slightly) affected by the vertex ordering of the input. - The
transformandreferencearguments forPGS_Transformation.align()were the wrong way round.
Removed
simplifyDCE(shape, targetNumVertices)andsimplifyDCE(shape, vertexRemovalFraction)in favour a single method that accepts a user-defined termination callback that is supplied with the current vertex candidate's coordinate, relevance score, and the number of vertices remaining.