GEOS  3.13.0dev
Public Member Functions | List of all members
geos::precision::SimpleGeometryPrecisionReducer Class Reference

Reduces the precision of a geom::Geometry according to the supplied geom::PrecisionModel, without attempting to preserve valid topology. More...

#include <SimpleGeometryPrecisionReducer.h>

Public Member Functions

 SimpleGeometryPrecisionReducer (const geom::PrecisionModel *pm)
 
void setRemoveCollapsedComponents (bool nRemoveCollapsed)
 
const geom::PrecisionModelgetPrecisionModel ()
 
bool getRemoveCollapsed ()
 
std::unique_ptr< geom::Geometryreduce (const geom::Geometry *geom)
 

Detailed Description

Reduces the precision of a geom::Geometry according to the supplied geom::PrecisionModel, without attempting to preserve valid topology.

The topology of the resulting geometry may be invalid if topological collapse occurs due to coordinates being shifted. It is up to the client to check this and handle it if necessary. Collapses may not matter for some uses. An example is simplifying the input to the buffer algorithm. The buffer algorithm does not depend on the validity of the input geometry.

Member Function Documentation

◆ setRemoveCollapsedComponents()

void geos::precision::SimpleGeometryPrecisionReducer::setRemoveCollapsedComponents ( bool  nRemoveCollapsed)

Sets whether the reduction will result in collapsed components being removed completely, or simply being collapsed to an (invalid) Geometry of the same type.

Parameters
nRemoveCollapsedif true collapsed components will be removed

The documentation for this class was generated from the following file: