GEOS
3.9.1dev
|
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::PrecisionModel * | getPrecisionModel () |
bool | getRemoveCollapsed () |
std::unique_ptr< geom::Geometry > | reduce (const geom::Geometry *geom) |
Private Attributes | |
const geom::PrecisionModel * | newPrecisionModel |
bool | removeCollapsed |
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.
Definition at line 45 of file SimpleGeometryPrecisionReducer.h.
geos::precision::SimpleGeometryPrecisionReducer::SimpleGeometryPrecisionReducer | ( | const geom::PrecisionModel * | pm | ) |
const geom::PrecisionModel* geos::precision::SimpleGeometryPrecisionReducer::getPrecisionModel | ( | ) |
bool geos::precision::SimpleGeometryPrecisionReducer::getRemoveCollapsed | ( | ) |
std::unique_ptr<geom::Geometry> geos::precision::SimpleGeometryPrecisionReducer::reduce | ( | const geom::Geometry * | geom | ) |
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.
nRemoveCollapsed | if true collapsed components will be removed |
|
private |
Definition at line 49 of file SimpleGeometryPrecisionReducer.h.
|
private |
Definition at line 51 of file SimpleGeometryPrecisionReducer.h.