17#include <geos/geom/Envelope.h>
18#include <geos/geom/Geometry.h>
20#include <geos/operation/grid/Side.h>
21#include <geos/operation/grid/Traversal.h>
23namespace geos::operation::grid {
33 Cell(
double xmin,
double ymin,
double xmax,
double ymax)
34 : m_box{ xmin, ymin, xmax, ymax }
44 void getEdgePoints(Side s, std::vector<geom::CoordinateXY>& points)
const;
48 double getWidth()
const;
50 double getHeight()
const;
52 double getArea()
const;
90 bool take(
const geom::CoordinateXY& c,
const geom::CoordinateXY* prev_original,
bool exitOnBoundary,
const void* parentage);
93 std::vector<const Traversal*> getTraversals()
const;
104 std::vector<Traversal> m_traversals;
106 Side getSide(
const geom::CoordinateXY& c)
const;
108 Location getLocation(
const geom::CoordinateXY& c)
const;
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:71
The Cell class stores information about the spatial extent of a Grid cell and any cases where a line ...
Definition Cell.h:30
std::unique_ptr< geom::Geometry > getCoveredPolygons(const geom::GeometryFactory &) const
Traversal & getLastTraversal()
bool isDetermined() const
double getCoveredFraction() const
Return the fraction of this Cell that is covered by a polygon.
void getEdgePoints(Side s, std::vector< geom::CoordinateXY > &points) const
Get all points that fall on the specified side of this cell.
bool take(const geom::CoordinateXY &c, const geom::CoordinateXY *prev_original, bool exitOnBoundary, const void *parentage)
double getTraversalLength() const
Return the total length of a linear geometry within this Cell.
The Traversal class records the coordinates of a line that are within a grid cell,...
Definition Traversal.h:31