geos-0.1.1.2: Bindings for GEOS.

Safe HaskellNone
LanguageHaskell2010

Data.Geometry.Geos.Geometry

Contents

Synopsis

Documentation

convertGeometryFromRaw :: (Geometry a, CoordSeqInput a ~ cb, CoordinateSequence cb) => a -> Geos (Some Geometry) Source #

convertGeometryToRaw :: (Geometry a, CoordSeqInput a ~ cb, CoordinateSequence cb) => Geometry b -> Geos a Source #

convertMultiPolygonFromRaw :: (Geometry a, CoordSeqInput a ~ ca, CoordinateSequence ca) => a -> Geos MultiPolygon Source #

interpolate :: Geometry LineString -> Double -> Geometry Point Source #

Given a distance, returns the point (or closest point) within the geometry LineString that distance.

interpolateNormalized :: Geometry LineString -> Double -> Geometry Point Source #

Like interpolate, but takes the distance as a double between 0 and 1.

project :: Geometry LineString -> Geometry Point -> Double Source #

Returns the distance from the origin of LineString to the point projected on the geometry (that is to a point of the line the closest to the given point).

projectNormalized :: Geometry LineString -> Geometry Point -> Double Source #

Like project, but returns the distance as a Double between 0 and 1.

covers :: Relatable a => a -> Geometry b -> Bool Source #

equalsExact :: Geometry a -> Geometry a -> Double -> Bool Source #

Returns True if the two geometries are exactly equal, up to a specified tolerance. The tolerance value should be a floating point number representing the error tolerance in the comparison, e.g., equalsExact g1 g2 0.001 will compare equality to within one thousandth of a unit.

equals :: Geometry a -> Geometry a -> Bool Source #

Returns True if the DE-9IM intersection matrix for the two geometries is T*F**FFF*.

overlaps :: Relatable a => a -> Geometry b -> Bool Source #

Returns true if the DE-9IM intersection matrix for the two geometries is T*T***T** (for two points or two surfaces) 1*T***T** (for two curves).

within :: Relatable a => a -> Geometry b -> Bool Source #

Returns True if the DE-9IM intersection matrix for the two geometries is T*F**F***.

crosses :: Relatable a => a -> Geometry b -> Bool Source #

Returns True if the DE-9IM intersection matrix for the two Geometries is T*T****** (for a point and a curve,a point and an area or a line and an area) 0******** (for two curves).

touches :: Relatable a => a -> Geometry b -> Bool Source #

Returns True if the DE-9IM intersection matrix for the two geometries is FT*******, F**T***** or F***T****.

disjoint :: Relatable a => a -> Geometry b -> Bool Source #

Returns True if the DE-9IM intersection matrix for the two geometries is FF*FF****.

geometryLength :: Geometry a -> Double Source #

Returns the length of this geometry (e.g., 0 for a Point, the length of a LineString, or the circumference of a Polygon).

distance :: Geometry a -> Geometry a -> Double Source #

NOTE: Data.Geometry.Geos distance calculations are linear – in other words, Data.Geometry.Geos does not perform a spherical calculation even if the SRID specifies a geographic coordinate system.

nearestPoints :: Geometry a -> Geometry a -> (Coordinate, Coordinate) Source #

Returns the closest points of the two geometries. The first point comes from g1 geometry and the second point comes from g2.

Orphan instances