20 #ifndef GEOS_OP_BUFFER_OFFSETSEGMENTSTRING_H 21 #define GEOS_OP_BUFFER_OFFSETSEGMENTSTRING_H 69 if(ptList->
size() < 1) {
74 if(ptDist < minimumVertexDistance) {
89 ptList(new geom::CoordinateArraySequence()),
90 precisionModel(nullptr),
91 minimumVertexDistance(0.0)
110 precisionModel =
nullptr;
111 minimumVertexDistance = 0.0;
117 precisionModel = nPrecisionModel;
123 minimumVertexDistance = nMinVertexDistance;
129 assert(precisionModel);
140 ptList->
add(bufPt,
true);
147 for(
size_t i = 0, n = pts.
size(); i < n; ++i) {
152 for(
size_t i = pts.
size(); i > 0; --i) {
164 if(ptList->
size() < 1) {
169 if(startPt.
equals(lastPt)) {
173 ptList->
add(startPt,
true);
196 return ptList ? ptList->
size() : 0 ;
209 os <<
"empty (consumed?)";
219 #endif // ndef GEOS_OP_BUFFER_OFFSETSEGMENTSTRING_H OffsetSegmentString & operator=(const OffsetSegmentString &)=delete
const geom::PrecisionModel * precisionModel
bool isRedundant(const geom::Coordinate &pt) const
Tests whether the given point is redundant relative to the previous point in the list (up to toleranc...
The default implementation of CoordinateSequence.
Coordinate is the lightweight class used to store coordinates.
double minimumVertexDistance
The distance below which two adjacent points on the curve are considered to be coincident.
const Coordinate & back() const
Return last Coordinate in the sequence.
Specifies the precision model of the Coordinate in a Geometry.
void setMinimumVertexDistance(double nMinVertexDistance)
geom::CoordinateSequence * getCoordinates()
void add(const Coordinate &c)
Add a Coordinate to the list.
void addPts(const geom::CoordinateSequence &pts, bool isForward)
bool equals(const Coordinate &other) const
2D only
Basic namespace for all GEOS functionalities.
void setPrecisionModel(const geom::PrecisionModel *nPrecisionModel)
double makePrecise(double val) const
Rounds a numeric value to the PrecisionModel grid.
double distance(const Coordinate &p) const
void addPt(const geom::Coordinate &pt)
The internal representation of a list of coordinates inside a Geometry.
void clear()
Reset this CoordinateArraySequence to the empty state.
friend std::ostream & operator<<(std::ostream &os, const OffsetSegmentString &node)
geom::CoordinateArraySequence * ptList
const Coordinate & front() const
Return first Coordinate in the sequence.