NDEVR
API Documentation
Proj4CoordinateConverter

A CoordinateConverter implementation using the PROJ library for geodetic transformations. More...

Inheritance diagram for Proj4CoordinateConverter:
[legend]
Collaboration diagram for Proj4CoordinateConverter:
[legend]

Public Member Functions

 Proj4CoordinateConverter (const CoordinateProjection &to_projection, const CoordinateProjection &from_projection)
 Constructs a converter between two coordinate projections.
 ~Proj4CoordinateConverter ()
 Destroys the converter and releases PROJ resources.
Bounds< 2, fltp08convert (const Bounds< 2, fltp08 > &location, bool inverse=false) const override
 Converts a 2D bounding box between coordinate systems.
Bounds< 3, fltp08convert (const Bounds< 3, fltp08 > &location, bool inverse=false) const override
 Converts a 3D bounding box between coordinate systems.
Matrix< fltp08convert (const Matrix< fltp08 > &location, bool inverse=false) const override
 Converts a transformation matrix between coordinate systems.
Vertex< 2, fltp08convert (const Vertex< 2, fltp08 > &location, bool inverse=false) const override
 Converts a 2D vertex between coordinate systems.
Vertex< 3, fltp08convert (const Vertex< 3, fltp08 > &location, bool inverse=false) const override
 Converts a 3D vertex between coordinate systems.
void setDestinationProjection (const CoordinateProjection &to_projection) override
 Sets the destination coordinate projection.
void setSourceProjection (const CoordinateProjection &from_projection) override
 Sets the source coordinate projection.
Public Member Functions inherited from CoordinateConverter
 CoordinateConverter (const CoordinateProjection &to_projection, const CoordinateProjection &from_projection)
 Constructs a CoordinateConverter with the given source and destination projections.
virtual ~CoordinateConverter ()
 Virtual destructor for safe polymorphic deletion.
CoordinateProjection fromProjection ()
 Returns the source coordinate projection.
CoordinateProjection toProjection ()
 Returns the destination coordinate projection.

Protected Member Functions

void destroyTransform ()
 Destroys the internal PROJ transform and context.
void rebuildTransform ()
 Rebuilds the internal PROJ transform from current projections.

Protected Attributes

void * m_context
 The PROJ threading context.
void * m_transform
 The PROJ transformation object.
Protected Attributes inherited from CoordinateConverter
CoordinateProjection m_from_projection
 The source coordinate projection to convert from.
CoordinateProjection m_to_projection
 The destination coordinate projection to convert into.

Detailed Description

A CoordinateConverter implementation using the PROJ library for geodetic transformations.


Definition at line 10 of file Proj4CoordinateConverter.h.

Constructor & Destructor Documentation

◆ Proj4CoordinateConverter()

Proj4CoordinateConverter::Proj4CoordinateConverter ( const CoordinateProjection & to_projection,
const CoordinateProjection & from_projection )

Constructs a converter between two coordinate projections.

Parameters
[in]to_projectionThe destination coordinate projection.
[in]from_projectionThe source coordinate projection.

Member Function Documentation

◆ convert() [1/5]

Bounds< 2, fltp08 > Proj4CoordinateConverter::convert ( const Bounds< 2, fltp08 > & location,
bool inverse = false ) const
overridevirtual

Converts a 2D bounding box between coordinate systems.

Parameters
[in]locationThe bounding box to convert.
[in]inverseWhether to perform the inverse transformation.
Returns
The converted bounding box.

Implements CoordinateConverter.

◆ convert() [2/5]

Bounds< 3, fltp08 > Proj4CoordinateConverter::convert ( const Bounds< 3, fltp08 > & location,
bool inverse = false ) const
overridevirtual

Converts a 3D bounding box between coordinate systems.

Parameters
[in]locationThe bounding box to convert.
[in]inverseWhether to perform the inverse transformation.
Returns
The converted bounding box.

Implements CoordinateConverter.

◆ convert() [3/5]

Matrix< fltp08 > Proj4CoordinateConverter::convert ( const Matrix< fltp08 > & location,
bool inverse = false ) const
overridevirtual

Converts a transformation matrix between coordinate systems.

Parameters
[in]locationThe matrix to convert.
[in]inverseWhether to perform the inverse transformation.
Returns
The converted matrix.

Implements CoordinateConverter.

◆ convert() [4/5]

Vertex< 2, fltp08 > Proj4CoordinateConverter::convert ( const Vertex< 2, fltp08 > & location,
bool inverse = false ) const
overridevirtual

Converts a 2D vertex between coordinate systems.

Parameters
[in]locationThe vertex to convert.
[in]inverseWhether to perform the inverse transformation.
Returns
The converted vertex.

Implements CoordinateConverter.

◆ convert() [5/5]

Vertex< 3, fltp08 > Proj4CoordinateConverter::convert ( const Vertex< 3, fltp08 > & location,
bool inverse = false ) const
overridevirtual

Converts a 3D vertex between coordinate systems.

Parameters
[in]locationThe vertex to convert.
[in]inverseWhether to perform the inverse transformation.
Returns
The converted vertex.

Implements CoordinateConverter.

◆ setDestinationProjection()

void Proj4CoordinateConverter::setDestinationProjection ( const CoordinateProjection & to_projection)
overridevirtual

Sets the destination coordinate projection.

Parameters
[in]to_projectionThe destination projection to set.

Implements CoordinateConverter.

◆ setSourceProjection()

void Proj4CoordinateConverter::setSourceProjection ( const CoordinateProjection & from_projection)
overridevirtual

Sets the source coordinate projection.

Parameters
[in]from_projectionThe source projection to set.

Implements CoordinateConverter.


The documentation for this class was generated from the following file: