Libosmium
2.9.0
Fast and flexible C++ library for working with OpenStreetMap data
|
Everything related to geometry handling. More...
Namespaces | |
haversine | |
Functions to calculate arc distance on Earth using the haversine formula. | |
Classes | |
struct | Coordinates |
class | CRS |
class | GeometryFactory |
class | IdentityProjection |
class | MercatorProjection |
class | Projection |
struct | Tile |
Typedefs | |
template<typename TProjection = IdentityProjection> | |
using | GeoJSONFactory = GeometryFactory< osmium::geom::detail::GeoJSONFactoryImpl, TProjection > |
template<typename TProjection = IdentityProjection> | |
using | GEOSFactory = GeometryFactory< osmium::geom::detail::GEOSFactoryImpl, TProjection > |
template<typename TProjection = IdentityProjection> | |
using | OGRFactory = GeometryFactory< osmium::geom::detail::OGRFactoryImpl, TProjection > |
template<typename TWriter , typename TProjection = IdentityProjection> | |
using | RapidGeoJSONFactory = GeometryFactory< detail::RapidGeoJSONFactoryImpl< TWriter >, TProjection > |
template<typename TProjection = IdentityProjection> | |
using | WKBFactory = GeometryFactory< osmium::geom::detail::WKBFactoryImpl, TProjection > |
template<typename TProjection = IdentityProjection> | |
using | WKTFactory = GeometryFactory< osmium::geom::detail::WKTFactoryImpl, TProjection > |
Enumerations | |
enum | use_nodes : bool { use_nodes::unique = true, use_nodes::all = false } |
enum | direction : bool { direction::backward = true, direction::forward = false } |
enum | wkb_type : bool { wkb_type::wkb = false, wkb_type::ewkb = true } |
enum | out_type : bool { out_type::binary = false, out_type::hex = true } |
enum | wkt_type : bool { wkt_type::wkt = false, wkt_type::ewkt = true } |
Functions | |
bool | operator== (const Coordinates &lhs, const Coordinates &rhs) noexcept |
bool | operator!= (const Coordinates &lhs, const Coordinates &rhs) noexcept |
template<typename TChar , typename TTraits > | |
std::basic_ostream< TChar, TTraits > & | operator<< (std::basic_ostream< TChar, TTraits > &out, const Coordinates &c) |
Coordinates | lonlat_to_mercator (const Coordinates &c) |
Coordinates | mercator_to_lonlat (const Coordinates &c) |
Coordinates | transform (const CRS &src, const CRS &dest, Coordinates c) |
bool | contains (const osmium::Box &a, const osmium::Box &b) |
bool | operator== (const Tile &a, const Tile &b) |
Tiles are equal if all their attributes are equal. More... | |
bool | operator!= (const Tile &a, const Tile &b) |
bool | operator< (const Tile &a, const Tile &b) |
constexpr double | deg_to_rad (double degree) noexcept |
Convert angle from degrees to radians. More... | |
constexpr double | rad_to_deg (double radians) noexcept |
Convert angle from radians to degrees. More... | |
Variables | |
constexpr double | MERCATOR_MAX_LAT = 85.0511288 |
constexpr double | PI = 3.14159265358979323846 |
Everything related to geometry handling.
using osmium::geom::GeoJSONFactory = typedef GeometryFactory<osmium::geom::detail::GeoJSONFactoryImpl, TProjection> |
using osmium::geom::GEOSFactory = typedef GeometryFactory<osmium::geom::detail::GEOSFactoryImpl, TProjection> |
using osmium::geom::OGRFactory = typedef GeometryFactory<osmium::geom::detail::OGRFactoryImpl, TProjection> |
using osmium::geom::RapidGeoJSONFactory = typedef GeometryFactory<detail::RapidGeoJSONFactoryImpl<TWriter>, TProjection> |
using osmium::geom::WKBFactory = typedef GeometryFactory<osmium::geom::detail::WKBFactoryImpl, TProjection> |
using osmium::geom::WKTFactory = typedef GeometryFactory<osmium::geom::detail::WKTFactoryImpl, TProjection> |
|
strong |
|
strong |
|
strong |
|
strong |
|
strong |
|
inline |
Check whether one geometry contains another.
|
inlinenoexcept |
Convert angle from degrees to radians.
|
inline |
|
inline |
|
inlinenoexcept |
|
inline |
|
inline |
This defines an arbitrary order on tiles for use in std::map etc.
|
inline |
|
inlinenoexcept |
Compare whether two Coordinates are identical. Might not give the right result if the coordinates have been the result of some calculation that introduced rounding errors.
|
inline |
Tiles are equal if all their attributes are equal.
|
inlinenoexcept |
Convert angle from radians to degrees.
|
inline |
Transform coordinates from one CRS into another. Wraps the same function of the proj library.
Coordinates have to be in radians and are produced in radians.
osmmium::projection_error | if the projection fails |
constexpr double osmium::geom::MERCATOR_MAX_LAT = 85.0511288 |
The maximum latitude that can be projected with the Web Mercator (EPSG:3857) projection.
constexpr double osmium::geom::PI = 3.14159265358979323846 |