|
GEOS 3.15.1
|
C API for the GEOS geometry algorithms library. More...
#include <stddef.h>#include <geos/export.h>Go to the source code of this file.
Typedefs | |
| typedef struct GEOSContextHandle_HS * | GEOSContextHandle_t |
| typedef void(*) | GEOSMessageHandler(GEOS_PRINTF_FORMAT const char *fmt,...) GEOS_PRINTF_FORMAT_ATTR(1 |
| typedef void typedef void(*) | GEOSMessageHandler_r(const char *message, void *userdata) |
| typedef void | GEOSProgressCallback(double progressRatio, const char *message, void *userdata) |
| typedef struct GEOSGeom_t | GEOSGeometry |
| typedef struct GEOSPrepGeom_t | GEOSPreparedGeometry |
| typedef struct GEOSCoordSeq_t | GEOSCoordSequence |
| typedef struct GEOSSTRtree_t | GEOSSTRtree |
| typedef struct GEOSBufParams_t | GEOSBufferParams |
| typedef struct GEOSCoverageCleanParams_t | GEOSCoverageCleanParams |
| typedef struct GEOSMakeValidParams_t | GEOSMakeValidParams |
| typedef struct GEOSClusterInfo_t | GEOSClusterInfo |
| typedef struct GEOSCurveToLineParams_t | GEOSCurveToLineParams |
| typedef struct GEOSLineToCurveParams_t | GEOSLineToCurveParams |
| typedef void(*) | GEOSQueryCallback(void *item, void *userdata) |
| typedef int(*) | GEOSDistanceCallback(const void *item1, const void *item2, double *distance, void *userdata) |
| typedef int(*) | GEOSTransformXYCallback(double *x, double *y, void *userdata) |
| typedef int(*) | GEOSTransformXYZCallback(double *x, double *y, double *z, void *userdata) |
| typedef void | GEOSInterruptCallback(void) |
| typedef int | GEOSContextInterruptCallback(void *) |
| typedef struct GEOSWKTReader_t | GEOSWKTReader |
| typedef struct GEOSWKTWriter_t | GEOSWKTWriter |
| typedef struct GEOSWKBReader_t | GEOSWKBReader |
| typedef struct GEOSWKBWriter_t | GEOSWKBWriter |
| typedef struct GEOSGeoJSONReader_t | GEOSGeoJSONReader |
| typedef struct GEOSGeoJSONWriter_t | GEOSGeoJSONWriter |
Clustering | |
| GEOSClusterInfo * | GEOSClusterDBSCAN (const GEOSGeometry *g, double eps, unsigned minPoints) |
| GEOSClusterDBSCAN. | |
| GEOSClusterInfo * | GEOSClusterGeometryDistance (const GEOSGeometry *g, double d) |
| GEOSClusterGeometryDistance. | |
| GEOSClusterInfo * | GEOSClusterGeometryIntersects (const GEOSGeometry *g) |
| GEOSClusterGeometryIntersects. | |
| GEOSClusterInfo * | GEOSClusterEnvelopeDistance (const GEOSGeometry *g, double d) |
| GEOSClusterEnvelopeDistance. | |
| GEOSClusterInfo * | GEOSClusterEnvelopeIntersects (const GEOSGeometry *g) |
| GEOSClusterEnvelopeIntersects. | |
| size_t | GEOSClusterInfo_getNumClusters (const GEOSClusterInfo *clusters) |
| GEOSClusterInfo_getNumClusters. | |
| size_t | GEOSClusterInfo_getClusterSize (const GEOSClusterInfo *clusters, size_t i) |
| GEOSClusterInfo_getSize. | |
| size_t * | GEOSClusterInfo_getClustersForInputs (const GEOSClusterInfo *clusters) |
| GEOSClusterInfo_getClustersForInputs. | |
| const size_t * | GEOSClusterInfo_getInputsForClusterN (const GEOSClusterInfo *clusters, size_t i) |
| GEOSClusterInfo_getInputsForClusterN. | |
| void | GEOSClusterInfo_destroy (GEOSClusterInfo *clusters) |
| GEOSClusterInfo_destroy. | |
C API for the GEOS geometry algorithms library.
The C API is the supported API for using GEOS in your application/library/etc. The C API is kept stable, and deprecated function signatures are kept available over a long time period to allow transition time. While the C++ API is available, it may change at any time, and the ABI may not be stable between versions.
Important programming notes:
| typedef struct GEOSBufParams_t GEOSBufferParams |
Parameter object for buffering.
| typedef struct GEOSClusterInfo_t GEOSClusterInfo |
Object containing information about cluster of geometries.
| typedef struct GEOSContextHandle_HS* GEOSContextHandle_t |
Type returned by GEOS_init_r(), for use with the functions ending in _r (the reentrant API).
Contexts must only be used from a single thread at a time.
| typedef int GEOSContextInterruptCallback(void *) |
Callback function for use in interruption. The callback will be invoked at each possible interruption point and can be used to request interruption by returning a non-zero value.
| typedef struct GEOSCoordSeq_t GEOSCoordSequence |
Coordinate sequence type representing fixed-size lists of coordinates. Contains the list of vertices defining the location of a GEOSGeometry.
| typedef struct GEOSCoverageCleanParams_t GEOSCoverageCleanParams |
Parameter object for coverage cleaning options.
| typedef struct GEOSCurveToLineParams_t GEOSCurveToLineParams |
Parameter object for curve-to-line conversion
| typedef int(*) GEOSDistanceCallback(const void *item1, const void *item2, double *distance, void *userdata) |
Callback function for use in spatial index nearest neighbor calculations. Allows custom distance to be calculated between items in the index. Is passed two items, and sets the calculated distance between the items into the distance pointer. Extra data for the calculation can be passed via the userdata.
| item1 | first of the pair of items to calculate distance between |
| item2 | second of the pair of items to calculate distance between |
| distance | the distance between the items here |
| userdata | extra data for the calculation |
| typedef struct GEOSGeoJSONReader_t GEOSGeoJSONReader |
Reader object to read GeoJSON format and construct a Geometry.
| typedef struct GEOSGeoJSONWriter_t GEOSGeoJSONWriter |
Writer object to turn a Geometry into GeoJSON.
| typedef struct GEOSGeom_t GEOSGeometry |
The generic type for a geometry. A geometry can be a Point, LineString, Polygon, MultiPoint, MultiLineString, MultiPolygon, or GeometryCollection. The geometry type can be read with GEOSGeomTypeId. Most functions in GEOS have GEOSGeometry * as either a parameter or a return type.
| typedef void GEOSInterruptCallback(void) |
Callback function for use in interruption. The callback will be invoked at each possible interruption point and can be used to request interruption.
| typedef struct GEOSLineToCurveParams_t GEOSLineToCurveParams |
Parameter object for line-to-curve conversion
| typedef struct GEOSMakeValidParams_t GEOSMakeValidParams |
Parameter object for validity enforcement.
| typedef void(*) GEOSMessageHandler(GEOS_PRINTF_FORMAT const char *fmt,...) GEOS_PRINTF_FORMAT_ATTR(1 |
Callback function for passing GEOS error messages to parent process.
Set the GEOSMessageHandler function for error and notice messages using initGEOS or initGEOS_r.
| fmt | the message format template |
| typedef void typedef void(*) GEOSMessageHandler_r(const char *message, void *userdata) |
A GEOS message handler function.
| message | the message contents |
| userdata | the user data pointer that was passed to GEOS when registering this message handler. |
| typedef struct GEOSPrepGeom_t GEOSPreparedGeometry |
Prepared geometry type.
| typedef void GEOSProgressCallback(double progressRatio, const char *message, void *userdata) |
A GEOS progress callback function.
Such function takes a progress ratio (0 to 1), and an optional message.
| progressRatio | Progression ratio (between 0 and 1) |
| message | Information message (can be NULL) |
| userdata | the user data pointer that was passed to GEOS together with this callback. |
| typedef void(*) GEOSQueryCallback(void *item, void *userdata) |
Callback function for use in spatial index search calls. Pass into the query function and handle query results as the index returns them.
| typedef struct GEOSSTRtree_t GEOSSTRtree |
STRTree index.
| typedef int(*) GEOSTransformXYCallback(double *x, double *y, void *userdata) |
Callback function for use in GEOSGeom_transformXY. Allows custom function to be applied to x and y values for each coordinate in a geometry. Z and M values are unchanged by this function. Extra data for the calculation can be passed via the userdata.
| x | coordinate value to be updated |
| y | coordinate value to be updated |
| userdata | extra data for the calculation |
| typedef int(*) GEOSTransformXYZCallback(double *x, double *y, double *z, void *userdata) |
Callback function for use in GEOSGeom_transformXYZ. Allows custom function to be applied to x, y and z values for each coordinate in a geometry. M values are unchanged by this function. Extra data for the calculation can be passed via the userdata.
| x | coordinate value to be updated |
| y | coordinate value to be updated |
| z | coordinate value to be updated |
| userdata | extra data for the calculation |
| typedef struct GEOSWKBReader_t GEOSWKBReader |
Reader object to read Well-Known Binary (WKB) format and construct Geometry.
| typedef struct GEOSWKBWriter_t GEOSWKBWriter |
Writer object to turn Geometry into Well-Known Binary (WKB).
| typedef struct GEOSWKTReader_t GEOSWKTReader |
Reader object to read Well-Known Text (WKT) format and construct Geometry.
| typedef struct GEOSWKTWriter_t GEOSWKTWriter |
Writer object to turn Geometry into Well-Known Text (WKT).
| enum GEOSBufCapStyles |
Cap styles control the ends of buffered lines.
| enum GEOSBufJoinStyles |
Join styles control the buffer shape at bends in a line.
| enum GEOSGeomTypes |
Geometry type number, used by functions returning or consuming geometry types.
| enum GEOSMakeValidMethods |
Algorithm to use when repairing invalid geometries.
| enum GEOSOverlapMerge |
Overlap repair strategies.
| enum GEOSPrecisionRules |
Controls the behavior of GEOSGeom_setPrecision() when altering the precision of a geometry.
Controls the behavior of the result of GEOSRelate when returning DE9IM results for two geometries.
| Enumerator | |
|---|---|
| GEOSRELATE_BNR_MOD2 | See geos::algorithm::BoundaryNodeRule::getBoundaryRuleMod2() |
| GEOSRELATE_BNR_OGC | Same as GEOSRELATE_BNR_MOD2 |
| GEOSRELATE_BNR_ENDPOINT | See geos::algorithm::BoundaryNodeRule::getBoundaryEndPoint() |
| GEOSRELATE_BNR_MULTIVALENT_ENDPOINT | See geos::algorithm::BoundaryNodeRule::getBoundaryMultivalentEndPoint() |
| GEOSRELATE_BNR_MONOVALENT_ENDPOINT | See geos::algorithm::BoundaryNodeRule::getBoundaryMonovalentEndPoint() |
| enum GEOSValidFlags |
Change behaviour of validity testing in GEOSisValidDetail
| Enumerator | |
|---|---|
| GEOSVALID_ALLOW_SELFTOUCHING_RING_FORMING_HOLE | Allow self-touching rings to form a hole in a polygon. |
| enum GEOSVoronoiFlags |
Change behaviour of GEOSVoronoiDiagram
| Enumerator | |
|---|---|
| GEOS_VORONOI_ONLY_EDGES | Return only edges of the Voronoi cells, as a MultiLineString |
| GEOS_VORONOI_PRESERVE_ORDER | Preserve order of inputs, such that the nth cell in the result corresponds to the nth vertex in the input. If this cannot be done, such as for inputs that contain repeated points, GEOSVoronoiDiagram will return NULL. |
| enum GEOSWKBByteOrders |
Well-known binary byte orders used when writing to WKB.
| Enumerator | |
|---|---|
| GEOS_WKB_XDR | Big Endian |
| GEOS_WKB_NDR | Little Endian |
| enum GEOSWKBFlavors |
Well-known binary flavors to use when writing to WKB. ISO flavour is more standard. Extended flavour supports 3D and SRID embedding. GEOS reads both transparently.
| Enumerator | |
|---|---|
| GEOS_WKB_EXTENDED | Extended |
| GEOS_WKB_ISO | ISO |
|
extern |
For non-reentrant code, call when all GEOS operations are complete, cleans up global resources.
References finishGEOS().
Referenced by finishGEOS().
|
extern |
References finishGEOS_r().
Referenced by finishGEOS_r().
|
extern |
Free the memory associated with a GEOSContextHandle_t when you are finished calling GEOS functions.
| handle | to be freed |
References GEOS_finish_r().
Referenced by GEOS_finish_r().
|
extern |
References GEOS_getWKBByteOrder().
Referenced by GEOS_getWKBByteOrder().
|
extern |
References GEOS_getWKBByteOrder_r().
Referenced by GEOS_getWKBByteOrder_r().
|
extern |
References GEOS_getWKBOutputDims().
Referenced by GEOS_getWKBOutputDims().
|
extern |
References GEOS_getWKBOutputDims_r().
Referenced by GEOS_getWKBOutputDims_r().
|
extern |
Allocate and initialize a context. Pass this context as the first argument when calling other *_r functions. Contexts must only be used from a single thread at a time.
References GEOS_init_r().
Referenced by GEOS_init_r().
|
extern |
Cancel a pending interruption request
References GEOS_interruptCancel().
Referenced by GEOS_interruptCancel().
|
extern |
Register a function to be called when a possible interruption point is reached on any thread. The function may be used to request interruption.
| cb | Callback function to invoke |
References GEOS_interruptRegisterCallback().
Referenced by GEOS_interruptRegisterCallback().
|
extern |
Request safe interruption of operations. The next thread to check for an interrupt will be interrupted. To request interruption of a specific thread, instead call GEOS_interruptThread() from a callback executed by that thread.
References GEOS_interruptRequest().
Referenced by GEOS_interruptRequest().
|
extern |
Print the shortest representation of a double. Non-zero absolute values that are <1e-4 and >=1e+17 are formatted using scientific notation, and other values are formatted with positional notation with precision used for the max digits after decimal point.
| d | The number to format. |
| precision | The desired precision. |
| result | The buffer to write the result to, with a suggested size 28. |
References GEOS_printDouble().
Referenced by GEOS_printDouble().
|
extern |
References GEOS_setWKBByteOrder().
Referenced by GEOS_setWKBByteOrder().
|
extern |
References GEOS_setWKBByteOrder_r().
Referenced by GEOS_setWKBByteOrder_r().
|
extern |
References GEOS_setWKBOutputDims().
Referenced by GEOS_setWKBOutputDims().
|
extern |
References GEOS_setWKBOutputDims_r().
Referenced by GEOS_setWKBOutputDims_r().
|
extern |
Calculate the area of a geometry.
Curved geometry types are supported since GEOS 3.13.
Area is calculated in the XY plane; Z and M values are ignored.
| [in] | g | Input geometry |
| [out] | area | Pointer to be filled in with area result |
References GEOSArea().
Referenced by GEOSArea().
|
extern |
|
extern |
Returns the "boundary" of a geometry, as defined by the DE9IM:
Z and M values in the input coordinates are preserved.
Curved geometry types are supported as of GEOS 3.15.
| g | The input geometry |
References GEOSBoundary().
Referenced by GEOSBoundary().
|
extern |
|
extern |
Buffer a geometry. The coordinates of the constructed geometry will not have Z or M values.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The input geometry to be buffered. |
| width | The distance by which to expand the geometry (or contract) if the value is negative. |
| quadsegs | The number of segments per quadrant to generate. More segments provides a more "precise" buffer at the expense of size. |
References GEOSBuffer().
Referenced by GEOSBuffer().
|
extern |
|
extern |
Create a default GEOSBufferParams object for controlling the shape of buffered generated by GEOSBuffer.
References GEOSBufferParams_create().
Referenced by GEOSBufferParams_create().
|
extern |
References GEOSBufferParams_create_r().
Referenced by GEOSBufferParams_create_r().
|
extern |
Destroy a GEOSBufferParams and free all associated memory.
| parms | The object to destroy. |
References GEOSBufferParams_destroy().
Referenced by GEOSBufferParams_destroy().
|
extern |
References GEOSBufferParams_destroy_r().
Referenced by GEOSBufferParams_destroy_r().
|
extern |
Set the end cap type of a GEOSBufferParams to the desired style, which must be one enumerated in GEOSBufCapStyles.
References GEOSBufferParams_setEndCapStyle().
Referenced by GEOSBufferParams_setEndCapStyle().
|
extern |
References GEOSBufferParams_setEndCapStyle_r().
Referenced by GEOSBufferParams_setEndCapStyle_r().
|
extern |
Set the join type of a GEOSBufferParams to the desired style, which must be one enumerated in GEOSBufJoinStyles.
References GEOSBufferParams_setJoinStyle().
Referenced by GEOSBufferParams_setJoinStyle().
|
extern |
References GEOSBufferParams_setJoinStyle_r().
Referenced by GEOSBufferParams_setJoinStyle_r().
|
extern |
Set the mitre limit of a GEOSBufferParams to the desired size. For acute angles, a mitre join can extend very very far from the input geometry, which is probably not desired. The mitre limit places an upper bound on that.
| p | The GEOSBufferParams to operate on |
| mitreLimit | The limit to set |
References GEOSBufferParams_setMitreLimit().
Referenced by GEOSBufferParams_setMitreLimit().
|
extern |
References GEOSBufferParams_setMitreLimit_r().
Referenced by GEOSBufferParams_setMitreLimit_r().
|
extern |
Set the number of segments to use to stroke each quadrant of circular arcs generated by the buffering process. More segments means a smoother output, but with larger size.
| p | The GEOSBufferParams to operate on |
| quadSegs | Number of segments per quadrant |
References GEOSBufferParams_setQuadrantSegments().
Referenced by GEOSBufferParams_setQuadrantSegments().
|
extern |
References GEOSBufferParams_setQuadrantSegments_r().
Referenced by GEOSBufferParams_setQuadrantSegments_r().
|
extern |
Sets whether the computed buffer should be single-sided. A single-sided buffer is constructed on only one side of each input line.
| p | The GEOSBufferParams to operate on |
| singleSided | Set to 1 for single-sided output 0 otherwise |
References GEOSBufferParams_setSingleSided().
Referenced by GEOSBufferParams_setSingleSided().
|
extern |
References GEOSBufferParams_setSingleSided_r().
Referenced by GEOSBufferParams_setSingleSided_r().
|
extern |
Generates a buffer using the special parameters in the GEOSBufferParams
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The geometry to buffer |
| p | The parameters to apply to the buffer process |
| width | The buffer distance |
References GEOSBufferWithParams().
Referenced by GEOSBufferWithParams().
|
extern |
References GEOSBufferWithParams_r().
Referenced by GEOSBufferWithParams_r().
|
extern |
Generate a buffer using the provided style parameters. The coordinates of the constructed geometry will not have Z or M values.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The geometry to buffer |
| width | Width of the buffer |
| quadsegs | Number of segments per quadrant |
| endCapStyle | See GEOSBufCapStyles |
| joinStyle | See GEOSBufJoinStyles |
| mitreLimit | See GEOSBufferParams_setMitreLimit |
References GEOSBufferWithStyle().
Referenced by GEOSBufferWithStyle().
|
extern |
References GEOSBufferWithStyle_r().
Referenced by GEOSBufferWithStyle_r().
|
extern |
Perform a polygonization using all the linework, assuming that rings contained within rings are empty holes, rather then extra polygons.
| g | The input linework |
References GEOSBuildArea().
Referenced by GEOSBuildArea().
|
extern |
|
extern |
Intersection optimized for a rectangular clipping polygon. Supposed to be faster than using GEOSIntersection(). Not guaranteed to return valid results.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g | The input geometry to be clipped |
| xmin | Left bound of clipping rectangle |
| ymin | Lower bound of clipping rectangle |
| xmax | Right bound of clipping rectangle |
| ymax | Upper bound of clipping rectangle |
References GEOSClipByRect().
Referenced by GEOSClipByRect().
|
extern |
|
extern |
GEOSClusterDBSCAN.
Cluster geometries using the DBSCAN algorithm
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | a collection of geometries to be clustered |
| eps | distance parameter for clustering |
| minPoints | density parameter for clustering |
References GEOSClusterDBSCAN().
Referenced by GEOSClusterDBSCAN().
|
extern |
|
extern |
GEOSClusterEnvelopeDistance.
Cluster geometries according to an envelope distance threshold
This function supports curved geometry types.
| g | a collection of geometries to be clustered |
| d | minimum envelope distance between geometries in the same cluster |
References GEOSClusterEnvelopeDistance().
Referenced by GEOSClusterEnvelopeDistance().
|
extern |
References GEOSClusterEnvelopeDistance_r().
Referenced by GEOSClusterEnvelopeDistance_r().
|
extern |
GEOSClusterEnvelopeIntersects.
Cluster geometries whose envelopes intersect
This function supports curved geometry types.
| g |
References GEOSClusterEnvelopeIntersects().
Referenced by GEOSClusterEnvelopeIntersects().
|
extern |
References GEOSClusterEnvelopeIntersects_r().
Referenced by GEOSClusterEnvelopeIntersects_r().
|
extern |
GEOSClusterGeometryDistance.
Cluster geometries according to a distance threshold
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | a collection of geometries to be clustered |
| d | minimum distance between geometries in the same cluster |
References GEOSClusterGeometryDistance().
Referenced by GEOSClusterGeometryDistance().
|
extern |
References GEOSClusterGeometryDistance_r().
Referenced by GEOSClusterGeometryDistance_r().
|
extern |
GEOSClusterGeometryIntersects.
Cluster geometries that intersect
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | a collection of geometries to be clustered |
References GEOSClusterGeometryIntersects().
Referenced by GEOSClusterGeometryIntersects().
|
extern |
References GEOSClusterGeometryIntersects_r().
Referenced by GEOSClusterGeometryIntersects_r().
|
extern |
GEOSClusterInfo_destroy.
Destroy a cluster information object.
| clusters | cluster information object |
References GEOSClusterInfo_destroy().
Referenced by GEOSClusterInfo_destroy().
|
extern |
References GEOSClusterInfo_destroy_r().
Referenced by GEOSClusterInfo_destroy_r().
|
extern |
GEOSClusterInfo_getClustersForInputs.
Get the cluster index associated with each input to the clustering operation. Inputs that do are not associated with any cluster will have an index of GEOS_CLUSTER_NONE.
| clusters | cluster information object |
References GEOSClusterInfo_getClustersForInputs().
Referenced by GEOSClusterInfo_getClustersForInputs().
|
extern |
References GEOSClusterInfo_getClustersForInputs_r().
Referenced by GEOSClusterInfo_getClustersForInputs_r().
|
extern |
GEOSClusterInfo_getSize.
Get the number of elements in the ith cluster (0-indexed)
| clusters | cluster information object |
| i | cluster for which a size will be returned |
References GEOSClusterInfo_getClusterSize().
Referenced by GEOSClusterInfo_getClusterSize().
|
extern |
References GEOSClusterInfo_getClusterSize_r().
Referenced by GEOSClusterInfo_getClusterSize_r().
|
extern |
GEOSClusterInfo_getInputsForClusterN.
| clusters | cluster information object |
| i | index of the cluster for which indices should be retrieved |
References GEOSClusterInfo_getInputsForClusterN().
Referenced by GEOSClusterInfo_getInputsForClusterN().
|
extern |
References GEOSClusterInfo_getInputsForClusterN_r().
Referenced by GEOSClusterInfo_getInputsForClusterN_r().
|
extern |
GEOSClusterInfo_getNumClusters.
Get the number of clusters identified by a clustering operation
| clusters | cluster information object |
References GEOSClusterInfo_getNumClusters().
Referenced by GEOSClusterInfo_getNumClusters().
|
extern |
References GEOSClusterInfo_getNumClusters_r().
Referenced by GEOSClusterInfo_getNumClusters_r().
|
extern |
Returns a "concave hull" of a geometry. A concave hull is a polygon which contains all the points of the input, but is a better approximation than the convex hull to the area occupied by the input. Frequently used to convert a multi-point into a polygonal area. that contains all the points in the input Geometry.
Z values in the input coordinates will be preserved. M values in the input coordinates will not be preserved.
A set of points has a sequence of hulls of increasing concaveness, determined by a numeric target parameter. The concave hull is constructed by removing the longest outer edges of the Delaunay Triangulation of the space between the polygons, until the target criterion parameter is reached. This can be expressed as a ratio between the lengths of the longest and shortest edges. 1 produces the convex hull; 0 produces a hull with maximum concaveness
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The input geometry |
| ratio | The edge length ratio value, between 0 and 1. |
| allowHoles | When non-zero, the polygonal output may contain holes. |
Caller is responsible for freeing with GEOSGeom_destroy().
References GEOSConcaveHull().
Referenced by GEOSConcaveHull().
|
extern |
|
extern |
Returns a "concave hull" of a geometry. A concave hull is a polygon which contains all the points of the input, but is a better approximation than the convex hull to the area occupied by the input. Frequently used to convert a multi-point into a polygonal area. that contains all the points in the input Geometry.
Z values in the input coordinates will be preserved. M values in the input coordinates will not be preserved.
A set of points has a sequence of hulls of increasing concaveness, determined by a numeric target parameter. The concave hull is constructed by removing the longest outer edges of the Delaunay Triangulation of the space between the polygons, until the specified maximum edge length is reached. A large value produces the convex hull, 0 produces the hull of maximum concaveness.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The input geometry |
| length | The maximum edge length (0 or greater) |
| allowHoles | When non-zero, the polygonal output may contain holes. |
Caller is responsible for freeing with GEOSGeom_destroy().
References GEOSConcaveHullByLength().
Referenced by GEOSConcaveHullByLength().
|
extern |
References GEOSConcaveHullByLength_r().
Referenced by GEOSConcaveHullByLength_r().
|
extern |
Constructs a concave hull of a set of polygons, respecting the polygons as constraints.
A concave hull is a (possibly) non-convex polygon containing all the input polygons. The computed hull "fills the gap" between the polygons, and does not intersect their interior. A set of polygons has a sequence of hulls of increasing concaveness, determined by a numeric target parameter.
The concave hull is constructed by removing the longest outer edges of the Delaunay Triangulation of the space between the polygons, until the target criterion parameter is reached. The "Maximum Edge Length" parameter limits the length of the longest edge between polygons to be no larger than this value. This can be expressed as a ratio between the lengths of the longest and shortest edges.
The input polygons must be a valid MultiPolygon (i.e. they must be non-overlapping).
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | the valid MultiPolygon geometry to process |
| lengthRatio | specifies the Maximum Edge Length as a fraction of the difference between the longest and shortest edge lengths between the polygons. This normalizes the Maximum Edge Length to be scale-free. A value of 1 produces the convex hull; a value of 0 produces the original polygons. |
| isTight | does the hull follow the outer boundaries of the input polygons? |
| isHolesAllowed | is the concave hull allowed to contain holes? |
Caller is responsible for freeing with GEOSGeom_destroy().
References GEOSConcaveHullOfPolygons().
Referenced by GEOSConcaveHullOfPolygons().
|
extern |
References GEOSConcaveHullOfPolygons_r().
Referenced by GEOSConcaveHullOfPolygons_r().
|
extern |
Return a constrained Delaunay triangulation of the vertices of the given polygon(s). For non-polygonal inputs, returns an empty geometry collection.
Z values from the input points will be propagated to the generated polygons. M values from the input points will be ignored.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | the input geometry whose rings will be used as input |
References GEOSConstrainedDelaunayTriangulation().
Referenced by GEOSConstrainedDelaunayTriangulation().
|
extern |
References GEOSConstrainedDelaunayTriangulation_r().
Referenced by GEOSConstrainedDelaunayTriangulation_r().
|
extern |
Tests if geometry g2 is completely within g1, but not wholly contained in the boundary of g1.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSContains().
Referenced by GEOSContains().
|
extern |
|
extern |
Set parameters to use for converting input curves to lines.
These parameters will be used with this context whenever a curved geometry is provided to a function that only supports linear types. If params is NULL, no automatic conversion will be performed.
| extHandle | the GEOS context |
| params | the curve conversion parameters |
References GEOSContext_setCurveToLineParams_r().
Referenced by GEOSContext_setCurveToLineParams_r().
|
extern |
Set the notice handler callback function for run-time error messages.
| extHandle | the GEOS context from GEOS_init_r |
| ef | the handler callback |
References GEOSContext_setErrorHandler_r().
Referenced by GEOSContext_setErrorHandler_r().
|
extern |
Sets an error message handler on the given GEOS context.
| extHandle | the GEOS context |
| ef | the message handler |
| userData | optional user data pointer that will be passed to the message handler |
References GEOSContext_setErrorMessageHandler_r().
Referenced by GEOSContext_setErrorMessageHandler_r().
|
extern |
Register a function to be called when a possible interruption point is reached in code executed in the specified context. The function can interrupt the thread if desired by returning True.
| extHandle | the context returned by GEOS_init_r. |
| cb | Callback function to invoke |
| userData | optional data to be pe provided as argument to callback |
References GEOSContext_setInterruptCallback_r().
Referenced by GEOSContext_setInterruptCallback_r().
|
extern |
Set parameters to use for converting output lines to curves.
These parameters will be used with this context whenever a curved geometry is provided to a function that only supports linear types. If params is NULL, no automatic conversion will be performed.
| extHandle | the GEOS context |
| params | the curve conversion parameters |
References GEOSContext_setLineToCurveParams_r().
Referenced by GEOSContext_setLineToCurveParams_r().
|
extern |
Set the notice handler callback function for run-time notice messages.
| extHandle | the context returned by GEOS_init_r. |
| nf | the handler callback |
References GEOSContext_setNoticeHandler_r().
Referenced by GEOSContext_setNoticeHandler_r().
|
extern |
Sets a notice message handler on the given GEOS context.
| extHandle | the GEOS context from GEOS_init_r |
| nf | the message handler |
| userData | optional user data pointer that will be passed to the message handler |
References GEOSContext_setNoticeMessageHandler_r().
Referenced by GEOSContext_setNoticeMessageHandler_r().
|
extern |
Register a function to be called with progress updates
| extHandle | the context returned by GEOS_init_r. |
| cb | Callback function to invoke |
| userData | optional data to be pe provided as argument to callback |
References GEOSContext_setProgressCallback_r().
Referenced by GEOSContext_setProgressCallback_r().
|
extern |
Returns the convex hull of a geometry. The smallest convex Geometry that contains all the points in the input Geometry
Z values in the input coordinates will be preserved. M values in the input coordinates will not be preserved.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The input geometry |
References GEOSConvexHull().
Referenced by GEOSConvexHull().
|
extern |
|
extern |
Clone a coordinate sequence.
| s | the coordinate sequence to clone |
References GEOSCoordSeq_clone().
Referenced by GEOSCoordSeq_clone().
|
extern |
|
extern |
Create a coordinate sequence by copying from arrays of doubles
| x | array of x coordinates |
| y | array of y coordinates |
| z | array of z coordinates, or NULL |
| m | array of m coordinates, or NULL |
| size | length of each array |
References GEOSCoordSeq_copyFromArrays().
Referenced by GEOSCoordSeq_copyFromArrays().
|
extern |
References GEOSCoordSeq_copyFromArrays_r().
Referenced by GEOSCoordSeq_copyFromArrays_r().
|
extern |
Create a coordinate sequence by copying from an interleaved buffer of doubles (e.g., XYXY or XYZXYZ)
| buf | pointer to buffer |
| size | number of coordinates in the sequence |
| hasZ | does buffer have Z values? |
| hasM | does buffer have M values? |
References GEOSCoordSeq_copyFromBuffer().
Referenced by GEOSCoordSeq_copyFromBuffer().
|
extern |
References GEOSCoordSeq_copyFromBuffer_r().
Referenced by GEOSCoordSeq_copyFromBuffer_r().
|
extern |
Copy the contents of a coordinate sequence to arrays of doubles
| s | sequence to copy |
| x | array to which x values should be copied |
| y | array to which y values should be copied |
| z | array to which z values should be copied, or NULL |
| m | array to which m values should be copied, or NULL |
References GEOSCoordSeq_copyToArrays().
Referenced by GEOSCoordSeq_copyToArrays().
|
extern |
References GEOSCoordSeq_copyToArrays_r().
Referenced by GEOSCoordSeq_copyToArrays_r().
|
extern |
Copy the contents of a coordinate sequence to an interleaved buffer of doubles (e.g., XYXY or XYZXYZ)
| s | sequence to copy |
| buf | buffer to which coordinates should be copied |
| hasZ | copy Z values to buffer? |
| hasM | copy M values to buffer? |
References GEOSCoordSeq_copyToBuffer().
Referenced by GEOSCoordSeq_copyToBuffer().
|
extern |
References GEOSCoordSeq_copyToBuffer_r().
Referenced by GEOSCoordSeq_copyToBuffer_r().
|
extern |
Create a coordinate sequence.
| size | number of coordinates in the sequence |
| dims | dimensionality of the coordinates (2, 3 or 4) |
References GEOSCoordSeq_create().
Referenced by GEOSCoordSeq_create().
|
extern |
References GEOSCoordSeq_create_r().
Referenced by GEOSCoordSeq_create_r().
|
extern |
Create a coordinate sequence.
| size | number of coordinates in the sequence |
| hasZ | whether the sequence should store Z values |
| hasM | whether the sequence should store M values |
References GEOSCoordSeq_createWithDimensions().
Referenced by GEOSCoordSeq_createWithDimensions().
|
extern |
References GEOSCoordSeq_createWithDimensions_r().
Referenced by GEOSCoordSeq_createWithDimensions_r().
|
extern |
Destroy a coordinate sequence, freeing all memory.
| s | the coordinate sequence to destroy |
References GEOSCoordSeq_destroy().
Referenced by GEOSCoordSeq_destroy().
|
extern |
References GEOSCoordSeq_destroy_r().
Referenced by GEOSCoordSeq_destroy_r().
|
extern |
Get dimension info from a coordinate sequence.
| [in] | s | the coordinate sequence |
| [out] | dims | pointer where dimension value will be placed |
References GEOSCoordSeq_getDimensions().
Referenced by GEOSCoordSeq_getDimensions().
|
extern |
References GEOSCoordSeq_getDimensions_r().
Referenced by GEOSCoordSeq_getDimensions_r().
|
extern |
Read M ordinate values from a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| val | pointer where ordinate value will be placed |
References GEOSCoordSeq_getM().
Referenced by GEOSCoordSeq_getM().
|
extern |
|
extern |
Read Nth ordinate value from a coordinate sequence.
| [in] | s | the coordinate sequence |
| [in] | idx | the index of the coordinate to alter, zero based |
| [in] | dim | the dimension number of the ordinate to read, zero based |
| [out] | val | pointer where ordinate value will be placed |
References GEOSCoordSeq_getOrdinate().
Referenced by GEOSCoordSeq_getOrdinate().
|
extern |
References GEOSCoordSeq_getOrdinate_r().
Referenced by GEOSCoordSeq_getOrdinate_r().
|
extern |
Get size info from a coordinate sequence.
| [in] | s | the coordinate sequence |
| [out] | size | pointer where size value will be placed |
References GEOSCoordSeq_getSize().
Referenced by GEOSCoordSeq_getSize().
|
extern |
References GEOSCoordSeq_getSize_r().
Referenced by GEOSCoordSeq_getSize_r().
|
extern |
Read X ordinate values from a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| val | pointer where ordinate value will be placed |
References GEOSCoordSeq_getX().
Referenced by GEOSCoordSeq_getX().
|
extern |
|
extern |
Read X and Y ordinate values from a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| x | pointer where ordinate X value will be placed |
| y | pointer where ordinate Y value will be placed |
References GEOSCoordSeq_getXY().
Referenced by GEOSCoordSeq_getXY().
|
extern |
|
extern |
Read X and Y ordinate values from a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| x | pointer where ordinate X value will be placed |
| y | pointer where ordinate Y value will be placed |
| z | pointer where ordinate Z value will be placed |
References GEOSCoordSeq_getXYZ().
Referenced by GEOSCoordSeq_getXYZ().
|
extern |
References GEOSCoordSeq_getXYZ_r().
Referenced by GEOSCoordSeq_getXYZ_r().
|
extern |
Read Y ordinate values from a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| val | pointer where ordinate value will be placed |
References GEOSCoordSeq_getY().
Referenced by GEOSCoordSeq_getY().
|
extern |
|
extern |
Read Z ordinate values from a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| val | pointer where ordinate value will be placed |
References GEOSCoordSeq_getZ().
Referenced by GEOSCoordSeq_getZ().
|
extern |
|
extern |
Tests whether the input coordinate sequence has M coordinates.
| s | the coordinate sequence to test |
References GEOSCoordSeq_hasM().
Referenced by GEOSCoordSeq_hasM().
|
extern |
|
extern |
Tests whether the input coordinate sequence has Z coordinates.
| s | the coordinate sequence to test |
References GEOSCoordSeq_hasZ().
Referenced by GEOSCoordSeq_hasZ().
|
extern |
|
extern |
Check orientation of a coordinate sequence. Closure of the sequence is assumed. Invalid (collapsed) or short (fewer than 4 points) sequences return false.
| s | the coordinate sequence |
| is_ccw | pointer for ccw value, 1 if counter-clockwise orientation, 0 otherwise |
References GEOSCoordSeq_isCCW().
Referenced by GEOSCoordSeq_isCCW().
|
extern |
|
extern |
Set M ordinate values in a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| val | the value to set the ordinate to |
References GEOSCoordSeq_setM().
Referenced by GEOSCoordSeq_setM().
|
extern |
|
extern |
Set Nth ordinate value in a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| dim | the dimension number of the ordinate to alter, zero based |
| val | the value to set the ordinate to |
References GEOSCoordSeq_setOrdinate().
Referenced by GEOSCoordSeq_setOrdinate().
|
extern |
References GEOSCoordSeq_setOrdinate_r().
Referenced by GEOSCoordSeq_setOrdinate_r().
|
extern |
Set X ordinate values in a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| val | the value to set the ordinate to |
References GEOSCoordSeq_setX().
Referenced by GEOSCoordSeq_setX().
|
extern |
|
extern |
Set X and Y ordinate values in a coordinate sequence simultaneously.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| x | the value to set the X ordinate to |
| y | the value to set the Y ordinate to |
References GEOSCoordSeq_setXY().
Referenced by GEOSCoordSeq_setXY().
|
extern |
|
extern |
Set X, Y and Z ordinate values in a coordinate sequence simultaneously.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| x | the value to set the X ordinate to |
| y | the value to set the Y ordinate to |
| z | the value to set the Z ordinate to |
References GEOSCoordSeq_setXYZ().
Referenced by GEOSCoordSeq_setXYZ().
|
extern |
References GEOSCoordSeq_setXYZ_r().
Referenced by GEOSCoordSeq_setXYZ_r().
|
extern |
Set Y ordinate values in a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| val | the value to set the ordinate to |
References GEOSCoordSeq_setY().
Referenced by GEOSCoordSeq_setY().
|
extern |
|
extern |
Set Z ordinate values in a coordinate sequence.
| s | the coordinate sequence |
| idx | the index of the coordinate to alter, zero based |
| val | the value to set the ordinate to |
References GEOSCoordSeq_setZ().
Referenced by GEOSCoordSeq_setZ().
|
extern |
|
extern |
References GEOSCoverageClean().
Referenced by GEOSCoverageClean().
|
extern |
|
extern |
Create a default GEOSCoverageCleanParams object for controlling* the way invalid polygon interactions are repaired by GEOSCoverageCleanWithParams.
References GEOSCoverageCleanParams_create().
Referenced by GEOSCoverageCleanParams_create().
|
extern |
References GEOSCoverageCleanParams_create_r().
Referenced by GEOSCoverageCleanParams_create_r().
|
extern |
Destroy a GEOSCoverageCleanParams and free all associated memory.
| params | The object to destroy. |
References GEOSCoverageCleanParams_destroy().
Referenced by GEOSCoverageCleanParams_destroy().
|
extern |
References GEOSCoverageCleanParams_destroy_r().
Referenced by GEOSCoverageCleanParams_destroy_r().
|
extern |
Set the maximum width of gaps to merge when cleaning a coverage.
Gaps wider than the given distance are merged with the adjacent polygon having the longest shared border with the gap. (The overlap merge strategy is not used.)
Gaps are defined as enclosed empty areas with width less than a distance tolerance. Empty holes in input polygons are treated as gaps, and may be filled in. Gaps which are not fully enclosed ("inlets") are not removed.
Width is computed as the diameter of the Maximum Inscribed Circle of the gap polygon. A width of zero prevents gaps from being merged.
| params | The GEOSCoverageCleanParams to operate on |
| gapMaximumWidth | Set to 0.0 for no gap merging. |
References GEOSCoverageCleanParams_setGapMaximumWidth().
Referenced by GEOSCoverageCleanParams_setGapMaximumWidth().
|
extern |
References GEOSCoverageCleanParams_setGapMaximumWidth_r().
Referenced by GEOSCoverageCleanParams_setGapMaximumWidth_r().
|
extern |
Sets the overlap merge strategy to use, using one from GEOSOverlapMerge.
Overlaps are merged with an adjacent polygon chosen according to a specified merge strategy. The supported strategies are:
The default is GEOS_MERGE_LONGEST_BORDER.
| params | The GEOSCoverageCleanParams to operate on |
| overlapMergeStrategy | One of GEOSOverlapMerge strategies |
References GEOSCoverageCleanParams_setOverlapMergeStrategy().
Referenced by GEOSCoverageCleanParams_setOverlapMergeStrategy().
|
extern |
|
extern |
Set the snapping distance to use when cleaning a coverage.
Snapping to nearby vertices and line segment snapping is used to improve noding robustness and eliminate small errors in an efficient way.
By default this uses a very small snapping distance based on the extent of the input data.
Specifying a larger snapping distance can reduce the number of overlaps and gaps that need to be merged, and reduce the risk of spikes formed by merging gaps. However, a large snapping distance can also introduce undesirable data alteration.
A distance of zero prevents snapping from being used.
| params | The GEOSCoverageCleanParams to operate on |
| snappingDistance | Set to 0.0 for no snapping. |
References GEOSCoverageCleanParams_setSnappingDistance().
Referenced by GEOSCoverageCleanParams_setSnappingDistance().
|
extern |
References GEOSCoverageCleanParams_setSnappingDistance_r().
Referenced by GEOSCoverageCleanParams_setSnappingDistance_r().
|
extern |
Clean a coverage.
Operates on a list of polygonal geometry with "exactly matching" edge geometry. Removes any overlaps and fixes cases where the geometry does not in fact exactly match.
The input is a collection of polygons, and the output is a collection with the same number of cleaned polygons, in the same order as the input. Polygons that have collapsed during cleaning will be returned as empties.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| input | The dirty polygonal coverage, stored in a geometry collection. All members must be POLYGON or MULTIPOLYGON. |
| params | A GEOSCoverageCleanParams to control the options used in cleaning the coverage. |
References GEOSCoverageCleanWithParams().
Referenced by GEOSCoverageCleanWithParams().
|
extern |
References GEOSCoverageCleanWithParams_r().
Referenced by GEOSCoverageCleanWithParams_r().
|
extern |
Returns a MultiLineString representing the unique edges of a polygonal coverage.
| input | a GeometryCollection or MultiPolygon representing the coverage. |
| edgetype | selection type: 0 = ALL, 1 = EXTERIOR (non-shared), 2 = INTERIOR (shared). |
References GEOSCoverageEdges().
Referenced by GEOSCoverageEdges().
|
extern |
|
extern |
Analyze a coverage (represented as a collection of polygonal geometry with exactly matching edge geometry) to find places where the assumption of exactly matching edges is not met.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| input | The polygonal coverage to access, stored in a geometry collection. All members must be POLYGON or MULTIPOLYGON. |
| gapWidth | The maximum width of gaps to detect. |
| invalidEdges | When there are invalidities in the coverage, this pointer will be set with a geometry collection of the same length as the input, with a MULTILINESTRING of the error edges for each invalid polygon, or an EMPTY where the polygon is a valid participant in the coverage. Pass NULL if you do not want the invalid edges returned. |
References GEOSCoverageIsValid().
Referenced by GEOSCoverageIsValid().
|
extern |
References GEOSCoverageIsValid_r().
Referenced by GEOSCoverageIsValid_r().
|
extern |
Operates on a coverage (represented as a list of polygonal geometry with exactly matching edge geometry) to apply a Visvalingam–Whyatt simplification to the edges, reducing complexity in proportion with the provided tolerance, while retaining a valid coverage (no edges will cross or touch after the simplification). Geometries never disappear, but they may be simplified down to just a triangle. Also, some invalid geoms (such as Polygons which have too few non-repeated points) will be returned unchanged. If the input dataset is not a valid coverage due to overlaps, it will still be simplified, but invalid topology such as crossing edges will still be invalid.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| input | The polygonal coverage to access, stored in a geometry collection. All members must be POLYGON or MULTIPOLYGON. |
| tolerance | A tolerance parameter in linear units. |
| preserveBoundary | Use 1 to preserve the outside edges of the coverage without simplification, 0 to allow them to be simplified. |
References GEOSCoverageSimplifyVW().
Referenced by GEOSCoverageSimplifyVW().
|
extern |
References GEOSCoverageSimplifyVW_r().
Referenced by GEOSCoverageSimplifyVW_r().
|
extern |
Optimized union algorithm for polygonal inputs that are correctly noded and do not overlap. It may generate an error (return NULL) for inputs that do not satisfy this constraint, however this is not guaranteed.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g | The input geometry |
References GEOSCoverageUnion().
Referenced by GEOSCoverageUnion().
|
extern |
|
extern |
Tests if geometry g1 is covered by g2, which is the case if every point of g1 lies in g2.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSCoveredBy().
Referenced by GEOSCoveredBy().
|
extern |
|
extern |
Tests if geometry g1 covers g2, which is the case if every point of g2 lies in g1.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSCovers().
Referenced by GEOSCovers().
|
extern |
|
extern |
Tests if two geometries interiors intersect but their boundaries do not. Most useful for finding line crosses cases.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSCrosses().
Referenced by GEOSCrosses().
|
extern |
|
extern |
Approximate all circular arcs in a geometry using line segments. If the input has no circular arcs, a copy will be returned.
| g | the geometry to convert |
| params | parameters to use in the linearization. |
References GEOSCurveToLine().
Referenced by GEOSCurveToLine().
|
extern |
|
extern |
Set the maximum deviation between an arc and its linear approximate.
| params | parameters to use in the conversion. |
| tolerance | the maximum deviation |
References GEOSCurveToLineParams_setMaxDeviation().
Referenced by GEOSCurveToLineParams_setMaxDeviation().
|
extern |
References GEOSCurveToLineParams_setMaxDeviation_r().
Referenced by GEOSCurveToLineParams_setMaxDeviation_r().
|
extern |
Set the maximum step (in degrees) between subsequent points.
| params | parameters to use in the conversion. |
| tolerance | the maximum step size |
References GEOSCurveToLineParams_setMaxStepDegrees().
Referenced by GEOSCurveToLineParams_setMaxStepDegrees().
|
extern |
References GEOSCurveToLineParams_setMaxStepDegrees_r().
Referenced by GEOSCurveToLineParams_setMaxStepDegrees_r().
|
extern |
Return a Delaunay triangulation of the vertices of the given geometry.
Z values from the input points will be propagated to the generated polygons. M values from the input points will be ignored.
Curved geometries are supported since GEOS 3.15. For curved geometries, the control point and endpoints of each arc will be used as input vertices.
| g | the input geometry whose vertices will be used as "sites" |
| tolerance | optional snapping tolerance to use for improved robustness |
| onlyEdges | if non-zero will return a MultiLineString, otherwise it will return a GeometryCollection containing triangular Polygons. |
References GEOSDelaunayTriangulation().
Referenced by GEOSDelaunayTriangulation().
|
extern |
References GEOSDelaunayTriangulation_r().
Referenced by GEOSDelaunayTriangulation_r().
|
extern |
Densifies a geometry using a given distance tolerance. Additional vertices will be added to every line segment that is greater this tolerance; these vertices will evenly subdivide that segment. Z and M values of added vertices will be interpolated. Only linear components of input geometry are densified.
Curved geometries are not supported, unless curve-to-line parameters are registered with the context handle. Output geometries will not contain curves.
| g | The geometry to densify |
| tolerance | the distance tolerance to densify |
References GEOSDensify().
Referenced by GEOSDensify().
|
extern |
|
extern |
Returns the difference of two geometries A and B: the set of points that fall within A but not within B.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| ga | the base geometry |
| gb | the geometry to subtract from it |
References GEOSDifference().
Referenced by GEOSDifference().
|
extern |
|
extern |
Returns the difference of two geometries A and B: the set of points that fall within A but not within B. All the vertices of the output geometry must fall on the grid defined by the gridSize, and the output will be a valid geometry.
| ga | one of the geometries |
| gb | the other geometry |
| gridSize | the cell size of the precision grid |
References GEOSDifferencePrec().
Referenced by GEOSDifferencePrec().
|
extern |
|
extern |
Tests if two geometries have no point in common.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSDisjoint().
Referenced by GEOSDisjoint().
|
extern |
|
extern |
Optimized union algorithm for inputs that can be divided into subsets that do not intersect. If there is only one such subset, performance can be expected to be worse than GEOSUnionaryUnion.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g | The input geometry |
References GEOSDisjointSubsetUnion().
Referenced by GEOSDisjointSubsetUnion().
|
extern |
References GEOSDisjointSubsetUnion_r().
Referenced by GEOSDisjointSubsetUnion_r().
|
extern |
Calculate the distance between two geometries. Distance is calculated in the XY plane; Z and M values are ignored.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g1 | Input geometry |
| [in] | g2 | Input geometry |
| [out] | dist | Pointer to be filled in with distance result. Positive infinity is returned if one of the geometry is empty. |
References GEOSDistance().
Referenced by GEOSDistance().
|
extern |
|
extern |
Calculate the distance between two geometries, using the indexed facet distance, which first indexes the geometries internally, then calculates the distance. Useful when one or both geometries is very large.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g1 | Input geometry |
| [in] | g2 | Input geometry |
| [out] | dist | Pointer to be filled in with distance result |
References GEOSDistanceIndexed().
Referenced by GEOSDistanceIndexed().
|
extern |
References GEOSDistanceIndexed_r().
Referenced by GEOSDistanceIndexed_r().
|
extern |
Test whether the distance between two geometries is within the given dist. Distance is calculated in the XY plane; Z and M values are ignored.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g1 | Input geometry |
| g2 | Input geometry |
| dist | The max distance |
References GEOSDistanceWithin().
Referenced by GEOSDistanceWithin().
|
extern |
|
extern |
Returns minimum 2D rectangular polygon or point that contains the geometry, or an empty point for empty inputs.
Z and M values in the input coordinates are ignored.
Cuved geometry types are supported as of GEOS 3.13.
| g | The geometry to calculate an envelope for |
References GEOSEnvelope().
Referenced by GEOSEnvelope().
|
extern |
|
extern |
Tests if two geometries contain the same set of points in the plane.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSEquals().
Referenced by GEOSEquals().
|
extern |
|
extern |
Determine pointwise equality of two geometries, by checking that they have identical structure and that each vertex of g2 is within the distance tolerance of the corresponding vertex in g1. Z and M values are ignored by GEOSEqualsExact, and this function may return true for inputs with different dimensionality. Unlike GEOSEquals(), geometries that are topologically equivalent but have different representations (e.g., LINESTRING (0 0, 1 1) and MULTILINESTRING ((0 0, 1 1)) ) are not considered equal by GEOSEqualsExact().
Curved geometry types are supported since GEOS 3.13.
| g1 | Input geometry |
| g2 | Input geometry |
| tolerance | Tolerance to determine vertex equality |
References GEOSEqualsExact().
Referenced by GEOSEqualsExact().
|
extern |
|
extern |
Determine pointwise equality of two geometries by checking that the structure, ordering, and values of all vertices are identical in all dimensions. NaN values are considered to be equal to other NaN values.
Curved geometry types are supported since GEOS 3.13.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSEqualsIdentical().
Referenced by GEOSEqualsIdentical().
|
extern |
References GEOSEqualsIdentical_r().
Referenced by GEOSEqualsIdentical_r().
|
extern |
Calculate the Frechet distance between two geometries, a similarity measure for linear features.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g1 | Input geometry |
| [in] | g2 | Input geometry |
| [out] | dist | Pointer to be filled in with distance result |
References GEOSFrechetDistance().
Referenced by GEOSFrechetDistance().
|
extern |
References GEOSFrechetDistance_r().
Referenced by GEOSFrechetDistance_r().
|
extern |
Calculate the Frechet distance between two geometries, a similarity measure for linear features. The inputs can be densified to provide a more accurate result.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g1 | Input geometry |
| [in] | g2 | Input geometry |
| [in] | densifyFrac | The largest % of the overall line length that any given two-point segment should be |
| [out] | dist | Pointer to be filled in with distance result |
References GEOSFrechetDistanceDensify().
Referenced by GEOSFrechetDistanceDensify().
|
extern |
References GEOSFrechetDistanceDensify_r().
Referenced by GEOSFrechetDistanceDensify_r().
|
extern |
Free strings and byte buffers returned by functions such as GEOSWKBWriter_write(), GEOSWKBWriter_writeHEX() and GEOSWKTWriter_write(), etc. If passed a null pointer the function does nothing.
| buffer | The memory to free (may be null) |
References GEOSFree().
Referenced by GEOSFree().
|
extern |
|
extern |
Allocate a new GEOSGeoJSONReader.
References GEOSGeoJSONReader_create().
Referenced by GEOSGeoJSONReader_create().
|
extern |
References GEOSGeoJSONReader_create_r().
Referenced by GEOSGeoJSONReader_create_r().
|
extern |
Free the memory associated with a GEOSGeoJSONReader.
| reader | The reader to destroy. |
References GEOSGeoJSONReader_destroy().
Referenced by GEOSGeoJSONReader_destroy().
|
extern |
References GEOSGeoJSONReader_destroy_r().
Referenced by GEOSGeoJSONReader_destroy_r().
|
extern |
Use a reader to parse a GeoJSON string. A single geometry or Feature is parsed as a geometry. A FeatureCollection is parsed as a GeometryCollection. Feature properties are not read.
| reader | A GeoJSON reader object, caller retains ownership |
| geojson | The json string to parse, caller retains ownership |
References GEOSGeoJSONReader_readGeometry().
Referenced by GEOSGeoJSONReader_readGeometry().
|
extern |
References GEOSGeoJSONReader_readGeometry_r().
Referenced by GEOSGeoJSONReader_readGeometry_r().
|
extern |
Allocate a new GEOSGeoJSONWriter.
References GEOSGeoJSONWriter_create().
Referenced by GEOSGeoJSONWriter_create().
|
extern |
References GEOSGeoJSONWriter_create_r().
Referenced by GEOSGeoJSONWriter_create_r().
|
extern |
Free the memory associated with a GEOSGeoJSONWriter.
| writer | The writer to destroy. |
References GEOSGeoJSONWriter_destroy().
Referenced by GEOSGeoJSONWriter_destroy().
|
extern |
References GEOSGeoJSONWriter_destroy_r().
Referenced by GEOSGeoJSONWriter_destroy_r().
|
extern |
Reads the current output dimension from a GEOSGeoJSONWriter.
| writer | A GEOSGeoJSONWriter. |
References GEOSGeoJSONWriter_getOutputDimension().
Referenced by GEOSGeoJSONWriter_getOutputDimension().
|
extern |
References GEOSGeoJSONWriter_getOutputDimension_r().
Referenced by GEOSGeoJSONWriter_getOutputDimension_r().
|
extern |
Set the output dimensionality of the writer. Either 2 or 3 dimensions.
| writer | A GEOSGeoJSONWriter. |
| dim | The dimensionality desired. |
References GEOSGeoJSONWriter_setOutputDimension().
Referenced by GEOSGeoJSONWriter_setOutputDimension().
|
extern |
References GEOSGeoJSONWriter_setOutputDimension_r().
Referenced by GEOSGeoJSONWriter_setOutputDimension_r().
|
extern |
Write out the GeoJSON representation of a geometry. Note that writing a GeoJSON Feature or FeatureCollection is unsupported through the GEOS C API.
| writer | A GeoJSON reader object, caller retains ownership. |
| g | The geometry to convert, caller retains ownership. |
| indent | The indentation used. Use -1 for no formatting. |
References GEOSGeoJSONWriter_writeGeometry().
Referenced by GEOSGeoJSONWriter_writeGeometry().
|
extern |
References GEOSGeoJSONWriter_writeGeometry_r().
Referenced by GEOSGeoJSONWriter_writeGeometry_r().
|
extern |
Create a new copy of the input geometry.
| g | The geometry to copy |
References GEOSGeom_clone().
Referenced by GEOSGeom_clone().
|
extern |
|
extern |
Creates a CircularString geometry.
| s | Input coordinate sequence, ownership passes to the geometry |
References GEOSGeom_createCircularString().
Referenced by GEOSGeom_createCircularString().
|
extern |
References GEOSGeom_createCircularString_r().
Referenced by GEOSGeom_createCircularString_r().
|
extern |
Create a geometry collection.
| type | The geometry type, enumerated by GEOSGeomTypes |
| geoms | A list of geometries that will form the collection |
| ngeoms | The number of geometries in the geoms list |
References GEOSGeom_createCollection().
Referenced by GEOSGeom_createCollection().
|
extern |
References GEOSGeom_createCollection_r().
Referenced by GEOSGeom_createCollection_r().
|
extern |
Creates a CompoundCurve geometry.
| curves | A list of geometries that will form the CompoundCurve |
| ncurves | The number of geometries in the curves list |
References GEOSGeom_createCompoundCurve().
Referenced by GEOSGeom_createCompoundCurve().
|
extern |
References GEOSGeom_createCompoundCurve_r().
Referenced by GEOSGeom_createCompoundCurve_r().
|
extern |
Creates a CurvePolygon geometry from ring geometries.
| shell | A ring that is the exterior ring of the polygon. |
| holes | An array of rings that are the holes. |
| nholes | The number of rings in the holes array. |
References GEOSGeom_createCurvePolygon().
Referenced by GEOSGeom_createCurvePolygon().
|
extern |
References GEOSGeom_createCurvePolygon_r().
Referenced by GEOSGeom_createCurvePolygon_r().
|
extern |
Creates an empty CircularString geometry.
References GEOSGeom_createEmptyCircularString().
Referenced by GEOSGeom_createEmptyCircularString().
|
extern |
References GEOSGeom_createEmptyCircularString_r().
Referenced by GEOSGeom_createEmptyCircularString_r().
|
extern |
Create an empty geometry collection.
| type | The geometry type, enumerated by GEOSGeomTypes |
References GEOSGeom_createEmptyCollection().
Referenced by GEOSGeom_createEmptyCollection().
|
extern |
References GEOSGeom_createEmptyCollection_r().
Referenced by GEOSGeom_createEmptyCollection_r().
|
extern |
Creates an empty CompoundCurve geometry.
References GEOSGeom_createEmptyCompoundCurve().
Referenced by GEOSGeom_createEmptyCompoundCurve().
|
extern |
References GEOSGeom_createEmptyCompoundCurve_r().
Referenced by GEOSGeom_createEmptyCompoundCurve_r().
|
extern |
Creates an empty CurvePolygon geometry.
References GEOSGeom_createEmptyCurvePolygon().
Referenced by GEOSGeom_createEmptyCurvePolygon().
|
extern |
References GEOSGeom_createEmptyCurvePolygon_r().
Referenced by GEOSGeom_createEmptyCurvePolygon_r().
|
extern |
Creates an emptylinestring geometry.
References GEOSGeom_createEmptyLineString().
Referenced by GEOSGeom_createEmptyLineString().
|
extern |
References GEOSGeom_createEmptyLineString_r().
Referenced by GEOSGeom_createEmptyLineString_r().
|
extern |
Creates an empty point.
References GEOSGeom_createEmptyPoint().
Referenced by GEOSGeom_createEmptyPoint().
|
extern |
References GEOSGeom_createEmptyPoint_r().
Referenced by GEOSGeom_createEmptyPoint_r().
|
extern |
Creates an empty polygon geometry.
References GEOSGeom_createEmptyPolygon().
Referenced by GEOSGeom_createEmptyPolygon().
|
extern |
References GEOSGeom_createEmptyPolygon_r().
Referenced by GEOSGeom_createEmptyPolygon_r().
|
extern |
Creates a linear ring geometry, for use in a polygon.
| s | Input coordinate sequence, ownership passes to the geometry |
References GEOSGeom_createLinearRing().
Referenced by GEOSGeom_createLinearRing().
|
extern |
References GEOSGeom_createLinearRing_r().
Referenced by GEOSGeom_createLinearRing_r().
|
extern |
Creates a linestring geometry.
| s | Input coordinate sequence, ownership passes to the geometry |
References GEOSGeom_createLineString().
Referenced by GEOSGeom_createLineString().
|
extern |
References GEOSGeom_createLineString_r().
Referenced by GEOSGeom_createLineString_r().
|
extern |
Creates a point geometry from a coordinate sequence.
| s | Input coordinate sequence, ownership passes to the geometry |
References GEOSGeom_createPoint().
Referenced by GEOSGeom_createPoint().
|
extern |
References GEOSGeom_createPoint_r().
Referenced by GEOSGeom_createPoint_r().
|
extern |
Creates a point geometry from a pair of coordinates.
| x | The X coordinate |
| y | The Y coordinate |
References GEOSGeom_createPointFromXY().
Referenced by GEOSGeom_createPointFromXY().
|
extern |
References GEOSGeom_createPointFromXY_r().
Referenced by GEOSGeom_createPointFromXY_r().
|
extern |
Creates a polygon geometry from linear ring geometries.
| shell | A linear ring that is the exterior ring of the polygon. |
| holes | An array of linear rings that are the holes. |
| nholes | The number of rings in the holes array. |
References GEOSGeom_createPolygon().
Referenced by GEOSGeom_createPolygon().
|
extern |
References GEOSGeom_createPolygon_r().
Referenced by GEOSGeom_createPolygon_r().
|
extern |
Create a rectangular polygon from bounding coordinates. Will return a point geometry if width and height are 0.
| xmin | Left bound of envelope |
| ymin | Lower bound of envelope |
| xmax | Right bound of envelope |
| ymax | Upper bound of envelope |
References GEOSGeom_createRectangle().
Referenced by GEOSGeom_createRectangle().
|
extern |
References GEOSGeom_createRectangle_r().
Referenced by GEOSGeom_createRectangle_r().
|
extern |
Release the memory associated with a geometry.
| g | The geometry to be destroyed. |
References GEOSGeom_destroy().
Referenced by GEOSGeom_destroy().
|
extern |
|
extern |
Return all distinct vertices of input geometry as a MultiPoint. Note that only 2 dimensions of the vertices are considered when testing for equality.
Z values on the retained coordinates will be preserved. M values will not be preserved.
Curved geometry types are supported since GEOS 3.13.
| g | The input geometry |
References GEOSGeom_extractUniquePoints().
Referenced by GEOSGeom_extractUniquePoints().
|
extern |
References GEOSGeom_extractUniquePoints_r().
Referenced by GEOSGeom_extractUniquePoints_r().
|
extern |
Return the cartesian dimension of the geometry.
| g | Input geometry |
References GEOSGeom_getCoordinateDimension().
Referenced by GEOSGeom_getCoordinateDimension().
|
extern |
References GEOSGeom_getCoordinateDimension_r().
Referenced by GEOSGeom_getCoordinateDimension_r().
|
extern |
Return the coordinate sequence underlying the given geometry (Must be a LineString, LinearRing, CircularString, or Point). Do not directly free the coordinate sequence, it is owned by the parent geometry.
| g | Input geometry |
References GEOSGeom_getCoordSeq().
Referenced by GEOSGeom_getCoordSeq().
|
extern |
References GEOSGeom_getCoordSeq_r().
Referenced by GEOSGeom_getCoordSeq_r().
|
extern |
Return the planar dimensionality of the geometry.
| g | Input geometry |
References GEOSGeom_getDimensions().
Referenced by GEOSGeom_getDimensions().
|
extern |
References GEOSGeom_getDimensions_r().
Referenced by GEOSGeom_getDimensions_r().
|
extern |
Finds the extent (minimum and maximum X and Y value) of the geometry's envelope.
Raises an exception for empty geometry input.
Curved geometry types are supported since GEOS 3.13.
| [in] | g | Input geometry |
| [out] | xmin | Pointer to place result for minimum X value |
| [out] | ymin | Pointer to place result for minimum Y value |
| [out] | xmax | Pointer to place result for maximum X value |
| [out] | ymax | Pointer to place result for maximum Y value |
References GEOSGeom_getExtent().
Referenced by GEOSGeom_getExtent().
|
extern |
|
extern |
Read the currently set precision value from the geometry and returns the grid size if it is a fixed precision or 0.0 if it is full floating point precision.
| g | Input geometry |
References GEOSGeom_getPrecision().
Referenced by GEOSGeom_getPrecision().
|
extern |
References GEOSGeom_getPrecision_r().
Referenced by GEOSGeom_getPrecision_r().
|
extern |
Return the anonymous "user data" for this geometry. User data must be managed by the caller, and is not freed when the geometry is destroyed.
| g | Input geometry |
References GEOSGeom_getUserData().
Referenced by GEOSGeom_getUserData().
|
extern |
References GEOSGeom_getUserData_r().
Referenced by GEOSGeom_getUserData_r().
|
extern |
Get the maximum X value of the geometry's envelope. For linear geometry types, this is the same as the maximum X coordinate value.
Curved geometry types are supported since GEOS 3.13.
| [in] | g | Input geometry |
| [out] | value | Pointer to place result |
References GEOSGeom_getXMax().
Referenced by GEOSGeom_getXMax().
|
extern |
|
extern |
Gets the minimum X value of the geometry's envelope. For linear geometry types, this is the same as the minimum X coordinate value.
Curved geometry types are supported since GEOS 3.13.
| [in] | g | Input geometry |
| [out] | value | Pointer to place result |
References GEOSGeom_getXMin().
Referenced by GEOSGeom_getXMin().
|
extern |
|
extern |
Gets the maximum Y value of the geometry's envelope. For linear geometry types, this is the same as the maximum Y coordinate value.
Curved geometry types are supported since GEOS 3.13.
| [in] | g | Input geometry |
| [out] | value | Pointer to place result |
References GEOSGeom_getYMax().
Referenced by GEOSGeom_getYMax().
|
extern |
|
extern |
Gets the minimum Y value of the geometry's envelope. For linear geometry types, this is the same as the minimum Y coordinate value.
Curved geometry types are supported since GEOS 3.13.
| [in] | g | Input geometry |
| [out] | value | Pointer to place result |
References GEOSGeom_getYMin().
Referenced by GEOSGeom_getYMin().
|
extern |
|
extern |
Release the sub-geometries of a collection for management. by the caller. The input collection remains as an empty collection, that the caller is responsible for destroying. The output geometries are also the responsibility of the caller, as is the containing array, which must be freed with GEOSFree().
| collection | The collection that will have its components released. |
| ngeoms | A pointer to a variable that will be filled with the size of the output array. |
References GEOSGeom_releaseCollection().
Referenced by GEOSGeom_releaseCollection().
|
extern |
References GEOSGeom_releaseCollection_r().
Referenced by GEOSGeom_releaseCollection_r().
|
extern |
Change the coordinate precision of a geometry. This will affect the precision of the existing geometry as well as any geometries derived from this geometry using overlay functions. The output will be a valid GEOSGeometry.
Note that operations will always be performed in the precision of the geometry with higher precision (smaller "gridSize"). That same precision will be attached to the operation outputs.
In the Default and GEOS_PREC_KEEP_COLLAPSED modes invalid input may cause an error to occur, unless the invalidity is below the scale of the requested precision
There are only 3 modes. The GEOS_PREC_NO_TOPO mode takes precedence over GEOS_PREC_KEEP_COLLAPSED. So the combination GEOS_PREC_NO_TOPO || GEOS_PREC_KEEP_COLLAPSED has the same semantics as GEOS_PREC_NO_TOPO
Z and M values in the input are preserved. Curved geometries are supported since GEOS 3.15 if GEOS_PREC_NO_TOPO is used.
| g | Input geometry |
| gridSize | cell size of grid to round coordinates to, or 0 for FLOATING precision |
| flags | The bitwise OR of members of the GEOSPrecisionRules enum |
References GEOSGeom_setPrecision().
Referenced by GEOSGeom_setPrecision().
|
extern |
References GEOSGeom_setPrecision_r().
Referenced by GEOSGeom_setPrecision_r().
|
extern |
Set the anonymous "user data" for this geometry.
| g | Input geometry |
| userData | Void pointer to user data |
References GEOSGeom_setUserData().
Referenced by GEOSGeom_setUserData().
|
extern |
References GEOSGeom_setUserData_r().
Referenced by GEOSGeom_setUserData_r().
|
extern |
Apply XY coordinate transform callback to all coordinates in a copy of input geometry. If the callback returns an error, returned geometry will be NULL. Z and M values, if present, are not modified by this function.
Curved geometry types are supported since GEOS 3.13.
| [in] | g | Input geometry |
| [in] | callback | a function to be executed for each coordinate in the geometry. The callback takes 3 parameters: x and y coordinate values to be updated and a void userdata pointer. |
| userdata | an optional pointer to pe passed to 'callback' as an argument |
References GEOSGeom_transformXY().
Referenced by GEOSGeom_transformXY().
|
extern |
References GEOSGeom_transformXY_r().
Referenced by GEOSGeom_transformXY_r().
|
extern |
Apply XYZ coordinate transform callback to all coordinates in a copy of input geometry. If the callback returns an error, returned geometry will be NULL. M values, if present, are not modified by this function.
Curved geometry types are supported since GEOS 3.13.
| [in] | g | Input geometry |
| [in] | callback | a function to be executed for each coordinate in the geometry. The callback takes 4 parameters: x, y and z coordinate values to be updated and a void userdata pointer. |
| userdata | an optional pointer to pe passed to 'callback' as an argument |
References GEOSGeom_transformXYZ().
Referenced by GEOSGeom_transformXYZ().
|
extern |
References GEOSGeom_transformXYZ_r().
Referenced by GEOSGeom_transformXYZ_r().
|
extern |
References GEOSGeomFromHEX_buf().
Referenced by GEOSGeomFromHEX_buf().
|
extern |
References GEOSGeomFromHEX_buf_r().
Referenced by GEOSGeomFromHEX_buf_r().
|
extern |
References GEOSGeomFromWKB_buf().
Referenced by GEOSGeomFromWKB_buf().
|
extern |
References GEOSGeomFromWKB_buf_r().
Referenced by GEOSGeomFromWKB_buf_r().
|
extern |
References GEOSGeomFromWKT().
Referenced by GEOSGeomFromWKT().
|
extern |
References GEOSGeomFromWKT_r().
Referenced by GEOSGeomFromWKT_r().
|
extern |
Return the last point of a linear geometry.
CircularString inputs are supported since GEOS 3.14. CompoundCurve inputs are supported since GEOS 3.15.
| g | Input geometry, must be a LineString, CircularString, or CompoundCurve |
References GEOSGeomGetEndPoint().
Referenced by GEOSGeomGetEndPoint().
|
extern |
References GEOSGeomGetEndPoint_r().
Referenced by GEOSGeomGetEndPoint_r().
|
extern |
Calculate the length of a LineString, CircularString, or CompoundCurve.
Returns an exception if a different geometry type is provided. Length is calculated in the XY plane; Z and M values are ignored.
CircularString and CompoundCurve arguments are supported since GEOS 3.15.
| [in] | g | Input geometry |
| [out] | length | Pointer to be filled in with length result |
References GEOSGeomGetLength().
Referenced by GEOSGeomGetLength().
|
extern |
|
extern |
Returns the M coordinate, for a Point input, or an exception otherwise.
| [in] | g | Input Point geometry |
| [out] | m | Pointer to hold return value |
References GEOSGeomGetM().
Referenced by GEOSGeomGetM().
|
extern |
|
extern |
Return the number of points in a linear geometry.
CircularString inputs are supported since GEOS 3.14. CompoundCurve inputs are supported since GEOS 3.15.
| g | Input geometry, must be a LineString, CircularString, or CompoundCurve |
References GEOSGeomGetNumPoints().
Referenced by GEOSGeomGetNumPoints().
|
extern |
References GEOSGeomGetNumPoints_r().
Referenced by GEOSGeomGetNumPoints_r().
|
extern |
Return the N'th point of a linear geometry.
CircularString inputs are supported since GEOS 3.14. CompoundCurve inputs are supported since GEOS 3.15.
| g | Input geometry, must be a LineString, CircularString, or CompoundCurve |
| n | Index of desired point (zero based) |
References GEOSGeomGetPointN().
Referenced by GEOSGeomGetPointN().
|
extern |
|
extern |
Return the first point of a linear geometry.
CircularString inputs are supported since GEOS 3.14. CompoundCurve inputs are supported since GEOS 3.15.
| g | Input geometry, must be a LineString, CircularString, or CompoundCurve |
References GEOSGeomGetStartPoint().
Referenced by GEOSGeomGetStartPoint().
|
extern |
References GEOSGeomGetStartPoint_r().
Referenced by GEOSGeomGetStartPoint_r().
|
extern |
Returns the X coordinate, for a Point input, or an exception otherwise.
| [in] | g | Input Point geometry |
| [out] | x | Pointer to hold return value |
References GEOSGeomGetX().
Referenced by GEOSGeomGetX().
|
extern |
|
extern |
Returns the Y coordinate, for a Point input, or an exception otherwise.
| [in] | g | Input Point geometry |
| [out] | y | Pointer to hold return value |
References GEOSGeomGetY().
Referenced by GEOSGeomGetY().
|
extern |
|
extern |
Returns the Z coordinate, for a Point input, or an exception otherwise.
| [in] | g | Input Point geometry |
| [out] | z | Pointer to hold return value |
References GEOSGeomGetZ().
Referenced by GEOSGeomGetZ().
|
extern |
|
extern |
References GEOSGeomToHEX_buf().
Referenced by GEOSGeomToHEX_buf().
|
extern |
References GEOSGeomToHEX_buf_r().
Referenced by GEOSGeomToHEX_buf_r().
|
extern |
References GEOSGeomToWKB_buf().
Referenced by GEOSGeomToWKB_buf().
|
extern |
References GEOSGeomToWKB_buf_r().
Referenced by GEOSGeomToWKB_buf_r().
|
extern |
References GEOSGeomToWKT().
Referenced by GEOSGeomToWKT().
|
extern |
References GEOSGeomToWKT_r().
Referenced by GEOSGeomToWKT_r().
|
extern |
Returns the geometry type string for this geometry. eg: "GeometryCollection", "LineString"
| g | Input geometry |
References GEOSGeomType().
Referenced by GEOSGeomType().
|
extern |
|
extern |
Returns the GEOSGeomTypeId number for this geometry.
| g | Input geometry |
References GEOSGeomTypeId().
Referenced by GEOSGeomTypeId().
|
extern |
|
extern |
Returns a 2D point at the center of mass of the input.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The input geometry |
References GEOSGetCentroid().
Referenced by GEOSGetCentroid().
|
extern |
|
extern |
Returns the specified sub-curve of a geometry. For a simple curve type (LineString/CircularString), returns a pointer to the input. Returns NULL for non-curve types (dimension != 1).
Returned object is a pointer to internal storage and must NOT be destroyed directly.
| g | Input geometry |
| n | Sub-curve index, zero-based |
References GEOSGetCurveN().
Referenced by GEOSGetCurveN().
|
extern |
|
extern |
Get the external ring of a Polygon.
| g | Input Polygon geometry |
References GEOSGetExteriorRing().
Referenced by GEOSGetExteriorRing().
|
extern |
References GEOSGetExteriorRing_r().
Referenced by GEOSGetExteriorRing_r().
|
extern |
Returns the specified sub-geometry of a collection. For a simple geometry, returns a pointer to the input. Returned object is a pointer to internal storage: it must NOT be destroyed directly.
| g | Input geometry |
| n | Sub-geometry index, zero-based |
References GEOSGetGeometryN().
Referenced by GEOSGetGeometryN().
|
extern |
|
extern |
Returns the N'th ring for a Polygon input.
| g | Input Polygon geometry |
| n | Index of the desired ring |
References GEOSGetInteriorRingN().
Referenced by GEOSGetInteriorRingN().
|
extern |
References GEOSGetInteriorRingN_r().
Referenced by GEOSGetInteriorRingN_r().
|
extern |
Get the total number of points in a geometry, of any type.
| g | Input geometry |
References GEOSGetNumCoordinates().
Referenced by GEOSGetNumCoordinates().
|
extern |
References GEOSGetNumCoordinates_r().
Referenced by GEOSGetNumCoordinates_r().
|
extern |
Returns the number of simple curves in a CompoundCurve. Returns 1 for a non-empty LineString/CircularString, and 0 for other inputs.
| g | Input geometry |
References GEOSGetNumCurves().
Referenced by GEOSGetNumCurves().
|
extern |
|
extern |
Returns the number of sub-geometries immediately under a multi-geometry or collection or 1 for a simple geometry. For nested collections, remember to check if returned sub-geometries are themselves also collections. Empty collection or multi-geometry types return 0, and empty simple geometry types return 1.
| g | Input geometry |
References GEOSGetNumGeometries().
Referenced by GEOSGetNumGeometries().
|
extern |
References GEOSGetNumGeometries_r().
Referenced by GEOSGetNumGeometries_r().
|
extern |
Returns the number of interior rings, for a Polygon input, or an exception otherwise.
| g | Input Polygon geometry |
References GEOSGetNumInteriorRings().
Referenced by GEOSGetNumInteriorRings().
|
extern |
References GEOSGetNumInteriorRings_r().
Referenced by GEOSGetNumInteriorRings_r().
|
extern |
Returns the "spatial reference id" (SRID) for this geometry.
| g | Input geometry |
References GEOSGetSRID().
Referenced by GEOSGetSRID().
|
extern |
|
extern |
Determine the fraction of each cell in a rectangular grid that is covered by a polygon.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The input geometry |
| xmin | Left bound of grd |
| ymin | Lower bound of grid |
| xmax | Right bound of grid |
| ymax | Upper bound of grid |
| nx | number of columns in grid |
| ny | number of rows in grid |
| buf | a buffer of size nx*ny to which the grid cell coverage fractions will be written in row-major order |
References GEOSGridIntersectionFractions().
Referenced by GEOSGridIntersectionFractions().
|
extern |
References GEOSGridIntersectionFractions_r().
Referenced by GEOSGridIntersectionFractions_r().
|
extern |
Tests whether the input geometry has M coordinates.
| g | The geometry to test |
References GEOSHasM().
Referenced by GEOSHasM().
|
extern |
|
extern |
Tests whether the input geometry has Z coordinates.
| g | The geometry to test |
References GEOSHasZ().
Referenced by GEOSHasZ().
|
extern |
|
extern |
Calculate the Hausdorff distance between two geometries. Hausdorff distance is the largest distance between two geometries.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g1 | Input geometry |
| [in] | g2 | Input geometry |
| [out] | dist | Pointer to be filled in with distance result |
References GEOSHausdorffDistance().
Referenced by GEOSHausdorffDistance().
|
extern |
References GEOSHausdorffDistance_r().
Referenced by GEOSHausdorffDistance_r().
|
extern |
Calculate a more precise Hausdorff distance between two geometries, by densifying the inputs before computation. Hausdorff distance is the largest distance between two geometries.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g1 | Input geometry |
| [in] | g2 | Input geometry |
| [in] | densifyFrac | The largest % of the overall line length that any given two-point segment should be |
| [out] | dist | Pointer to be filled in with distance result |
References GEOSHausdorffDistanceDensify().
Referenced by GEOSHausdorffDistanceDensify().
|
extern |
References GEOSHausdorffDistanceDensify_r().
Referenced by GEOSHausdorffDistanceDensify_r().
|
extern |
Calculate a more precise Hausdorff distance between two geometries, by densifying the inputs before computation and return the points that determine the distance. Hausdorff distance is the largest distance between two geometries.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g1 | Input geometry |
| [in] | g2 | Input geometry |
| [in] | densifyFrac | The largest % of the overall line length that any given two point segment should be. |
| [out] | dist | Pointer to be filled in with distance result |
| [out] | p1x | X coordinate of point on g1 |
| [out] | p1y | Y coordinate of point on g1 |
| [out] | p2x | X coordinate of point on g2 |
| [out] | p2y | Y coordinate of point on g2 |
References GEOSHausdorffDistanceDensifyWithPoints().
Referenced by GEOSHausdorffDistanceDensifyWithPoints().
|
extern |
References GEOSHausdorffDistanceDensifyWithPoints_r().
Referenced by GEOSHausdorffDistanceDensifyWithPoints_r().
|
extern |
Calculate the Hausdorff distance between two geometries and return the coordinates of the points that determine the distance.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g1 | Input geometry |
| [in] | g2 | Input geometry |
| [out] | dist | Pointer to be filled in with distance result |
| [out] | p1x | X coordinate of point on g1 |
| [out] | p1y | Y coordinate of point on g1 |
| [out] | p2x | X coordinate of point on g2 |
| [out] | p2y | Y coordinate of point on g2 |
References GEOSHausdorffDistanceWithPoints().
Referenced by GEOSHausdorffDistanceWithPoints().
|
extern |
References GEOSHausdorffDistanceWithPoints_r().
Referenced by GEOSHausdorffDistanceWithPoints_r().
|
extern |
Calculate the Hilbert code of the center of a geometry's bounding box relative to a larger extent. This allows sorting geometries in a deterministic way, such that similar Hilbert codes are likely to be near each other in two-dimensional space. The caller must ensure that the geometry is contained within the extent.
Curved geometries are supported since GEOS 3.13.
| [in] | geom | Input geometry, must be non-empty |
| [in] | extent | Extent within which to calculate the Hilbert code for geom |
| [in] | level | The level of precision of the Hilbert curve, up to 16 |
| [out] | code | Pointer to be filled in with Hilbert code result |
References GEOSHilbertCode().
Referenced by GEOSHilbertCode().
|
extern |
|
extern |
Return the point that is the specified 2D distance along a LineString from the start.
If applicable, the Z value of the returned point will be interpolated from the input line. Since GEOS 3.15, the M value will also be interpolated.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
If the (converted) input is not a LineString, NULL will be returned.
| line | linear target of projection |
| d | distance from start of line to created point |
References GEOSInterpolate().
Referenced by GEOSInterpolate().
|
extern |
|
extern |
Measuring from start of a LineString, return the point at the specified fraction of the total length.
If applicable, the Z value of the returned point will be interpolated from the input line. Since GEOS 3.15, the M value will also be interpolated.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
If the (converted) input is not a LineString, NULL will be returned.
| line | linear target of projection |
| proportion | The proportion from the start of line to created point |
References GEOSInterpolateNormalized().
Referenced by GEOSInterpolateNormalized().
|
extern |
References GEOSInterpolateNormalized_r().
Referenced by GEOSInterpolateNormalized_r().
|
extern |
Returns the intersection of two geometries: the set of points that fall within both geometries.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g1 | one of the geometries |
| g2 | the other geometry |
References GEOSIntersection().
Referenced by GEOSIntersection().
|
extern |
|
extern |
Returns the intersection of two geometries: the set of points that fall within both geometries. All the vertices of the output geometry must fall on the grid defined by the gridSize, and the output will be a valid geometry.
| g1 | one of the geometries |
| g2 | the other geometry |
| gridSize | the cell size of the precision grid |
References GEOSIntersectionPrec().
Referenced by GEOSIntersectionPrec().
|
extern |
References GEOSIntersectionPrec_r().
Referenced by GEOSIntersectionPrec_r().
|
extern |
Tests if two geometries intersect.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSIntersects().
Referenced by GEOSIntersects().
|
extern |
|
extern |
Tests whether the input geometry is closed. A closed geometry is either:
Z and M values are not considered.
| g | The geometry to test |
References GEOSisClosed().
Referenced by GEOSisClosed().
|
extern |
|
extern |
Tests whether the input geometry is empty. If the geometry or any component is non-empty, the geometry is non-empty. An empty geometry has no boundary or interior.
| g | The geometry to test |
References GEOSisEmpty().
Referenced by GEOSisEmpty().
|
extern |
|
extern |
Tests whether the input geometry is a ring. Rings are linestrings, without self-intersections, with start and end point having the same XY values. Z and M values are not considered.
| g | The geometry to test |
References GEOSisRing().
Referenced by GEOSisRing().
|
extern |
|
extern |
Tests whether the input geometry is "simple". Mostly relevant for linestrings. A "simple" linestring has no self-intersections. Z and M values are not considered.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The geometry to test |
References GEOSisSimple().
Referenced by GEOSisSimple().
|
extern |
|
extern |
In one step, calculate and return whether a geometry is simple and one more more points at which the geometry self-intersects at interior points. Caller has the responsibility to destroy 'location' with GEOSGeom_destroy()
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The geometry to test |
| findAllLocations | Whether to return all self-intersection locations, or just one |
| locations | A pointer in which the location GEOSGeometry will be placed |
References GEOSisSimpleDetail().
Referenced by GEOSisSimpleDetail().
|
extern |
|
extern |
Check the validity of the provided geometry.
Z and M values are not considered.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The geometry to test |
References GEOSisValid().
Referenced by GEOSisValid().
|
extern |
|
extern |
In one step, calculate and return the validity, the human readable validity reason and a point at which validity rules are broken. Caller has the responsibility to destroy 'reason' with GEOSFree() and 'location' with GEOSGeom_destroy()
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The geometry to test |
| flags | A value from the GEOSValidFlags enum |
| reason | A pointer in which the reason string will be places |
| location | A pointer in which the location GEOSGeometry will be placed |
References GEOSisValidDetail().
Referenced by GEOSisValidDetail().
|
extern |
|
extern |
Return the human readable reason a geometry is invalid, "Valid Geometry" string otherwise, or NULL on exception.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The geometry to test |
References GEOSisValidReason().
Referenced by GEOSisValidReason().
|
extern |
|
extern |
Constructs the "largest empty circle" (LEC) for a set of obstacle geometries and within a polygonal boundary, with accuracy to to a specified distance tolerance. The obstacles may be any collection of points, lines and polygons. The LEC is the largest circle whose interior does not intersect with any obstacle. and which has its center inside the given boundary. If no boundary is provided, the convex hull of the obstacles is used. The LEC center is the point in the interior of the boundary which has the farthest distance from the obstacles (up to the given distance tolerance). The LEC is determined by the center point and a point indicating the circle radius (which will lie on an obstacle).
To compute an LEC which lies wholly within a polygonal boundary, include the boundary of the polygon(s) as a linear obstacle.
The implementation uses a successive-approximation technique over a grid of square cells covering the obstacles and boundary. The grid is refined using a branch-and-bound algorithm. Point containment and distance are computed in a performant way by using spatial indexes.
Returns the LEC radius as a two-point linestring, with the start point at the center of the inscribed circle and the end on the boundary of the circle.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| obstacles | The geometries that the LEC must not cross |
| boundary | The area to contain the LEC center (may be null or empty) |
| tolerance | Stop the algorithm when the search area is smaller than this tolerance |
References GEOSLargestEmptyCircle().
Referenced by GEOSLargestEmptyCircle().
|
extern |
References GEOSLargestEmptyCircle_r().
Referenced by GEOSLargestEmptyCircle_r().
|
extern |
Calculate the length of a geometry.
Curved geometry types are supported since GEOS 3.13.
Length is calculated in the XY plane; Z and M values are ignored.
| [in] | g | Input geometry |
| [out] | length | Pointer to be filled in with length result |
References GEOSLength().
Referenced by GEOSLength().
|
extern |
|
extern |
Merges a set of LineStrings, joining them at nodes which have cardinality 2. Lines may have their direction reversed.
Z and M values from the input will be preserved. If the Z and M values differ at the points where two lines are joined, the values from one of the points will be selected.
Curved geometry types are supported since GEOS 3.15.
| g | The input linework |
References GEOSLineMerge().
Referenced by GEOSLineMerge().
|
extern |
|
extern |
Merges a set of LineStrings,* joining them at nodes which have cardinality 2. and where the lines have the same direction. This means that lines do not have their direction reversed.
Z and M values from the input will be preserved. If the Z and M values differ at the points where two lines are joined, the values from one of the points will be selected.
Curved geometry types are supported since GEOS 3.15.
| g | The input linework |
References GEOSLineMergeDirected().
Referenced by GEOSLineMergeDirected().
|
extern |
References GEOSLineMergeDirected_r().
Referenced by GEOSLineMergeDirected_r().
|
extern |
Computes the line which is the section of the input LineString starting and ending at the given length fractions.
Z values will be interpolated from the input. M values from the input will be ignored.
| g | The input LineString |
| start_fraction | start fraction (0-1) along the length of g |
| end_fraction | end fraction (0-1) along the length of g |
References GEOSLineSubstring().
Referenced by GEOSLineSubstring().
|
extern |
|
extern |
Replace line segments in the geometry with circular arcs, where possible.
| g | the geometry to convert |
| params | parameters to use in the conversion. |
References GEOSLineToCurve().
Referenced by GEOSLineToCurve().
|
extern |
|
extern |
Set the maximum angle difference used in line-to-curve conversion
A point may be considered to continue a circular arc if the angle between the point and the final point in the arc is within the specified tolerance of the angle calculated when the final point in the arc was added. This tolerance can be used to ensure that the step spacing is regular, which is an indication of a line that was generated by linearizing a curve.
| params | the parameters object |
| tolerance | the tolerance value |
References GEOSLineToCurveParams_setMaxAngleDifferenceDegrees().
Referenced by GEOSLineToCurveParams_setMaxAngleDifferenceDegrees().
|
extern |
|
extern |
Set the maximum angle spacing used in line-to-curve conversion.
A point may be considered to continue a circular arc if the angle between the point and the final point in the arc is less than the specified tolerance. Because of round-off errors, this value should be slightly greater than the one used in GEOSCurveToLineParams_setMaxStepDegrees.
| params | the parameters object |
| tolerance | the tolerance value |
References GEOSLineToCurveParams_setMaxStepDegrees().
Referenced by GEOSLineToCurveParams_setMaxStepDegrees().
|
extern |
References GEOSLineToCurveParams_setMaxStepDegrees_r().
Referenced by GEOSLineToCurveParams_setMaxStepDegrees_r().
|
extern |
Set the radius tolerance used in line-to-curve conversion.
A vertex may be considered to continue a circular arc if its distance to the previously-computed circle center is within the specified fraction of the circle radius.
| params | the parameters object |
| tolerance | the tolerance value |
References GEOSLineToCurveParams_setRadiusTolerance().
Referenced by GEOSLineToCurveParams_setRadiusTolerance().
|
extern |
References GEOSLineToCurveParams_setRadiusTolerance_r().
Referenced by GEOSLineToCurveParams_setRadiusTolerance_r().
|
extern |
Repair an invalid geometry, returning a valid output.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g | The geometry to repair |
References GEOSMakeValid().
Referenced by GEOSMakeValid().
|
extern |
|
extern |
Create a GEOSMakeValidParams to hold the desired parameters to control the algorithm and behavior of the validation process.
References GEOSMakeValidParams_create().
Referenced by GEOSMakeValidParams_create().
|
extern |
References GEOSMakeValidParams_create_r().
Referenced by GEOSMakeValidParams_create_r().
|
extern |
Destroy a GEOSMakeValidParams.
| parms | the object to destroy |
References GEOSMakeValidParams_destroy().
Referenced by GEOSMakeValidParams_destroy().
|
extern |
References GEOSMakeValidParams_destroy_r().
Referenced by GEOSMakeValidParams_destroy_r().
|
extern |
When this parameter is nn-zero, the GEOS_MAKE_VALID_STRUCTURE method will keep components that have collapsed into a lower dimensionality. For example, a ring collapsing to a line, or a line collapsing to a point.
References GEOSMakeValidParams_setKeepCollapsed().
Referenced by GEOSMakeValidParams_setKeepCollapsed().
|
extern |
References GEOSMakeValidParams_setKeepCollapsed_r().
Referenced by GEOSMakeValidParams_setKeepCollapsed_r().
|
extern |
Set the GEOSMakeValidMethods to use in making the geometry valid.
References GEOSMakeValidParams_setMethod().
Referenced by GEOSMakeValidParams_setMethod().
|
extern |
References GEOSMakeValidParams_setMethod_r().
Referenced by GEOSMakeValidParams_setMethod_r().
|
extern |
Repair an invalid geometry, returning a valid output, using the indicated GEOSMakeValidMethods algorithm and options.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g | is the geometry to test. |
| makeValidParams | is a GEOSMakeValidParams with the desired parameters set on it. |
References GEOSMakeValidWithParams().
Referenced by GEOSMakeValidWithParams().
|
extern |
References GEOSMakeValidWithParams_r().
Referenced by GEOSMakeValidWithParams_r().
|
extern |
Constructs the "maximum inscribed circle" (MIC) for a polygonal geometry, up to a specified tolerance. The MIC is determined by a point in the interior of the area which has the farthest distance from the area boundary, along with a boundary point at that distance. In the context of geography the center of the MIC is known as the "pole of inaccessibility". A cartographic use case is to determine a suitable point to place a map label within a polygon. The radius length of the MIC is a measure of how "narrow" a polygon is. It is the distance at which the negative buffer becomes empty. The class supports polygons with holes and multipolygons. The implementation uses a successive-approximation technique over a grid of square cells covering the area geometry. The grid is refined using a branch-and-bound algorithm. Point containment and distance are computed in a performant way by using spatial indexes. Returns a two-point linestring, with one point at the center of the inscribed circle and the other on the boundary of the inscribed circle.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | Input geometry |
| tolerance | Stop the algorithm when the search area is smaller than this tolerance |
References GEOSMaximumInscribedCircle().
Referenced by GEOSMaximumInscribedCircle().
|
extern |
References GEOSMaximumInscribedCircle_r().
Referenced by GEOSMaximumInscribedCircle_r().
|
extern |
Returns a 2D geometry which represents the "minimum bounding circle", the smallest circle that contains the input.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g | The input geometry |
| [out] | radius | Pointer will be filled with output radius. |
| [out] | center | Pointer will be filled with output circle center. Caller must free. |
References GEOSMinimumBoundingCircle().
Referenced by GEOSMinimumBoundingCircle().
|
extern |
References GEOSMinimumBoundingCircle_r().
Referenced by GEOSMinimumBoundingCircle_r().
|
extern |
Computes the minimum clearance of a geometry. The minimum clearance is the smallest amount by which a vertex could be move to produce an invalid polygon, a non-simple linestring, or a multipoint with repeated points. If a geometry has a minimum clearance of 'eps', it can be said that:
If the minimum clearance cannot be defined for a geometry (such as with a single point, or a multipoint whose points are identical, a value of Infinity will be calculated.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | the input geometry |
| d | a double to which the result can be stored |
References GEOSMinimumClearance().
Referenced by GEOSMinimumClearance().
|
extern |
References GEOSMinimumClearance_r().
Referenced by GEOSMinimumClearance_r().
|
extern |
Returns a 2D LineString whose endpoints define the minimum clearance of a geometry. If the geometry has no minimum clearance, an empty LineString will be returned.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | the input geometry |
References GEOSMinimumClearanceLine().
Referenced by GEOSMinimumClearanceLine().
|
extern |
References GEOSMinimumClearanceLine_r().
Referenced by GEOSMinimumClearanceLine_r().
|
extern |
Returns the minimum rotated rectangular POLYGON which encloses the input geometry. The rectangle has width equal to the minimum diameter, and a longer length. If the convex hill of the input is degenerate (a line or point) a linestring or point is returned. The minimum rotated rectangle can be used as an extremely generalized representation for the given geometry.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The input geometry |
References GEOSMinimumRotatedRectangle().
Referenced by GEOSMinimumRotatedRectangle().
|
extern |
References GEOSMinimumRotatedRectangle_r().
Referenced by GEOSMinimumRotatedRectangle_r().
|
extern |
Computes the Minimum Spanning Tree of the given Curves.
The input is an array of Curves (LineString, CircularString, CompoundCurve) which form the edges of a graph. The nodes of the graph are the endpoints of the Curves. Coincident endpoints are treated as the same node.
| geoms | Input array of Curves. Non-Curve geometries are ignored. |
| ngeoms | Number of geometries in the input array. |
References GEOSMinimumSpanningTree().
Referenced by GEOSMinimumSpanningTree().
|
extern |
References GEOSMinimumSpanningTree_r().
Referenced by GEOSMinimumSpanningTree_r().
|
extern |
Returns a linestring geometry which represents the minimum diameter of the geometry. The minimum diameter is defined to be the width of the smallest band that contains the geometry, where a band is a strip of the plane defined by two parallel lines. This can be thought of as the smallest hole that the geometry can be moved through, with a single rotation.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The input geometry |
References GEOSMinimumWidth().
Referenced by GEOSMinimumWidth().
|
extern |
|
extern |
The closest points of the two geometries. The first point comes from g1 geometry and the second point comes from g2. Returned points will not have Z or M values.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| [in] | g1 | Input geometry |
| [in] | g2 | Input geometry |
References GEOSNearestPoints().
Referenced by GEOSNearestPoints().
|
extern |
|
extern |
For linear inputs, returns a new geometry in which no lines cross each other, and all touching occurs at end points.
Z and M values of input coordinates will be preserved. Z and M values at constructed points will be interpolated.
Curved geometry types are supported since GEOS 3.15.
| g | The input geometry |
References GEOSNode().
Referenced by GEOSNode().
|
extern |
|
extern |
Organize the elements, rings, and coordinate order of geometries in a consistent way, so that geometries that represent the same object can be easily compared. Modifies the geometry in-place.
Normalization ensures the following:
Coordinate Z and M values are not modified during normalization.
Curved geometry types are supported since GEOS 3.15.
Use before calling GEOSEqualsExact to avoid false "not equal" results.
| g | Input geometry |
References GEOSNormalize().
Referenced by GEOSNormalize().
|
extern |
|
extern |
Generates offset curve line(s) for a geometry. Handles all non-curved geometry types as input. The coordinates of the constructed geometry will not have Z or M values.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The linear geometry to offset from |
| width | Distance to offset from the curve. Negative for a right-side offset. Positive for a left-side offset. |
| quadsegs | Number of segments per quadrant |
| joinStyle | See GEOSBufJoinStyles |
| mitreLimit | See GEOSBufferParams_setMitreLimit |
References GEOSOffsetCurve().
Referenced by GEOSOffsetCurve().
|
extern |
|
extern |
For the points formed by the six input ordinates, walking from A to B and then to P.
| Ax | X coordinate of A |
| Ay | Y coordinate of A |
| Bx | X coordinate of B |
| By | Y coordinate of B |
| Px | X coordinate of P |
| Py | Y coordinate of P |
References GEOSOrientationIndex().
Referenced by GEOSOrientationIndex().
|
extern |
References GEOSOrientationIndex_r().
Referenced by GEOSOrientationIndex_r().
|
extern |
Enforce a ring orientation on all polygonal elements in the input geometry. Non-polygonal geometries will not be modified. Coordinate Z and M values are not modified.
| g | Input geometry |
| exteriorCW | if 1, exterior rings will be clockwise and interior rings will be counter-clockwise |
References GEOSOrientPolygons().
Referenced by GEOSOrientPolygons().
|
extern |
|
extern |
Tests if two geometries share interiors but are neither within nor contained.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSOverlaps().
Referenced by GEOSOverlaps().
|
extern |
|
extern |
Returns a 2D point that is inside the boundary of a polygonal geometry.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g | The input geometry |
References GEOSPointOnSurface().
Referenced by GEOSPointOnSurface().
|
extern |
|
extern |
Computes a boundary-respecting hull of a polygonal geometry, with hull shape determined by a target parameter specifying the fraction of the input vertices retained in the result. Larger values produce less concave results. A value of 1 produces the convex hull; a value of 0 produces the original geometry. An outer hull is computed if the parameter is positive, an inner hull is computed if it is negative.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g | the polygonal geometry to process |
| isOuter | indicates whether to compute an outer or inner hull (1 for outer hull, 0 for inner) |
| vertexNumFraction | the target fraction of the count of input vertices to retain in result |
Caller is responsible for freeing with GEOSGeom_destroy().
References GEOSPolygonHullSimplify().
Referenced by GEOSPolygonHullSimplify().
|
extern |
References GEOSPolygonHullSimplify_r().
Referenced by GEOSPolygonHullSimplify_r().
|
extern |
Computes a topology-preserving simplified hull of a polygonal geometry, with hull shape determined by the parameter, controlled by a parameter mode, which is one defined in GEOSPolygonHullParameterModes. Larger values compute less concave results and a value of 0 produces the original geometry. Either outer or inner hulls can be computed.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g | the polygonal geometry to process |
| isOuter | indicates whether to compute an outer or inner hull (1 for outer hull, 0 for inner) |
| parameterMode | the interpretation to apply to the parameter argument; see GEOSPolygonHullParameterModes |
| parameter | the target ratio of area difference to original area |
Caller is responsible for freeing with GEOSGeom_destroy().
References GEOSPolygonHullSimplifyMode().
Referenced by GEOSPolygonHullSimplifyMode().
|
extern |
References GEOSPolygonHullSimplifyMode_r().
Referenced by GEOSPolygonHullSimplifyMode_r().
|
extern |
Polygonizes a set of Geometries which contain linework that represents the edges of a planar graph.
All non-curved types of Geometry are accepted as input; the constituent linework is extracted as the edges to be polygonized.
Z and M values from the input linework will be preserved. Curved geometries are supported since GEOS 3.15.
The edges must be correctly noded; that is, they must only meet at their endpoints and not overlap anywhere. If your edges are not already noded, run them through GEOSUnaryUnion() first. Polygonization will accept incorrectly noded input but will not form polygons from non-noded edges, and reports them as errors.
The Polygonizer reports the following kinds of errors:
Errors are reported to output parameters "cuts", "dangles" and "invalid" (if not-null). Formed polygons are returned as a collection. NULL is returned on exception. All returned geometries must be destroyed by caller.
The GEOSPolygonize_valid() variant allows extracting only polygons which form a valid polygonal result. The set of extracted polygons is guaranteed to be edge-disjoint. This is useful when it is known that the input lines form a valid polygonal geometry (which may include holes or nested polygons).
| geoms | Array of linear geometries to polygonize. Caller retains ownership of both array container and objects. |
| ngeoms | Size of the geoms array. |
References GEOSPolygonize().
Referenced by GEOSPolygonize().
|
extern |
Perform the polygonization as GEOSPolygonize() and return the polygonal result as well as all extra outputs.
Z and M values from the input linework will be preserved. Curved geometries are supported since GEOS 3.15.
| [in] | input | A single geometry with all the input lines to polygonize. |
| [out] | cuts | Pointer to hold "cut edges", connected on both ends but not part of output. Caller must free. |
| [out] | dangles | Pointer to hold "dangles", connected one end but not part of output. Caller must free. |
| [out] | invalid | Pointer to hold invalid outputs, polygons formed but not valid. Caller must free. |
References GEOSPolygonize_full().
Referenced by GEOSPolygonize_full().
|
extern |
References GEOSPolygonize_full_r().
Referenced by GEOSPolygonize_full_r().
|
extern |
|
extern |
Has the same polygonizing behavior as GEOSPolygonize(), but returns a result which is a valid polygonal geometry. The result will not contain any edge-adjacent elements.
Z and M values from the input linework will be preserved. Curved geometries are supported since GEOS 3.15.
| geoms | Array of linear geometries to polygonize. Caller retains ownership of both array container and objects. |
| ngeoms | Size of the geoms array. |
References GEOSPolygonize_valid().
Referenced by GEOSPolygonize_valid().
|
extern |
References GEOSPolygonize_valid_r().
Referenced by GEOSPolygonize_valid_r().
|
extern |
Perform the polygonization as GEOSPolygonize() but return only the "cut edges", the linear features that are connected at both ends, do not participate in the final polygon.
Z and M values from the input linework will be preserved. Curved geometries are supported since GEOS 3.15.
| geoms | Array of linear geometries to polygonize. Caller retains ownership of both array container and objects. |
| ngeoms | Size of the geoms array. |
References GEOSPolygonizer_getCutEdges().
Referenced by GEOSPolygonizer_getCutEdges().
|
extern |
References GEOSPolygonizer_getCutEdges_r().
Referenced by GEOSPolygonizer_getCutEdges_r().
|
extern |
Create a Prepared Geometry. The caller retains ownership of the base geometry, and after processing is complete, must free both the prepared and the base geometry. (Ideally, destroy the prepared geometry first, as it has an internal reference to the base geometry.)
| g | The base geometry to wrap in a prepared geometry. |
References GEOSPrepare().
Referenced by GEOSPrepare().
|
extern |
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry is contained.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedContains().
Referenced by GEOSPreparedContains().
|
extern |
References GEOSPreparedContains_r().
Referenced by GEOSPreparedContains_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry is contained properly.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedContainsProperly().
Referenced by GEOSPreparedContainsProperly().
|
extern |
References GEOSPreparedContainsProperly_r().
Referenced by GEOSPreparedContainsProperly_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation of whether the provided point is contained.
| pg1 | The prepared geometry |
| x | x coordinate of point to test |
| y | y coordinate of point to test |
References GEOSPreparedContainsXY().
Referenced by GEOSPreparedContainsXY().
|
extern |
References GEOSPreparedContainsXY_r().
Referenced by GEOSPreparedContainsXY_r().
|
extern |
Using a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry is covered by.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedCoveredBy().
Referenced by GEOSPreparedCoveredBy().
|
extern |
References GEOSPreparedCoveredBy_r().
Referenced by GEOSPreparedCoveredBy_r().
|
extern |
Using a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry covers.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedCovers().
Referenced by GEOSPreparedCovers().
|
extern |
|
extern |
Using a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry crosses.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedCrosses().
Referenced by GEOSPreparedCrosses().
|
extern |
References GEOSPreparedCrosses_r().
Referenced by GEOSPreparedCrosses_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry is disjoint.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedDisjoint().
Referenced by GEOSPreparedDisjoint().
|
extern |
References GEOSPreparedDisjoint_r().
Referenced by GEOSPreparedDisjoint_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation to find the distance between the prepared and provided geometry. Useful for situations where one geometry is large and static and needs to be tested against a large number of other geometries.
| [in] | pg1 | The prepared geometry |
| [in] | g2 | The geometry to test |
| [out] | dist | Pointer to store the result in |
References GEOSPreparedDistance().
Referenced by GEOSPreparedDistance().
|
extern |
References GEOSPreparedDistance_r().
Referenced by GEOSPreparedDistance_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation to find whether the prepared and provided geometry are within the given max distance. Useful for situations where one geometry is large and static and needs to be tested against a large number of other geometries.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
| dist | The max distance |
References GEOSPreparedDistanceWithin().
Referenced by GEOSPreparedDistanceWithin().
|
extern |
References GEOSPreparedDistanceWithin_r().
Referenced by GEOSPreparedDistanceWithin_r().
|
extern |
Free the memory associated with a GEOSPreparedGeometry. Caller must separately free the base GEOSGeometry used to create the prepared geometry.
| g | Prepared geometry to destroy. |
References GEOSPreparedGeom_destroy().
Referenced by GEOSPreparedGeom_destroy().
|
extern |
References GEOSPreparedGeom_destroy_r().
Referenced by GEOSPreparedGeom_destroy_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry intersects.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedIntersects().
Referenced by GEOSPreparedIntersects().
|
extern |
References GEOSPreparedIntersects_r().
Referenced by GEOSPreparedIntersects_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation of whether the provided point intersects.
| pg1 | The prepared geometry |
| x | x coordinate of point to test |
| y | y coordinate of point to test |
References GEOSPreparedIntersectsXY().
Referenced by GEOSPreparedIntersectsXY().
|
extern |
References GEOSPreparedIntersectsXY_r().
Referenced by GEOSPreparedIntersectsXY_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation to find the nearest points between the prepared and provided geometry.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedNearestPoints().
Referenced by GEOSPreparedNearestPoints().
|
extern |
References GEOSPreparedNearestPoints_r().
Referenced by GEOSPreparedNearestPoints_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry overlaps.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedOverlaps().
Referenced by GEOSPreparedOverlaps().
|
extern |
References GEOSPreparedOverlaps_r().
Referenced by GEOSPreparedOverlaps_r().
|
extern |
Use a GEOSPreparedGeometry do a high-performance calculation of the DE9IM relationship between the prepared and provided geometry.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedRelate().
Referenced by GEOSPreparedRelate().
|
extern |
|
extern |
Use a GEOSPreparedGeometry do a high-performance calculation of the DE9IM relationship between the prepared and provided geometry, and compare the relationship to the provided DE9IM pattern. Returns true if the patterns are consistent and false otherwise.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
| imPattern | The DE9IM pattern to test |
References GEOSPreparedRelatePattern().
Referenced by GEOSPreparedRelatePattern().
|
extern |
References GEOSPreparedRelatePattern_r().
Referenced by GEOSPreparedRelatePattern_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry touches.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedTouches().
Referenced by GEOSPreparedTouches().
|
extern |
References GEOSPreparedTouches_r().
Referenced by GEOSPreparedTouches_r().
|
extern |
Use a GEOSPreparedGeometry do a high performance calculation of whether the provided geometry is within.
| pg1 | The prepared geometry |
| g2 | The geometry to test |
References GEOSPreparedWithin().
Referenced by GEOSPreparedWithin().
|
extern |
|
extern |
Distance of point projected onto line from the start of the line.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| line | linear target of projection |
| point | point to be projected onto 'g' |
References GEOSProject().
Referenced by GEOSProject().
|
extern |
|
extern |
Project point to line and calculate the proportion of the line the point is from the start. For example, a point that projects to the middle of a line would be return 0.5.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| line | linear target of projection |
| point | the point to project |
References GEOSProjectNormalized().
Referenced by GEOSProjectNormalized().
|
extern |
References GEOSProjectNormalized_r().
Referenced by GEOSProjectNormalized_r().
|
extern |
Calculate the DE9IM string for this geometry pair. The result is a 9-character string containing dimension symbols in the set "012F".
| g1 | First geometry in pair |
| g2 | Second geometry in pair |
References GEOSRelate().
Referenced by GEOSRelate().
|
extern |
|
extern |
Calculate the DE9IM string for this geometry pair, using the supplied GEOSRelateBoundaryNodeRules.
| g1 | First geometry in pair |
| g2 | Second geometry in pair |
| bnr | A member of the GEOSRelateBoundaryNodeRules enum |
References GEOSRelateBoundaryNodeRule().
Referenced by GEOSRelateBoundaryNodeRule().
|
extern |
References GEOSRelateBoundaryNodeRule_r().
Referenced by GEOSRelateBoundaryNodeRule_r().
|
extern |
Calculate the DE9IM string for a geometry pair and compare against a DE9IM pattern. Returns true if the computed matrix matches the pattern. The pattern is a 9-character string containing symbols in the set "012TF*". "012F" match the corresponding dimension symbol; "T" matches any non-empty dimension; "*" matches any dimension.
| g1 | First geometry in pair |
| g2 | Second geometry in pair |
| imPattern | DE9IM pattern to match |
References GEOSRelatePattern().
Referenced by GEOSRelatePattern().
|
extern |
|
extern |
Compare a DE9IM string to a pattern and return true if they are consistent.
| intMatrix | DE9IM string (contains symbols "012F") |
| imPattern | Pattern to match to (may also contain symbols "T" and "*") |
References GEOSRelatePatternMatch().
Referenced by GEOSRelatePatternMatch().
|
extern |
References GEOSRelatePatternMatch_r().
Referenced by GEOSRelatePatternMatch_r().
|
extern |
Works from start of each coordinate sequence in the geometry, retaining points that are further away from the previous retained point than the tolerance value.
Removing repeated points with a non-zero tolerance may result in an invalid geometry being returned. Be sure to check and repair validity.
Z and M coordinate values are preserved but are not considered when determining if a point is repeated.
| g | The geometry to filter |
| tolerance | Remove all points within this distance of each other. Use 0.0 to remove only exactly repeated points. |
References GEOSRemoveRepeatedPoints().
Referenced by GEOSRemoveRepeatedPoints().
|
extern |
References GEOSRemoveRepeatedPoints_r().
Referenced by GEOSRemoveRepeatedPoints_r().
|
extern |
For geometries with coordinate sequences, reverses the order of the sequences. Converts CCW rings to CW. Reverses direction of LineStrings. Z and M values of the input coordinates are preserved.
Curved geometry types are supported since GEOS 3.13.
| g | The input geometry |
References GEOSReverse().
Referenced by GEOSReverse().
|
extern |
|
extern |
Computes the coordinate where two line segments intersect, if any
| [in] | ax0 | x-coordinate of 1st point in 1st segment |
| [in] | ay0 | y-coordinate of 1st point in 1st segment |
| [in] | ax1 | x-coordinate of 2nd point in 1st segment |
| [in] | ay1 | y-coordinate of 2nd point in 1st segment |
| [in] | bx0 | x-coordinate of 1st point in 2nd segment |
| [in] | by0 | y-coordinate of 1st point in 2nd segment |
| [in] | bx1 | x-coordinate of 2nd point in 2nd segment |
| [in] | by1 | y-coordinate of 2nd point in 2nd segment |
| [out] | cx | x-coordinate of intersection point |
| [out] | cy | y-coordinate of intersection point |
References GEOSSegmentIntersection().
Referenced by GEOSSegmentIntersection().
|
extern |
References GEOSSegmentIntersection_r().
Referenced by GEOSSegmentIntersection_r().
|
extern |
Set the "spatial reference id" (SRID) for this geometry.
| g | Input geometry |
| SRID | SRID number or 0 for unknown SRID. |
References GEOSSetSRID().
Referenced by GEOSSetSRID().
|
extern |
|
extern |
Find paths shared between the two given lineal geometries.
Returns a GeometryCollection having two elements:
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail.
| g1 | An input geometry |
| g2 | An input geometry |
References GEOSSharedPaths().
Referenced by GEOSSharedPaths().
|
extern |
|
extern |
Apply the Douglas/Peucker algorithm to the coordinate sequences of the input geometry. Removes "unnecessary" vertices, vertices that are co-linear within the tolerance distance. Z and M values on the retained coordinates will be preserved.
| g | The input geometry |
| tolerance | The tolerance to apply. Larger tolerance leads to simpler output. |
References GEOSSimplify().
Referenced by GEOSSimplify().
|
extern |
|
extern |
References GEOSSingleSidedBuffer().
Referenced by GEOSSingleSidedBuffer().
|
extern |
References GEOSSingleSidedBuffer_r().
Referenced by GEOSSingleSidedBuffer_r().
|
extern |
Snaps the vertices and segments of the first geometry to vertices of the second geometry within the given tolerance.
Where possible, this operation tries to avoid creating invalid geometries; however, it does not guarantee that output geometries will be valid. It is the responsibility of the caller to check for and handle invalid geometries.
Because too much snapping can result in invalid topology being created, heuristics are used to determine the number and location of snapped vertices that are likely safe to snap. These heuristics may omit some potential snaps that are otherwise within the tolerance.
| input | An input geometry |
| snap_target | A geometry to snap the input to |
| tolerance | Snapping tolerance |
References GEOSSnap().
Referenced by GEOSSnap().
|
extern |
|
extern |
Split a linear or polygonal input
Linear inputs can be split with points, lines, and/or polygons. Polygons can be split with lines and/or polygons.
The returned geometry will be a GeometryCollection containing the split elements.
| g | The geometry to split |
| edge | the geometry containing splitting edges/points |
References GEOSSplit().
Referenced by GEOSSplit().
|
extern |
|
extern |
Construct an STRtree from items that have been inserted. Once constructed, no more items may be inserted into the tree. Functions that require a constructed tree will build it automatically, so there is no need to call GEOSSTRtree_build unless it is desired to explicitly construct the tree in a certain section of code or using a certain thread.
| tree | the GEOSSTRtree to apply the build to |
References GEOSSTRtree_build().
Referenced by GEOSSTRtree_build().
|
extern |
|
extern |
Create a new GEOSSTRtree using the Sort-Tile-Recursive algorithm (STRtree) for two-dimensional spatial data.
| nodeCapacity | The maximum number of child nodes that a node may have. The minimum recommended capacity value is 4. If unsure, use a default node capacity of 10. |
References GEOSSTRtree_create().
Referenced by GEOSSTRtree_create().
|
extern |
|
extern |
Frees all the memory associated with a GEOSSTRtree. Only the tree is freed. The geometries and items fed into GEOSSTRtree_insert() are not owned by the tree, and are still left to the caller to manage.
| tree | the GEOSSTRtree to destroy |
References GEOSSTRtree_destroy().
Referenced by GEOSSTRtree_destroy().
|
extern |
References GEOSSTRtree_destroy_r().
Referenced by GEOSSTRtree_destroy_r().
|
extern |
Insert an item into an GEOSSTRtree
| tree | the GEOSSTRtree in which the item should be inserted |
| g | a GEOSGeometry whose envelope corresponds to the extent of 'item'. As of GEOS 3.9, this envelope will be copied into the tree and the caller may destroy g while the tree is still in use. Before GEOS 3.9, g must be retained until the tree is destroyed. |
| item | the item to insert into the tree |
References GEOSSTRtree_insert().
Referenced by GEOSSTRtree_insert().
|
extern |
|
extern |
Iterate over all items in the GEOSSTRtree. This will not cause the tree to be constructed.
| tree | the STRtree over which to iterate |
| callback | a function to be executed for each item in the tree. |
| userdata | payload to pass the callback function. |
References GEOSSTRtree_iterate().
Referenced by GEOSSTRtree_iterate().
|
extern |
References GEOSSTRtree_iterate_r().
Referenced by GEOSSTRtree_iterate_r().
|
extern |
Returns the nearest item in the GEOSSTRtree to the supplied geometry. All items in the tree MUST be of type GEOSGeometry. If this is not the case, use GEOSSTRtree_nearest_generic() instead. The tree will automatically be constructed if necessary, after which no more items may be added.
| tree | the GEOSSTRtree to search |
| geom | the geometry with which the tree should be queried |
References GEOSSTRtree_nearest().
Referenced by GEOSSTRtree_nearest().
|
extern |
Returns the nearest item in the GEOSSTRtree to the supplied item The tree will automatically be constructed if necessary, after which no more items may be added.
| tree | the STRtree to search |
| item | the item with which the tree should be queried |
| itemEnvelope | a GEOSGeometry having the bounding box of 'item' |
| distancefn | a function that can compute the distance between two items in the STRtree. The function should return zero in case of error, and should store the computed distance to the location pointed to by the distance argument. The computed distance between two items must not exceed the Cartesian distance between their envelopes. |
| userdata | optional pointer to arbitrary data; will be passed to distancefn each time it is called. |
References GEOSSTRtree_nearest_generic().
Referenced by GEOSSTRtree_nearest_generic().
|
extern |
References GEOSSTRtree_nearest_generic_r().
Referenced by GEOSSTRtree_nearest_generic_r().
|
extern |
References GEOSSTRtree_nearest_r().
Referenced by GEOSSTRtree_nearest_r().
|
extern |
Query a GEOSSTRtree for items intersecting a specified envelope. The tree will automatically be constructed if necessary, after which no more items may be added.
| tree | the GEOSSTRtree to search |
| g | a GEOSGeomety from which a query envelope will be extracted |
| callback | a function to be executed for each item in the tree whose envelope intersects the envelope of 'g'. The callback function should take two parameters: a void pointer representing the located item in the tree, and a void userdata pointer. |
| userdata | an optional pointer to pe passed to callback as an argument |
References GEOSSTRtree_query().
Referenced by GEOSSTRtree_query().
|
extern |
|
extern |
Removes an item from the GEOSSTRtree The tree will automatically be constructed if necessary, after which no more items may be added.
| tree | the STRtree from which to remove an item |
| g | the envelope of the item to remove |
| item | the item to remove |
References GEOSSTRtree_remove().
Referenced by GEOSSTRtree_remove().
|
extern |
|
extern |
Compute the intersection of a geometry with each polygon in a rectangular grid.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g | The input geometry to be clipped |
| xmin | Left bound of grd |
| ymin | Lower bound of grid |
| xmax | Right bound of grid |
| ymax | Upper bound of grid |
| nx | number of columns in grid |
| ny | number of rows in grid |
| includeExterior | whether to include portions of the input geometry that do not intersect the grid in the returned result. |
This algorithm operates in 2D only; Z and M values in the input will be dropped.
References GEOSSubdivideByGrid().
Referenced by GEOSSubdivideByGrid().
|
extern |
References GEOSSubdivideByGrid_r().
Referenced by GEOSSubdivideByGrid_r().
|
extern |
Returns the symmetric difference of two geometries A and B: the set of points that fall in A but not within B and the set of points that fall in B but not in A.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| ga | geometry A |
| gb | geometry B |
References GEOSSymDifference().
Referenced by GEOSSymDifference().
|
extern |
|
extern |
Returns the symmetric difference of two geometries A and B: the set of points that fall in A but not within B and the set of points that fall in B but not in A. All the vertices of the output geometry must fall on the grid defined by the gridSize, and the output will be a valid geometry.
| ga | one of the geometries |
| gb | the other geometry |
| gridSize | the cell size of the precision grid |
References GEOSSymDifferencePrec().
Referenced by GEOSSymDifferencePrec().
|
extern |
References GEOSSymDifferencePrec_r().
Referenced by GEOSSymDifferencePrec_r().
|
extern |
Apply the Douglas/Peucker algorithm to the coordinate sequences of the input geometry. Removes "unnecessary" vertices, vertices that are co-linear within the tolerance distance. Returns a valid output geometry, checking for collapses, ring-intersections, etc and attempting to avoid. More computationally expensive than GEOSSimplify() Z values on the retained coordinates will be preserved. M values will not be preserved.
| g | The input geometry |
| tolerance | The tolerance to apply. Larger tolerance leads to simpler output. |
References GEOSTopologyPreserveSimplify().
Referenced by GEOSTopologyPreserveSimplify().
|
extern |
References GEOSTopologyPreserveSimplify_r().
Referenced by GEOSTopologyPreserveSimplify_r().
|
extern |
Tests if two geometries share boundaries at one or more points, but do not have interior points in common.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSTouches().
Referenced by GEOSTouches().
|
extern |
|
extern |
Returns the union of all components of a single geometry. Usually used to convert a collection into the smallest set of polygons that cover the same area.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| g | The input geometry |
References GEOSUnaryUnion().
Referenced by GEOSUnaryUnion().
|
extern |
|
extern |
Returns the union of all components of a single geometry. Usually used to convert a collection into the smallest set of polygons that cover the same area. All the vertices of the output geometry must fall on the grid defined by the gridSize, and the output will be a valid geometry.
| g | input geometry |
| gridSize | the cell size of the precision grid |
References GEOSUnaryUnionPrec().
Referenced by GEOSUnaryUnionPrec().
|
extern |
|
extern |
Returns the union of two geometries A and B: the set of points that fall in A or within B.
This function does not support curved types directly. If curve-to-line conversion parameters are registered with the context, curved inputs will be automatically converted to lines. Otherwise, the operation will fail. This function outputs linear geometry types only. If line-to-curve conversion parameters are registered with the context, and a curved input was provided, outputs will be automatically converted to curved types.
| ga | geometry A |
| gb | geometry B |
References GEOSUnion().
Referenced by GEOSUnion().
|
extern |
|
extern |
References GEOSUnionCascaded().
Referenced by GEOSUnionCascaded().
|
extern |
References GEOSUnionCascaded_r().
Referenced by GEOSUnionCascaded_r().
|
extern |
Returns the union of two geometries A and B: the set of points that fall in A or within B. All the vertices of the output geometry must fall on the grid defined by the gridSize, and the output will be a valid geometry.
| ga | one of the geometries |
| gb | the other geometry |
| gridSize | the cell size of the precision grid |
References GEOSUnionPrec().
Referenced by GEOSUnionPrec().
|
extern |
|
extern |
Returns the current GEOS version string. eg: "3.10.0" This function does not have a reentrant variant and is available if GEOS_USE_ONLY_R_API is defined.
References GEOSversion().
Referenced by GEOSversion().
|
extern |
Returns the 2D Voronoi polygons or edges computed from the vertices of the given geometry.
Curved geometries are supported since GEOS 3.15. For curved geometries, the control point and endpoints of each arc will be used as input vertices.
| g | the input geometry whose vertices will be used as sites. |
| tolerance | snapping tolerance to use for improved robustness. A tolerance of 0.0 specifies that no snapping will take place. This argument can be finicky and is known to cause the algorithm to fail in several cases. If you're using tolerance and getting a failure, try setting it to 0.0. |
| flags | A value from the GEOSVoronoiFlags enum |
| env | clipping envelope for the returned diagram, automatically determined if env is NULL. The diagram will be clipped to the larger of this envelope or an envelope surrounding the sites. |
References GEOSVoronoiDiagram().
Referenced by GEOSVoronoiDiagram().
|
extern |
|
extern |
Tests if geometry g1 is completely within g2, but not wholly contained in the boundary of g2.
| g1 | Input geometry |
| g2 | Input geometry |
References GEOSWithin().
Referenced by GEOSWithin().
|
extern |
|
extern |
Allocate a new GEOSWKBReader.
References GEOSWKBReader_create().
Referenced by GEOSWKBReader_create().
|
extern |
References GEOSWKBReader_create_r().
Referenced by GEOSWKBReader_create_r().
|
extern |
Free the memory associated with a GEOSWKBReader.
| reader | The reader to destroy. |
References GEOSWKBReader_destroy().
Referenced by GEOSWKBReader_destroy().
|
extern |
References GEOSWKBReader_destroy_r().
Referenced by GEOSWKBReader_destroy_r().
|
extern |
Read a geometry from a well-known binary buffer.
| reader | A GEOSWKBReader |
| wkb | A pointer to the buffer to read from |
| size | The number of bytes of data in the buffer |
References GEOSWKBReader_read().
Referenced by GEOSWKBReader_read().
|
extern |
|
extern |
Read a geometry from a hex encoded well-known binary buffer.
| reader | A GEOSWKBReader |
| hex | A pointer to the buffer to read from |
| size | The number of bytes of data in the buffer |
References GEOSWKBReader_readHEX().
Referenced by GEOSWKBReader_readHEX().
|
extern |
References GEOSWKBReader_readHEX_r().
Referenced by GEOSWKBReader_readHEX_r().
|
extern |
Set the reader to automatically repair structural errors in the input (currently just unclosed rings) while reading.
| reader | A WKB reader object, caller retains ownership |
| doFix | Set to 1 to repair, 0 for no repair (default). |
References GEOSWKBReader_setFixStructure().
Referenced by GEOSWKBReader_setFixStructure().
|
extern |
References GEOSWKBReader_setFixStructure_r().
Referenced by GEOSWKBReader_setFixStructure_r().
|
extern |
Allocate a new GEOSWKBWriter.
References GEOSWKBWriter_create().
Referenced by GEOSWKBWriter_create().
|
extern |
References GEOSWKBWriter_create_r().
Referenced by GEOSWKBWriter_create_r().
|
extern |
Free the memory associated with a GEOSWKBWriter.
| writer | The writer to destroy. |
References GEOSWKBWriter_destroy().
Referenced by GEOSWKBWriter_destroy().
|
extern |
References GEOSWKBWriter_destroy_r().
Referenced by GEOSWKBWriter_destroy_r().
|
extern |
Find whether the writer will use WKB byte order that is big or little endian. The return value is a member of GEOSWKBByteOrders.
| writer | The writer to read byte order from |
References GEOSWKBWriter_getByteOrder().
Referenced by GEOSWKBWriter_getByteOrder().
|
extern |
References GEOSWKBWriter_getByteOrder_r().
Referenced by GEOSWKBWriter_getByteOrder_r().
|
extern |
Find whether the writer will use WKB that is ISO flavor or "extended" flavor. The flavor determines how extra dimensionality is encoded with the type number, and whether SRID can be included in the WKB. ISO flavor does not support SRID embedding. ISO flavor is "more standard" for 3D output. GEOS can read both flavors. The return value is a member of GEOSWKBFlavors.
| writer | The writer to read flavor from |
References GEOSWKBWriter_getFlavor().
Referenced by GEOSWKBWriter_getFlavor().
|
extern |
References GEOSWKBWriter_getFlavor_r().
Referenced by GEOSWKBWriter_getFlavor_r().
|
extern |
Read the current SRID embedding value from the writer.
| writer | The writer to check SRID value on |
References GEOSWKBWriter_getIncludeSRID().
Referenced by GEOSWKBWriter_getIncludeSRID().
|
extern |
References GEOSWKBWriter_getIncludeSRID_r().
Referenced by GEOSWKBWriter_getIncludeSRID_r().
|
extern |
Read the current output dimension of the writer. Either 2, 3, or 4 dimensions. Return current number of dimensions.
| writer | The writer to read from. |
References GEOSWKBWriter_getOutputDimension().
Referenced by GEOSWKBWriter_getOutputDimension().
|
extern |
References GEOSWKBWriter_getOutputDimension_r().
Referenced by GEOSWKBWriter_getOutputDimension_r().
|
extern |
Set the output byte order of the writer, using a value from GEOSWKBByteOrders enum.
| writer | The writer to set byte order on |
| byteOrder | Desired byte order |
References GEOSWKBWriter_setByteOrder().
Referenced by GEOSWKBWriter_setByteOrder().
|
extern |
References GEOSWKBWriter_setByteOrder_r().
Referenced by GEOSWKBWriter_setByteOrder_r().
|
extern |
Set the output flavor of the writer, using a value from GEOSWKBFlavors enum.
| writer | The writer to set flavor on |
| flavor | Desired flavor |
References GEOSWKBWriter_setFlavor().
Referenced by GEOSWKBWriter_setFlavor().
|
extern |
References GEOSWKBWriter_setFlavor_r().
Referenced by GEOSWKBWriter_setFlavor_r().
|
extern |
Specify whether SRID values should be output in WKB. Many WKB readers do not support SRID values, use with caution.
| writer | The writer to set SRID output on |
| writeSRID | Set to 1 to include SRID, 0 otherwise |
References GEOSWKBWriter_setIncludeSRID().
Referenced by GEOSWKBWriter_setIncludeSRID().
|
extern |
References GEOSWKBWriter_setIncludeSRID_r().
Referenced by GEOSWKBWriter_setIncludeSRID_r().
|
extern |
Set the output dimensionality of the writer. Either 2, 3, or 4 dimensions. Default since GEOS 3.12 is 4.
| writer | The writer to read from. |
| newDimension | The dimensionality desired |
References GEOSWKBWriter_setOutputDimension().
Referenced by GEOSWKBWriter_setOutputDimension().
|
extern |
References GEOSWKBWriter_setOutputDimension_r().
Referenced by GEOSWKBWriter_setOutputDimension_r().
|
extern |
Write out the WKB representation of a geometry.
| writer | The GEOSWKBWriter controlling the writing. |
| g | Geometry to convert to WKB |
| size | Pointer to write the size of the final output WKB to |
References GEOSWKBWriter_write().
Referenced by GEOSWKBWriter_write().
|
extern |
References GEOSWKBWriter_write_r().
Referenced by GEOSWKBWriter_write_r().
|
extern |
Write out the hex WKB representation of a geometry.
| writer | The GEOSWKBWriter controlling the writing. |
| g | Geometry to convert to WKB |
| size | Pointer to write the size of the final output WKB to |
References GEOSWKBWriter_writeHEX().
Referenced by GEOSWKBWriter_writeHEX().
|
extern |
References GEOSWKBWriter_writeHEX_r().
Referenced by GEOSWKBWriter_writeHEX_r().
|
extern |
Allocate a new GEOSWKTReader.
References GEOSWKTReader_create().
Referenced by GEOSWKTReader_create().
|
extern |
References GEOSWKTReader_create_r().
Referenced by GEOSWKTReader_create_r().
|
extern |
Free the memory associated with a GEOSWKTReader.
| reader | The reader to destroy. |
References GEOSWKTReader_destroy().
Referenced by GEOSWKTReader_destroy().
|
extern |
References GEOSWKTReader_destroy_r().
Referenced by GEOSWKTReader_destroy_r().
|
extern |
Use a reader to parse the well-known text representation of a geometry, and return an allocated geometry.
| reader | A WKT reader object, caller retains ownership |
| wkt | The WKT string to parse, caller retains ownership |
References GEOSWKTReader_read().
Referenced by GEOSWKTReader_read().
|
extern |
|
extern |
Set the reader to automatically repair structural errors in the input (currently just unclosed rings) while reading.
| reader | A WKT reader object, caller retains ownership |
| doFix | Set to 1 to repair, 0 for no repair (default). |
References GEOSWKTReader_setFixStructure().
Referenced by GEOSWKTReader_setFixStructure().
|
extern |
References GEOSWKTReader_setFixStructure_r().
Referenced by GEOSWKTReader_setFixStructure_r().
|
extern |
Allocate a new GEOSWKTWriter.
References GEOSWKTWriter_create().
Referenced by GEOSWKTWriter_create().
|
extern |
References GEOSWKTWriter_create_r().
Referenced by GEOSWKTWriter_create_r().
|
extern |
Free the memory associated with a GEOSWKTWriter.
| writer | The writer to destroy. |
References GEOSWKTWriter_destroy().
Referenced by GEOSWKTWriter_destroy().
|
extern |
References GEOSWKTWriter_destroy_r().
Referenced by GEOSWKTWriter_destroy_r().
|
extern |
Reads the current output dimension from a GEOSWKTWriter.
| writer | A GEOSWKTWriter. |
References GEOSWKTWriter_getOutputDimension().
Referenced by GEOSWKTWriter_getOutputDimension().
|
extern |
References GEOSWKTWriter_getOutputDimension_r().
Referenced by GEOSWKTWriter_getOutputDimension_r().
|
extern |
Sets the format for 3D outputs. The "old 3D" format does not include a Z dimension tag, e.g. "POINT (1 2 3)", except for XYM, e.g. "POINT M (1 2 3)". Geometries with XYZM coordinates do not add any dimensionality tags, e.g. "POINT (1 2 3 4)".
| writer | A GEOSWKTWriter. |
| useOld3D | True to use the old format, false is the default. |
References GEOSWKTWriter_setOld3D().
Referenced by GEOSWKTWriter_setOld3D().
|
extern |
References GEOSWKTWriter_setOld3D_r().
Referenced by GEOSWKTWriter_setOld3D_r().
|
extern |
Set the output dimensionality of the writer. Either 2, 3, or 4 dimensions. Default since GEOS 3.12 is 4.
| writer | A GEOSWKTWriter. |
| dim | The dimensionality desired. |
References GEOSWKTWriter_setOutputDimension().
Referenced by GEOSWKTWriter_setOutputDimension().
|
extern |
References GEOSWKTWriter_setOutputDimension_r().
Referenced by GEOSWKTWriter_setOutputDimension_r().
|
extern |
Sets the number places after the decimal to output in WKT.
| writer | A GEOSWKTWriter. |
| precision | The desired precision, default 16. |
References GEOSWKTWriter_setRoundingPrecision().
Referenced by GEOSWKTWriter_setRoundingPrecision().
|
extern |
References GEOSWKTWriter_setRoundingPrecision_r().
Referenced by GEOSWKTWriter_setRoundingPrecision_r().
|
extern |
Sets the number trimming option on a GEOSWKTWriter. With trim set to 1, the writer will strip trailing 0's from the output coordinates. With 1 (trimming enabled), big and small absolute coordinates will use scientific notation, otherwise positional notation is used; see GEOS_printDouble for details. With 0 (trimming disabled), all coordinates will be padded with 0's out to the rounding precision. Default since GEOS 3.12 is with trim set to 1 for 'on'.
| writer | A GEOSWKTWriter. |
| trim | The trimming behaviour to set, 1 for 'on', 0 for 'off' |
References GEOSWKTWriter_setTrim().
Referenced by GEOSWKTWriter_setTrim().
|
extern |
References GEOSWKTWriter_setTrim_r().
Referenced by GEOSWKTWriter_setTrim_r().
|
extern |
Writes out the well-known text representation of a geometry, using the trim, rounding and dimension settings of the writer.
| writer | A GEOSWKTWriter. |
| g | Input geometry |
References GEOSWKTWriter_write().
Referenced by GEOSWKTWriter_write().
|
extern |
References GEOSWKTWriter_write_r().
Referenced by GEOSWKTWriter_write_r().
|
extern |
For non-reentrant code, set up an execution contact, and associate GEOSMessageHandler functions with it, to pass error and notice messages back to the calling application.
typedef void (*GEOSMessageHandler)(const char *fmt, ...);
| notice_function | Handle notice messages |
| error_function | Handle error messages |
References initGEOS().
Referenced by initGEOS().
|
extern |
References initGEOS_r().
Referenced by initGEOS_r().