geos.GEOSGeomFromHEX_buf ⇒ number
⏏
Converts a hexadecimal representation of WKB to a geometry.
Kind: Exported member
Returns: number
- A geometry, or NULL on exception. The caller is responsible for destroying it.
Param | Type | Description |
---|---|---|
hex | string | The hexadecimal string to convert. |
size | number | The size of the hexadecimal string. |
geos.GEOSGeomFromHEX_buf_r ⇒ number
⏏
Converts a hexadecimal representation of WKB to a geometry with a GEOS context handle.
Kind: Exported member
Returns: number
- A geometry, or NULL on exception. The caller is responsible for destroying it.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
hex | string | The hexadecimal string to convert. |
size | number | The size of the hexadecimal string. |
geos.GEOSGeomFromWKB_buf ⇒ number
⏏
Converts a WKB representation to a GEOSGeometry.
Kind: Exported member
Returns: number
- A pointer to a newly allocated GEOSGeometry, or NULL on exception. The caller is responsible for destroying it with GEOSGeom_destroy().
Param | Type | Description |
---|---|---|
wkb | number | A pointer to a buffer containing the WKB representation of the geometry. |
size | number | The size of the buffer. |
geos.GEOSGeomFromWKB_buf_r ⇒ number
⏏
Converts a WKB representation to a GEOSGeometry using a context handle.
Kind: Exported member
Returns: number
- A pointer to a newly allocated GEOSGeometry, or NULL on exception. The caller is responsible for destroying it with GEOSGeom_destroy_r().
Param | Type | Description |
---|---|---|
handle | number | The context handle.pointer |
wkb | number | A pointer to a buffer containing the WKB representation of the geometry. |
size | number | The size of the buffer. |
geos.GEOSGeomFromWKT ⇒ number
⏏
Returns a GEOSGeometry from a Well-Known Text (WKT) representation.
Kind: Exported member
Returns: number
- A pointer to the GEOSGeometry object.
Param | Type | Description |
---|---|---|
wkt | number | The WKT representation of the geometry. |
geos.GEOSGeomFromWKT_r ⇒ number
⏏
Returns a GEOSGeometry from a Well-Known Text (WKT) representation.
Kind: Exported member
Returns: number
- A pointer to the GEOSGeometry object.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
wkt | number | The WKT representation of the geometry. |
geos.GEOSGeomGetEndPoint ⇒ number
⏏
Returns the endpoint of a LineString geometry.
Kind: Exported member
Returns: number
- A pointer to a newly allocated GEOSGeometry object representing the endpoint, or NULL on exception.
See: https://libgeos.org/doxygen/geos__c_8h.html#a9c6f7f5d3b9a0f1a0d4c1a4e2a0b6e8b
Param | Type | Description |
---|---|---|
geom | number | A pointer to a GEOSGeometry object. |
geos.GEOSGeomGetEndPoint_r ⇒ number
⏏
Returns the endpoint of a LineString geometry.
Kind: Exported member
Returns: number
- A pointer to a newly allocated GEOSGeometry object representing the endpoint, or NULL on exception.
See: https://libgeos.org/doxygen/geos__c_8h.html#a9c6f7f5d3b9a0f1a0d4c1a4e2a0b6e8b
Param | Type | Description |
---|---|---|
handle | number | A GEOS context handle. |
geom | number | A pointer to a GEOSGeometry object. |
geos.GEOSGeomGetLength ⇒ number
⏏
Computes the length of a geometry.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
See: https://libgeos.org/doxygen/geos__c_8h.html#a4e9f6a5bbec6edea7adba6ffac72fe48
Param | Type | Description |
---|---|---|
geom | number | A pointer to a GEOSGeometry object. |
length | number | A pointer to a double value that will store the result. |
geos.GEOSGeomGetLength_r ⇒ number
⏏
Computes the length of a geometry.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry pointer. |
length | number | The output parameter for the length value. |
geos.GEOSGeomGetNumPoints ⇒ number
⏏
Returns the number of points in a geometry.
Kind: Exported member
Returns: number
- The number of points, or -1 on exception.
Param | Type | Description |
---|---|---|
g | number | The GEOS geometry pointer. |
geos.GEOSGeomGetNumPoints_r ⇒ number
⏏
Returns the number of points in a geometry.
Kind: Exported member
Returns: number
- The number of points, or -1 on exception.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry pointer. |
geos.GEOSGeomGetPointN ⇒ number
⏏
Return the Nth point of a LineString.
Kind: Exported member
Returns: number
- A Point geometry. Caller must free with GEOSGeom_destroy(). NULL on exception or if n is out of range.
Param | Type | Description |
---|---|---|
g | number | The input geometry, must be a LineString. |
n | number | The index of the point to return, starting from 0. |
geos.GEOSGeomGetPointN_r ⇒ number
⏏
Return the Nth point of a LineString (thread-safe version).
Kind: Exported member
Returns: number
- A Point geometry. Caller must free with GEOSGeom_destroy(). NULL on exception or if n is out of range.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The input geometry, must be a LineString. |
n | number | The index of the point to return, starting from 0. |
geos.GEOSGeomGetStartPoint ⇒ number
⏏
Return the first point of a LineString.
Kind: Exported member
Returns: number
- A Point geometry. Caller must free with GEOSGeom_destroy(). NULL on exception.
Param | Type | Description |
---|---|---|
g | number | The input geometry, must be a LineString. |
geos.GEOSGeomGetStartPoint_r ⇒ number
⏏
Returns the first point of a geometry.
Kind: Exported member
Returns: number
- The GEOS geometry pointer of the start point, or null if the input is not a lineal geometry.
See: GEOSGeomGetStartPoint_r
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry pointer. |
geos.GEOSGeomGetX ⇒ number
⏏
Returns the X coordinate of a point geometry.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
Param | Type | Description |
---|---|---|
g | number | The GEOS geometry pointer. Must be a point geometry. |
x | number | The output parameter for the X coordinate value. |
geos.GEOSGeomGetX_r ⇒ number
⏏
Returns the X coordinate of a point geometry.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry pointer. Must be a point geometry. |
x | number | The output parameter for the X coordinate value. |
geos.GEOSGeomGetY ⇒ number
⏏
Returns the Y coordinate of a point geometry.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
Param | Type | Description |
---|---|---|
g | number | A pointer to a GEOSGeometry object of type Point. |
value | number | A pointer to a double where the result will be stored. |
geos.GEOSGeomGetY_r ⇒ number
⏏
Returns the Y coordinate of a point geometry in a thread-safe manner.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
Param | Type | Description |
---|---|---|
handle | number | A GEOS context handle created by GEOS_init_r(). |
g | number | A pointer to a GEOSGeometry object of type Point. |
value | number | A pointer to a double where the result will be stored. |
geos.GEOSGeomGetZ ⇒ number
⏏
Returns the Z coordinate of a point geometry.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
Param | Type | Description |
---|---|---|
g | number | A pointer to a GEOSGeometry object of type Point. |
value | number | A pointer to a double where the result will be stored. |
geos.GEOSGeomGetZ_r ⇒ number
⏏
Returns the Z coordinate of a point geometry in a thread-safe manner.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
Param | Type | Description |
---|---|---|
handle | number | A GEOS context handle created by GEOS_init_r(). |
g | number | A pointer to a GEOSGeometry object of type Point. |
value | number | A pointer to a double where the result will be stored. |
geos.GEOSGeomToHEX_buf ⇒ string
⏏
Converts a GEOSGeometry to a HEX-encoded WKB representation.
Kind: Exported member
Returns: string
- A null-terminated string containing the HEX-encoded WKB representation of the geometry, or NULL on exception. The caller is responsible for freeing the string with GEOSFree().
Param | Type | Description |
---|---|---|
g | number | The geometry pointer to convert. |
size | number | A pointer to a size_t where the length of the returned string will be stored. |
geos.GEOSGeomToHEX_buf_r ⇒ string
⏏
Converts a geometry to a hexadecimal representation of its WKB.
Kind: Exported member
Returns: string
- A null-terminated hexadecimal string, or NULL on exception. The caller is responsible for freeing it.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The geometry to convert. |
size | number | A pointer to a size_t where the size of the returned buffer will be stored. |
geos.GEOSGeomToWKB_buf ⇒ number
⏏
Converts a GEOSGeometry to a WKB representation.
Kind: Exported member
Returns: number
- A pointer to a buffer containing the WKB representation of the geometry, or NULL on exception. The caller is responsible for freeing the buffer with GEOSFree().
Param | Type | Description |
---|---|---|
g | number | The geometry pointer to convert. |
size | number | A pointer to a size_t where the size of the returned buffer will be stored. |
geos.GEOSGeomToWKB_buf_r ⇒ number
⏏
Converts a GEOSGeometry to a WKB representation using a context handle.
Kind: Exported member
Returns: number
- A pointer to a buffer containing the WKB representation of the geometry, or NULL on exception. The caller is responsible for freeing the buffer with GEOSFree_r().
Param | Type | Description |
---|---|---|
handle | number | The context handle.pointer |
g | number | The geometry pointer to convert. |
size | number | A pointer to a size_t where the size of the returned buffer will be stored. |
geos.GEOSGeomToWKT ⇒ number
⏏
Returns a Well-Known Text (WKT) representation of a GEOSGeometry.
Kind: Exported member
Returns: number
- A WKT representation of the geometry.
Param | Type | Description |
---|---|---|
geom | number | A pointer to the GEOSGeometry object. |
geos.GEOSGeomToWKT_r ⇒ number
⏏
Returns a Well-Known Text (WKT) representation of a GEOSGeometry.
Kind: Exported member
Returns: number
- A WKT representation of the geometry.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
geom | number | A pointer to the GEOSGeometry object. |
geos.GEOSGeomType ⇒ string
⏏
Returns the type name of a geometry as a string. The possible values are: "Point", "LineString", "LinearRing", "Polygon", "MultiPoint", "MultiLineString", "MultiPolygon", "GeometryCollection".
Kind: Exported member
Returns: string
- the type name of the geometry, or NULL on error
Param | Type | Description |
---|---|---|
g | number | a pointer to a GEOSGeometry object |
geos.GEOSGeomTypeId ⇒ number
⏏
Returns the type ID of a geometry.
Kind: Exported member
Returns: number
- The type ID of the geometry, or -1 on exception.
See: https://libgeos.org/doxygen/geos__c_8h.html#a6e4b5f2c7d0b6a9a3e7b2d5f8d7f9e4c
Param | Type | Description |
---|---|---|
g | number | The geometry pointer to get the type ID of. |
geos.GEOSGeomTypeId_r ⇒ number
⏏
Returns the type ID of a geometry.
Kind: Exported member
Returns: number
- The type ID of the geometry, or -1 on exception.
See: https://libgeos.org/doxygen/geos__c_8h.html#a3b9d5a4f2e9b4a0c2e8a6f3b1c1d2e0b
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The geometry pointer to get the type ID of. |
geos.GEOSGeomType_r ⇒ string
⏏
Returns the name of a geometry's type.
Kind: Exported member
Returns: string
- The name of the geometry's type, or NULL on exception.
See: https://libgeos.org/doxygen/geos__c_8h.html#a9f3a3f0d6a8c7e9a0b4f2b7c6d0e5f1a
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The geometry pointer to get the type name of. |
geos.GEOSGeomTypes ⏏
Geometry type number, used by functions returning or consuming geometry types.
Name | Value |
---|---|
GEOS_POINT | 0 |
GEOS_LINESTRING | 1 |
GEOS_LINEARRING | 2 |
GEOS_POLYGON | 3 |
GEOS_MULTIPOINT | 4 |
GEOS_MULTILINESTRING | 5 |
GEOS_MULTIPOLYGON | 6 |
GEOS_GEOMETRYCOLLECTION | 7 |
Kind: Exported member
See
- GEOSGeomType
- GEOSGeomTypeId
geos.GEOSGeom_clone ⇒ number
⏏
Clone a geometry object with a different context handle.
Kind: Exported member
Returns: number
- The pointer to the cloned geometry object, or null on exception.
Param | Type | Description |
---|---|---|
g | number | The pointer to the geometry object to clone. |
geos.GEOSGeom_clone_r ⇒ number
⏏
Clone a geometry object.
Kind: Exported member
Returns: number
- The pointer to the cloned geometry object, or null on exception.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The pointer to the geometry object to clone. |
geos.GEOSGeom_createCollection ⇒ number
⏏
Creates a geometry collection of a specified type from an array of geometries.
Kind: Exported member
Returns: number
- A pointer to a GEOS geometry object representing the collection, or NULL on error.
See: https://libgeos.org/doxygen/geos__c_8h.html#a871ccb7efc6dd63162b3547fcd76c638
Param | Type | Description |
---|---|---|
type | number | An integer representing the geometry type, such as 1 for POINT, 4 for MULTIPOINT, etc. |
geoms | number | A pointer to a list of GEOS geometry pointers. |
ngeoms | number | The number of geometries in the array. |
geos.GEOSGeom_createCollection_r ⇒ number
⏏
Creates a geometry collection of a specified type from an array of geometries using a thread-safe context handle.
Kind: Exported member
Returns: number
- A pointer to a GEOS geometry object representing the collection, or NULL on error.
See: https://geos.osgeo.org/doxygen/classgeos_1_1geom_1_1GeometryFactory.html#a0c8f6a2a9f5b7a3d7e5c7b0f8b6f9c0e
Param | Type | Description |
---|---|---|
handle | number | A pointer to a GEOS context handle. |
type | number | An integer representing the geometry type, such as 1 for POINT, 4 for MULTIPOINT, etc. |
geoms | number | A pointer to an array of pointers to GEOS geometry objects. |
ngeoms | number | The number of geometries in the array. |
geos.GEOSGeom_createEmptyCollection ⇒ number
⏏
Creates an empty geometry collection of a given type.
Kind: Exported member
Returns: number
- An empty geometry collection, or null on exception.
Param | Type | Description |
---|---|---|
type | number | The geometry type, one of GEOS_GEOMETRYCOLLECTION, GEOS_MULTIPOINT, GEOS_MULTILINESTRING, GEOS_MULTIPOLYGON. |
geos.GEOSGeom_createEmptyCollection_r ⇒ number
⏏
Creates an empty geometry collection of a given type with a context handle.
Kind: Exported member
Returns: number
- An empty geometry collection, or null on exception.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
type | number | The geometry type, one of GEOS_GEOMETRYCOLLECTION, GEOS_MULTIPOINT, GEOS_MULTILINESTRING, GEOS_MULTIPOLYGON. |
geos.GEOSGeom_createEmptyLineString ⇒ number
⏏
Creates an empty line string geometry.
Kind: Exported member
Returns: number
- A pointer to a newly allocated empty line string geometry. NULL on exception. Caller is responsible for freeing with GEOSGeom_destroy().
See: https://libgeos.org/usage/c_api/#geosgeom_createemptylinestring
geos.GEOSGeom_createEmptyLineString_r ⇒ number
⏏
Creates an empty line string geometry using a reentrant context handle.
Kind: Exported member
Returns: number
- A pointer to a newly allocated empty line string geometry. NULL on exception. Caller is responsible for freeing with GEOSGeom_destroy_r().
See: https://libgeos.org/usage/c_api/#geosgeom_createemptylinestring_r
Param | Type | Description |
---|---|---|
handle | number | A GEOSContextHandle_t created by GEOS_init_r(). |
geos.GEOSGeom_createEmptyPoint ⇒ number
⏏
Creates an empty point geometry.
Kind: Exported member
Returns: number
- An empty point geometry, or null on exception.
geos.GEOSGeom_createEmptyPoint_r ⇒ number
⏏
Creates an empty point geometry with a context handle.
Kind: Exported member
Returns: number
- An empty point geometry, or null on exception.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
geos.GEOSGeom_createEmptyPolygon ⇒ number
⏏
Creates an empty polygon geometry.
Kind: Exported member
Returns: number
- A pointer to a newly allocated empty polygon geometry. NULL on exception. Caller is responsible for freeing with GEOSGeom_destroy().
See: https://libgeos.org/usage/c_api/#geosgeom_createemptypolygon
geos.GEOSGeom_createEmptyPolygon_r ⇒ number
⏏
Creates an empty polygon geometry using a reentrant context handle.
Kind: Exported member
Returns: number
- A pointer to a newly allocated empty polygon geometry. NULL on exception. Caller is responsible for freeing with GEOSGeom_destroy_r().
See: https://libgeos.org/usage/c_api/#geosgeom_createemptypolygon_r
Param | Type | Description |
---|---|---|
handle | number | A GEOSContextHandle_t created by GEOS_init_r(). |
geos.GEOSGeom_createLineString ⇒ number
⏏
Creates a line string geometry from a coordinate sequence.
Kind: Exported member
Returns: number
- The pointer to the created geometry or NULL on exception.
Param | Type | Description |
---|---|---|
coordSeq | number | The pointer to the coordinate sequence. |
geos.GEOSGeom_createLineString_r ⇒ number
⏏
Creates a line string geometry from a coordinate sequence.
Kind: Exported member
Returns: number
- The pointer to the created geometry or NULL on exception.
Param | Type | Description |
---|---|---|
handle | number | The handle to the GEOS context. |
coordSeq | number | The pointer to the coordinate sequence. |
geos.GEOSGeom_createLinearRing ⇒ number
⏏
Creates a linear ring geometry from a coordinate sequence. A linear ring is a line string that is both closed and simple.
Kind: Exported member
Returns: number
- A pointer to a newly allocated linear ring geometry. NULL on exception. Caller is responsible for freeing with GEOSGeom_destroy().
Param | Type | Description |
---|---|---|
s | number | A pointer to the coordinate sequence to use. Must have at least four elements and be closed. |
geos.GEOSGeom_createLinearRing_r ⇒ number
⏏
Creates a linear ring geometry from a coordinate sequence.
Kind: Exported member
Returns: number
- The pointer to the created geometry or NULL on exception.
Param | Type | Description |
---|---|---|
handle | number | The handle to the GEOS context. |
coordSeq | number | The pointer to the coordinate sequence. |
geos.GEOSGeom_createPoint ⇒ number
⏏
Creates a point geometry from a coordinate sequence.
Kind: Exported member
Returns: number
- A pointer to a newly allocated point geometry. NULL on exception. Caller is responsible for freeing with GEOSGeom_destroy().
Param | Type | Description |
---|---|---|
s | number | The pointer to a coordinate sequence to use. Must have exactly one element. |
geos.GEOSGeom_createPointFromXY ⇒ number
⏏
Creates a point geometry from a pair of coordinates.
Kind: Exported member
Returns: number
- A pointer to a newly allocated point geometry. NULL on exception. Caller is responsible for freeing with GEOSGeom_destroy().
Since: 3.8
Param | Type | Description |
---|---|---|
x | number | The X coordinate |
y | number | The Y coordinate |
geos.GEOSGeom_createPointFromXY_r ⇒ number
⏏
Creates a point geometry from a pair of coordinates (reentrant).
Kind: Exported member
Returns: number
- A pointer to a newly allocated point geometry. NULL on exception. Caller is responsible for freeing with GEOSGeom_destroy_r().
Since: 3.8
Param | Type | Description |
---|---|---|
handle | number | The context handle topointer use. |
x | number | The X coordinate |
y | number | The Y coordinate |
geos.GEOSGeom_createPoint_r ⇒ number
⏏
Creates a point geometry from a coordinate sequence (reentrant).
Kind: Exported member
Returns: number
- A pointer to a newly allocated point geometry. NULL on exception. Caller is responsible for freeing with GEOSGeom_destroy_r().
Param | Type | Description |
---|---|---|
handle | number | The context handle topointer use. |
s | number | The pointer to a coordinate sequence to use. Must have exactly one element. |
geos.GEOSGeom_createPolygon ⇒ number
⏏
Creates a polygon geometry from an outer ring and an optional array of inner rings.
Kind: Exported member
Returns: number
- The pointer to the created geometry or NULL on exception.
Param | Type | Description |
---|---|---|
outerRing | number | The pointer to the outer ring geometry. |
innerRings | number | The pointer to an array of inner ring geometries. |
numInnerRings | number | The number of inner rings in the array. |
geos.GEOSGeom_createPolygon_r ⇒ number
⏏
Creates a polygon geometry from an outer ring and an optional array of inner rings.
Kind: Exported member
Returns: number
- The pointer to the created geometry or NULL on exception.
Param | Type | Description |
---|---|---|
handle | number | The handle to the GEOS context. |
outerRing | number | The pointer to the outer ring geometry. |
innerRings | number | The pointer to an array of inner ring geometries. |
numInnerRings | number | The number of inner rings in the array. |
geos.GEOSGeom_destroy ⏏
Destroys a geometry object and frees its memory.
Kind: Exported member
Param | Type | Description |
---|---|---|
g | number | A pointer to a GEOSGeometry object. |
geos.GEOSGeom_destroy_r ⏏
Destroys a GEOS geometry object.
Kind: Exported member
See: https://libgeos.org/doxygen/geos__c_8h.html#a6a7f0c9b3f9a1d0f4e5c2a7b5b3e6a8d
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry object to destroy. |
geos.GEOSGeom_extractUniquePoints ⇒ number
⏏
Returns a multipoint containing all distinct vertices of input geometry g, which can be any kind of geometry.
Kind: Exported member
Returns: number
- A pointer to a new GEOSGeometry object representing a multipoint, or NULL on error.
Param | Type | Description |
---|---|---|
g | number | A pointer to a GEOSGeometry object representing any kind of geometry. |
geos.GEOSGeom_extractUniquePoints_r ⇒ number
⏏
Extracts every unique point from a geometry.
Kind: Exported member
Returns: number
- A geometry containing the unique points, or null on exception.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The geometry to extract points from. |
geos.GEOSGeom_getCoordSeq ⇒ number
⏏
Returns the coordinate sequence of a geometry.
Kind: Exported member
Returns: number
- A pointer to the coordinate sequence, or NULL on exception.
Param | Type | Description |
---|---|---|
g | number | The geometry to get the coordinate sequence from. |
geos.GEOSGeom_getCoordSeq_r ⇒ number
⏏
Returns the coordinate sequence of a geometry with a context handle.
Kind: Exported member
Returns: number
- A pointer to the coordinate sequence, or NULL on exception.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The geometry to get the coordinate sequence from. |
geos.GEOSGeom_getCoordinateDimension ⇒ number
⏏
Get the coordinate dimension of a geometry object.
Kind: Exported member
Returns: number
- The coordinate dimension of the geometry, or 0 on exception.
See: https://libgeos.org/doxygen/geos__c_8h.html#a3f7a6b7f8b6a3e5d2e9e4a4f5d8a0b1c
Param | Type | Description |
---|---|---|
g | number | The GEOS geometry pointer. |
geos.GEOSGeom_getCoordinateDimension_r ⇒ number
⏏
Get the coordinate dimension of a geometry object.
Kind: Exported member
Returns: number
- The coordinate dimension of the geometry, or 0 on exception.
See: https://github.com/libgeos/geos/blob/main/capi/geos_c.h.in#L2251
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry pointer. |
geos.GEOSGeom_getDimensions ⇒ number
⏏
Get the inherent dimension of a geometry object, which must be less than or equal to the coordinate dimension.
Kind: Exported member
Returns: number
- The inherent dimension of the geometry, or -1 on exception.
See: https://libgeos.org/doxygen/geos__c_8h.html#a4a2a3f2b9c7d6f9f0c8e5b4a0d6c1e7d
Param | Type | Description |
---|---|---|
g | number | The GEOS geometry pointer. |
geos.GEOSGeom_getDimensions_r ⇒ number
⏏
Get the inherent dimension of a geometry object, which must be less than or equal to the coordinate dimension.
Kind: Exported member
Returns: number
- The inherent dimension of the geometry, or -1 on exception.
See: https://github.com/libgeos/geos/blob/main/capi/geos_c.h.in#L2245
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry pointer. |
geos.GEOSGeom_getPrecision ⇒ number
⏏
Get the precision of a geometry object.
Kind: Exported member
Returns: number
- The precision value of the geometry object, or NaN on exception.
Param | Type | Description |
---|---|---|
g | number | The pointer to the geometry object to query. |
geos.GEOSGeom_getPrecision_r ⇒ number
⏏
Get the precision model of a geometry.
Kind: Exported member
Returns: number
- The precision model value, or 0 on exception.
See: https://github.com/libgeos/geos/blob/main/capi/geos_c.h.in#L2239
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry pointer. |
geos.GEOSGeom_getUserData ⇒ string
⏏
Returns the user data associated with a geometry as a string.
Kind: Exported member
Returns: string
- The user data of the geometry, or null if not set or not a string.
Param | Type | Description |
---|---|---|
g | string | A pointer to a GEOSGeometry object. |
geos.GEOSGeom_getUserData_r ⇒ string
⏏
Get the user data pointer associated with a geometry.
Kind: Exported member
Returns: string
- The user data pointer, or null if none is set.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | string | The GEOS geometry object. |
geos.GEOSGeom_getXMax ⇒ number
⏏
Finds the maximum X value in the geometry.
Kind: Exported member
Returns: number
- 0 on exception
Since: 3.7
Param | Type | Description |
---|---|---|
g | number | The pointer to the input geometry |
value | number | The pointer to place the result |
geos.GEOSGeom_getXMax_r ⇒ number
⏏
Returns the maximum X coordinate of the geometry.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
See: https://github.com/libgeos/geos/blob/main/capi/geos_c.h.in#L1652
Param | Type | Description |
---|---|---|
handle | number | The GEOS context pointer handle. |
g | number | The input geometry pointer. |
value | number | The output value. |
geos.GEOSGeom_getXMin ⇒ number
⏏
Finds the minimum X value in the geometry.
Kind: Exported member
Returns: number
- 0 on exception
Since: 3.7
Param | Type | Description |
---|---|---|
g | number | The pointer to the input geometry |
value | number | The pointer to place the result |
geos.GEOSGeom_getXMin_r ⇒ number
⏏
Finds the minimum X value in the geometry (thread-safe version).
Kind: Exported member
Returns: number
- 0 on exception
Since: 3.7
Param | Type | Description |
---|---|---|
handle | number | The pointer to the GEOS context |
g | number | The pointer to the input geometry |
value | number | The pointer to place the result |
geos.GEOSGeom_getYMax ⇒ number
⏏
Returns the maximum Y coordinate of the geometry.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
See: https://libgeos.org/doxygen/geos__c_8h.html#a9c6f3a7b7d4a5f3a9e8f1c6b0b4e2d9f
Param | Type | Description |
---|---|---|
g | number | The input geometry pointer. |
value | number | The output value. |
geos.GEOSGeom_getYMax_r ⇒ number
⏏
Returns the maximum Y coordinate of the geometry.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
See: https://github.com/libgeos/geos/blob/main/capi/geos_c.h.in#L1655
Param | Type | Description |
---|---|---|
handle | number | The GEOS context pointer handle. |
g | number | The input geometry pointer. |
value | number | The output value. |
geos.GEOSGeom_getYMin ⇒ number
⏏
Finds the minimum Y value in the geometry.
Kind: Exported member
Returns: number
- 0 on exception
Since: 3.7
Param | Type | Description |
---|---|---|
g | number | The pointer to the input geometry |
value | number | The pointer to place the result |
geos.GEOSGeom_getYMin_r ⇒ number
⏏
Finds the minimum Y value in the geometry (thread-safe version).
Kind: Exported member
Returns: number
- 0 on exception
Since: 3.7
Param | Type | Description |
---|---|---|
handle | number | The pointer to the GEOS context |
g | number | The pointer to the input geometry |
value | number | The pointer to place the result |
geos.GEOSGeom_releaseCollection ⇒ number
⏏
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().
Kind: Exported member
Returns: number
- A newly allocated array of GEOSGeometry pointers.
See: https://libgeos.org/doxygen/geos__c_8h.html#a9a7624d6406f501856cfb1e60a30f4fa
Param | Type | Description |
---|---|---|
collection | number | A pointer to a GEOS geometry collection object. |
ngeoms | number | A pointer to a variable that will be filled with the size of the output array. |
geos.GEOSGeom_releaseCollection_r ⇒ number
⏏
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().
Kind: Exported member
Returns: number
- A newly allocated array of GEOSGeometry pointers.
See: https://libgeos.org/doxygen/geos__c_8h.html#a9a7624d6406f501856cfb1e60a30f4fa
Param | Type | Description |
---|---|---|
handle | number | A pointer to a GEOS context handle. |
collection | number | A pointer to a GEOS geometry collection object. |
ngeoms | number | A pointer to a variable that will be filled with the size of the output array. |
geos.GEOSGeom_setPrecision ⇒ number
⏏
Set the precision of a geometry object with a different context handle.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
Param | Type | Description |
---|---|---|
g | number | The pointer to the geometry object to modify. |
precision | number | The precision value to set, or 0.0 for full precision. |
flags | number | The flags to control the behavior of the function. See https://libgeos.org/doxygen/geos__c_8h.html for details. |
geos.GEOSGeom_setPrecision_r ⇒ number
⏏
Set the precision of a geometry object.
Kind: Exported member
Returns: number
- 1 on success, 0 on exception.
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The pointer to the geometry object to modify. |
precision | number | The precision value to set, or 0.0 for full precision. |
flags | number | The flags to control the behavior of the function. See https://libgeos.org/doxygen/geos__c_8h.html for details. |
geos.GEOSGeom_setUserData ⏏
Set the user data pointer associated with a geometry. The user is responsible for freeing the memory of the user data pointer.
Kind: Exported member
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry object. |
userData | string | The user data pointer to be set. |
geos.GEOSGeom_setUserData_r ⏏
Set the user data pointer associated with a geometry. The user is responsible for freeing the memory of the user data pointer.
Kind: Exported member
Param | Type | Description |
---|---|---|
handle | number | A pointer to the GEOS context handle. |
g | number | The GEOS geometry object. |
userData | string | The user data pointer to be set. |