|
GEOS 3.15.0dev
|
The Cell class stores information about the spatial extent of a Grid cell and any cases where a line crosses that cell (recorded in a Traversal).
More...
#include <Cell.h>
Public Member Functions | |
| Cell (double xmin, double ymin, double xmax, double ymax) | |
| Cell (const geom::Envelope &b) | |
| void | getEdgePoints (Side s, std::vector< geom::CoordinateXY > &points) const |
| Get all points that fall on the specified side of this cell. | |
| const geom::Envelope & | box () const |
| double | getWidth () const |
| double | getHeight () const |
| double | getArea () const |
| void | forceExit () |
| bool | isDetermined () const |
| double | getTraversalLength () const |
| Return the total length of a linear geometry within this Cell. | |
| double | getCoveredFraction () const |
| Return the fraction of this Cell that is covered by a polygon. | |
| std::unique_ptr< geom::Geometry > | getCoveredPolygons (const geom::GeometryFactory &) const |
| Traversal & | getLastTraversal () |
| bool | take (const geom::CoordinateXY &c, const geom::CoordinateXY *prev_original, bool exitOnBoundary, const void *parentage) |
The Cell class stores information about the spatial extent of a Grid cell and any cases where a line crosses that cell (recorded in a Traversal).
| void geos::operation::grid::Cell::forceExit | ( | ) |
Force the last Coordinate processed (via take) to be considered as an exit point, provided that it lies on the boundary of this Cell.
| std::unique_ptr< geom::Geometry > geos::operation::grid::Cell::getCoveredPolygons | ( | const geom::GeometryFactory & | ) | const |
Return a newly constructed geometry representing the portion of this Cell that is covered by a polygon
| Traversal & geos::operation::grid::Cell::getLastTraversal | ( | ) |
Return the last (most recent) traversal to which a coordinate has been added. The traversal may or may not be completed.
| bool geos::operation::grid::Cell::isDetermined | ( | ) | const |
Returns whether the cell can be determined to be wholly or partially covered by a polygon.
| bool geos::operation::grid::Cell::take | ( | const geom::CoordinateXY & | c, |
| const geom::CoordinateXY * | prev_original, | ||
| bool | exitOnBoundary, | ||
| const void * | parentage | ||
| ) |
Attempt to take a coordinate and add it to a Traversal in progress, or start a new Traversal
| c | Coordinate to process |
| prev_original | The last uninterpolated coordinate preceding c in the boundary being processed |
| exitOnBoundary | Whether to exit the cell if c lies on the boundary. This is needed to ensure that exit nodes are added to both polygons whose shared boundary is coincident with the Cell boundary. If these nodes are not needed (for example, in the area-only case), it is more efficient to not exit the cell. |
| parentage | an optional pointer indicating the source of the coordinate. |
true if the Coordinate was inside this cell, false otherwise