The writer supports removing duplicate consecutive points (via the setRemoveDuplicatePoints(boolean) method) as well as true decimation (via the setDecimation(double) method. Enabling one of these strategies can substantially improve rendering speed for large geometries. It is only necessary to enable one strategy. Using decimation is preferred, but this requires determining a distance below which input geometry vertices can be considered unique (which may not always be feasible). If neither strategy is enabled, all vertices of the input Geometry will be represented in the output Shape.
The default is false.
When rendering to a screen image, a suitably small distance should be used to avoid obvious rendering defects. A distance equivalent to the equivalent of 1.5 pixels or less is recommended (and perhaps even smaller to avoid any chance of visible artifacts).
The default distance is 0.0, which disables decimation.
Note that Shapes do not preserve information about which elements in heterogeneous collections are 1D and which are 2D. For example, a GeometryCollection containing a ring and a disk will render as two disks if Graphics.fill is used, or as two rings if Graphics.draw is used. To avoid this issue use separate shapes for the components.