19#include <geos/index/strtree/TemplateSTRtree.h>
20#include <geos/index/VertexSequencePackedRtree.h>
21#include <geos/simplify/LinkedLine.h>
22#include <geos/coverage/Corner.h>
23#include <geos/export.h>
24#include <geos/util/Progress.h>
30class CoordinateSequence;
63 using Corner = geos::coverage::Corner;
72 template<
typename ItemType>
73 using TemplateSTRtree = geos::index::strtree::TemplateSTRtree<ItemType>;
74 using LinkedLine = geos::simplify::LinkedLine;
91 LinkedLine linkedLine;
93 std::size_t minEdgeSize;
104 Edge(
const LineString* p_inputLine,
bool p_isFreeRing,
double p_areaTolerance);
106 const Coordinate& getCoordinate(std::size_t index)
const;
108 const Envelope* getEnvelopeInternal()
const;
110 std::size_t size()
const;
112 std::unique_ptr<CoordinateSequence> simplify(EdgeIndex& edgeIndex);
114 void createQueue(Corner::PriorityQueue& pq);
116 void addCorner(std::size_t i, Corner::PriorityQueue& cornerQueue);
118 bool isRemovable(Corner& corner, EdgeIndex& edgeIndex)
const;
129 bool hasIntersectingVertex(
const Corner& corner,
131 const Edge& edge)
const;
133 std::vector<std::size_t> query(
const Envelope& cornerEnv)
const;
146 Corner::PriorityQueue& cornerQueue);
154 TemplateSTRtree<const Edge*> index;
156 void add(std::vector<Edge>& edges);
158 std::vector<const Edge*> query(
const Envelope& queryEnv);
173 double distanceTolerance,
192 std::vector<bool>& freeRings,
194 double distanceTolerance,
199 double distanceTolerance);
206 std::vector<bool> isFreeRing;
207 double areaTolerance;
213 void setFreeRingIndices(std::vector<bool>& freeRing);
219 std::vector<Edge> createEdges(
221 std::vector<bool>& freeRing,
Definition TPVWSimplifier.h:62
static std::unique_ptr< MultiLineString > simplify(const MultiLineString *lines, double distanceTolerance, geos::util::ProgressFunction *progressFunction)
static std::unique_ptr< MultiLineString > simplify(const MultiLineString *lines, std::vector< bool > &freeRings, const MultiLineString *constraintLines, double distanceTolerance, geos::util::ProgressFunction *progressFunction)
The internal representation of a list of coordinates inside a Geometry.
Definition CoordinateSequence.h:56
Coordinate is the lightweight class used to store coordinates.
Definition Coordinate.h:220
An Envelope defines a rectangulare region of the 2D coordinate plane.
Definition Envelope.h:59
Supplies a set of utility methods for building Geometry objects from CoordinateSequence or other Geom...
Definition GeometryFactory.h:72
Basic implementation of Geometry, constructed and destructed by GeometryFactory.
Definition Geometry.h:201
Definition LineString.h:66
Models a collection of LineStrings.
Definition MultiLineString.h:49
Definition VertexSequencePackedRtree.h:49
std::function< void(double, const char *)> ProgressFunction
Definition Progress.h:29
Basic namespace for all GEOS functionalities.
Definition geos.h:38