PROJ C++ API
Public Member Functions | Static Public Member Functions | List of all members
osgeo::proj::operation::Transformation Class Reference

A mathematical operation on coordinates in which parameters are empirically derived from data containing the coordinates of a series of points in both coordinate reference systems. More...

#include <coordinateoperation.hpp>

Inheritance diagram for osgeo::proj::operation::Transformation:
Inheritance graph
[legend]
Collaboration diagram for osgeo::proj::operation::Transformation:
Collaboration graph
[legend]

Public Member Functions

const crs::CRSNNPtrsourceCRS () PROJ_CONST_DECL
 Return the source crs::CRS of the transformation. More...
 
const crs::CRSNNPtrtargetCRS () PROJ_CONST_DECL
 Return the target crs::CRS of the transformation. More...
 
CoordinateOperationNNPtr inverse () const override
 Return the inverse of the coordinate operation. More...
 
std::vector< double > getTOWGS84Parameters () const
 Return the TOWGS84 parameters of the transformation. More...
 
TransformationNNPtr substitutePROJAlternativeGridNames (io::DatabaseContextNNPtr databaseContext) const
 Return an equivalent transformation to the current one, but using PROJ alternative grid names.
 
- Public Member Functions inherited from osgeo::proj::operation::SingleOperation
const std::vector< GeneralParameterValueNNPtr > & parameterValues () PROJ_CONST_DECL
 Return the parameter values. More...
 
const OperationMethodNNPtrmethod () PROJ_CONST_DECL
 Return the operation method associated to the operation. More...
 
const ParameterValuePtrparameterValue (const std::string &paramName, int epsg_code=0) const noexcept
 Return the parameter value corresponding to a parameter name or EPSG code. More...
 
const common::MeasureparameterValueMeasure (const std::string &paramName, int epsg_code=0) const noexcept
 Return the parameter value, as a measure, corresponding to a parameter name or EPSG code. More...
 
bool isEquivalentTo (const util::IComparable *other, util::IComparable::Criterion criterion=util::IComparable::Criterion::STRICT) const override
 Returns whether an object is equivalent to another one. More...
 
std::set< GridDescriptiongridsNeeded (const io::DatabaseContextPtr &databaseContext) const override
 Return grids needed by an operation.
 
- Public Member Functions inherited from osgeo::proj::operation::CoordinateOperation
const util::optional< std::string > & operationVersion () const
 Return the version of the coordinate transformation (i.e. instantiation due to the stochastic nature of the parameters). More...
 
const std::vector< metadata::PositionalAccuracyNNPtr > & coordinateOperationAccuracies () const
 Return estimate(s) of the impact of this coordinate operation on point accuracy. More...
 
const crs::CRSPtr sourceCRS () const
 Return the source CRS of this coordinate operation. More...
 
const crs::CRSPtr targetCRS () const
 Return the target CRS of this coordinate operation. More...
 
const crs::CRSPtrinterpolationCRS () const
 Return the interpolation CRS of this coordinate operation. More...
 
const util::optional< common::DataEpoch > & sourceCoordinateEpoch () const
 Return the source epoch of coordinates. More...
 
const util::optional< common::DataEpoch > & targetCoordinateEpoch () const
 Return the target epoch of coordinates. More...
 
bool isPROJInstanciable (const io::DatabaseContextPtr &databaseContext) const
 Return whether a coordinate operation can be instanciated as a PROJ pipeline, checking in particular that referenced grids are available.
 
- Public Member Functions inherited from osgeo::proj::common::ObjectUsage
const std::vector< ObjectDomainNNPtr > & domains () PROJ_CONST_DECL
 Return the domains of the object.
 
- Public Member Functions inherited from osgeo::proj::common::IdentifiedObject
const metadata::IdentifierNNPtrname () PROJ_CONST_DECL
 Return the name of the object. More...
 
const std::string & nameStr () PROJ_CONST_DECL
 Return the name of the object. More...
 
const std::vector< metadata::IdentifierNNPtr > & identifiers () PROJ_CONST_DECL
 Return the identifier(s) of the object. More...
 
const std::vector< util::GenericNameNNPtr > & aliases () PROJ_CONST_DECL
 Return the alias(es) of the object.
 
const std::string & remarks () PROJ_CONST_DECL
 Return the remarks.
 
bool isDeprecated () PROJ_CONST_DECL
 Return whether the object is deprecated. More...
 
std::string alias () PROJ_CONST_DECL
 Return the (first) alias of the object as a string. More...
 
int getEPSGCode () PROJ_CONST_DECL
 Return the EPSG code. More...
 
bool isEPSG (int code) PROJ_CONST_DECL
 Return whether the object has a identifiers() in the EPSG code space.
 
- Public Member Functions inherited from osgeo::proj::io::IWKTExportable
std::string exportToWKT (WKTFormatter *formatter) const
 
- Public Member Functions inherited from osgeo::proj::io::IPROJStringExportable
std::string exportToPROJString (PROJStringFormatter *formatter) const
 Builds a PROJ string representation. More...
 

Static Public Member Functions

static TransformationNNPtr create (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const crs::CRSPtr &interpolationCRSIn, const OperationMethodNNPtr &methodIn, const std::vector< GeneralParameterValueNNPtr > &values, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation from a vector of GeneralParameterValue. More...
 
static TransformationNNPtr create (const util::PropertyMap &propertiesTransformation, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const crs::CRSPtr &interpolationCRSIn, const util::PropertyMap &propertiesOperationMethod, const std::vector< OperationParameterNNPtr > &parameters, const std::vector< ParameterValueNNPtr > &values, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation ands its OperationMethod. More...
 
static TransformationNNPtr createGeocentricTranslations (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, double translationXMetre, double translationYMetre, double translationZMetre, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with Geocentric Translations method. More...
 
static TransformationNNPtr createPositionVector (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, double translationXMetre, double translationYMetre, double translationZMetre, double rotationXArcSecond, double rotationYArcSecond, double rotationZArcSecond, double scaleDifferencePPM, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with Position vector transformation method. More...
 
static TransformationNNPtr createCoordinateFrameRotation (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, double translationXMetre, double translationYMetre, double translationZMetre, double rotationXArcSecond, double rotationYArcSecond, double rotationZArcSecond, double scaleDifferencePPM, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with Coordinate Frame Rotation method. More...
 
static TransformationNNPtr createTimeDependentPositionVector (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, double translationXMetre, double translationYMetre, double translationZMetre, double rotationXArcSecond, double rotationYArcSecond, double rotationZArcSecond, double scaleDifferencePPM, double rateTranslationX, double rateTranslationY, double rateTranslationZ, double rateRotationX, double rateRotationY, double rateRotationZ, double rateScaleDifference, double referenceEpochYear, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with Time Dependent position vector transformation method. More...
 
static TransformationNNPtr createTimeDependentCoordinateFrameRotation (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, double translationXMetre, double translationYMetre, double translationZMetre, double rotationXArcSecond, double rotationYArcSecond, double rotationZArcSecond, double scaleDifferencePPM, double rateTranslationX, double rateTranslationY, double rateTranslationZ, double rateRotationX, double rateRotationY, double rateRotationZ, double rateScaleDifference, double referenceEpochYear, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with Time Dependent Position coordinate frame rotation transformation method. More...
 
static TransformationNNPtr createTOWGS84 (const crs::CRSNNPtr &sourceCRSIn, const std::vector< double > &TOWGS84Parameters)
 Instanciate a transformation from TOWGS84 parameters. More...
 
static TransformationNNPtr createNTv2 (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const std::string &filename, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with NTv2 method. More...
 
static TransformationNNPtr createMolodensky (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, double translationXMetre, double translationYMetre, double translationZMetre, double semiMajorAxisDifferenceMetre, double flattingDifference, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with Molodensky method. More...
 
static TransformationNNPtr createAbridgedMolodensky (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, double translationXMetre, double translationYMetre, double translationZMetre, double semiMajorAxisDifferenceMetre, double flattingDifference, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with Abridged Molodensky method. More...
 
static TransformationNNPtr createGravityRelatedHeightToGeographic3D (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const std::string &filename, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation from GravityRelatedHeight to Geographic3D. More...
 
static TransformationNNPtr createVERTCON (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const std::string &filename, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with method VERTCON. More...
 
static TransformationNNPtr createLongitudeRotation (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const common::Angle &offset)
 Instanciate a transformation with method Longitude rotation. More...
 
static TransformationNNPtr createGeographic2DOffsets (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const common::Angle &offsetLat, const common::Angle &offsetLon, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with method Geographic 2D offsets. More...
 
static TransformationNNPtr createGeographic3DOffsets (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const common::Angle &offsetLat, const common::Angle &offsetLon, const common::Length &offsetHeight, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with method Geographic 3D offsets. More...
 
static TransformationNNPtr createGeographic2DWithHeightOffsets (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const common::Angle &offsetLat, const common::Angle &offsetLon, const common::Length &offsetHeight, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with method Geographic 2D with height offsets. More...
 
static TransformationNNPtr createVerticalOffset (const util::PropertyMap &properties, const crs::CRSNNPtr &sourceCRSIn, const crs::CRSNNPtr &targetCRSIn, const common::Length &offsetHeight, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies)
 Instanciate a transformation with method Vertical Offset. More...
 
- Static Public Member Functions inherited from osgeo::proj::operation::SingleOperation
static SingleOperationNNPtr createPROJBased (const util::PropertyMap &properties, const std::string &PROJString, const crs::CRSPtr &sourceCRS, const crs::CRSPtr &targetCRS, const std::vector< metadata::PositionalAccuracyNNPtr > &accuracies=std::vector< metadata::PositionalAccuracyNNPtr >())
 Instanciate a PROJ-based single operation;. More...
 
- Static Public Member Functions inherited from osgeo::proj::common::IdentifiedObject
static IdentifiedObjectNNPtr create (const util::PropertyMap &properties)
 Instanciate a new IdentifiedObject. More...
 

Additional Inherited Members

- Public Types inherited from osgeo::proj::util::IComparable
enum  Criterion { Criterion::STRICT, Criterion::EQUIVALENT }
 Comparison criterion. More...
 
- Static Public Attributes inherited from osgeo::proj::common::ObjectUsage
static const std::string SCOPE_KEY
 Key to set the scope of a common::ObjectUsage. More...
 
static const std::string DOMAIN_OF_VALIDITY_KEY
 Key to set the domain of validity of a common::ObjectUsage. More...
 
static const std::string OBJECT_DOMAIN_KEY
 Key to set the object domain(s) of a common::ObjectUsage. More...
 
- Static Public Attributes inherited from osgeo::proj::common::IdentifiedObject
static const std::string NAME_KEY
 Key to set the name of a common::IdentifiedObject. More...
 
static const std::string IDENTIFIERS_KEY
 Key to set the identifier(s) of a common::IdentifiedObject. More...
 
static const std::string ALIAS_KEY
 Key to set the alias(es) of a common::IdentifiedObject. More...
 
static const std::string REMARKS_KEY
 Key to set the remarks of a common::IdentifiedObject. More...
 
static const std::string DEPRECATED_KEY
 Key to set the deprecation flag of a common::IdentifiedObject. More...
 

Detailed Description

A mathematical operation on coordinates in which parameters are empirically derived from data containing the coordinates of a series of points in both coordinate reference systems.

This computational process is usually "over-determined", allowing derivation of error (or accuracy) estimates for the coordinate transformation. Also, the stochastic nature of the parameters may result in multiple (different) versions of the same coordinate transformations between the same source and target CRSs. Any single coordinate operation in which the input and output coordinates are referenced to different datums (reference frames) will be a coordinate transformation.

Remarks
Implements Transformation from ISO 19111:2018

Member Function Documentation

TransformationNNPtr osgeo::proj::operation::Transformation::create ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const crs::CRSPtr interpolationCRSIn,
const OperationMethodNNPtr methodIn,
const std::vector< GeneralParameterValueNNPtr > &  values,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation from a vector of GeneralParameterValue.

Parameters
propertiesSee General properties. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
interpolationCRSInInterpolation CRS (might be null)
methodInOperation method.
valuesVector of GeneralOperationParameterNNPtr.
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
Exceptions
InvalidOperation
TransformationNNPtr osgeo::proj::operation::Transformation::create ( const util::PropertyMap propertiesTransformation,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const crs::CRSPtr interpolationCRSIn,
const util::PropertyMap propertiesOperationMethod,
const std::vector< OperationParameterNNPtr > &  parameters,
const std::vector< ParameterValueNNPtr > &  values,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation ands its OperationMethod.

Parameters
propertiesTransformationThe General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
interpolationCRSInInterpolation CRS (might be null)
propertiesOperationMethodThe General properties of the OperationMethod. At minimum the name should be defined.
parametersVector of parameters of the operation method.
valuesVector of ParameterValueNNPtr. Constraint: values.size() == parameters.size()
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
Exceptions
InvalidOperation
TransformationNNPtr osgeo::proj::operation::Transformation::createAbridgedMolodensky ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
double  translationXMetre,
double  translationYMetre,
double  translationZMetre,
double  semiMajorAxisDifferenceMetre,
double  flattingDifference,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with Abridged Molodensky method.

See also
createdMolodensky() for a related method.

This method is defined as EPSG:9605

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
translationXMetreValue of the Translation_X parameter (in metre).
translationYMetreValue of the Translation_Y parameter (in metre).
translationZMetreValue of the Translation_Z parameter (in metre).
semiMajorAxisDifferenceMetreThe difference between the semi-major axis values of the ellipsoids used in the target and source CRS (in metre).
flattingDifferenceThe difference between the flattening values of the ellipsoids used in the target and source CRS.
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
Exceptions
InvalidOperation
TransformationNNPtr osgeo::proj::operation::Transformation::createCoordinateFrameRotation ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
double  translationXMetre,
double  translationYMetre,
double  translationZMetre,
double  rotationXArcSecond,
double  rotationYArcSecond,
double  rotationZArcSecond,
double  scaleDifferencePPM,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with Coordinate Frame Rotation method.

This is similar to createPositionVector(), except that the sign of the rotation terms is inverted.

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
translationXMetreValue of the Translation_X parameter (in metre).
translationYMetreValue of the Translation_Y parameter (in metre).
translationZMetreValue of the Translation_Z parameter (in metre).
rotationXArcSecondValue of the Rotation_X parameter (in arc-second).
rotationYArcSecondValue of the Rotation_Y parameter (in arc-second).
rotationZArcSecondValue of the Rotation_Z parameter (in arc-second).
scaleDifferencePPMValue of the Scale_Difference parameter (in parts-per-million).
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createGeocentricTranslations ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
double  translationXMetre,
double  translationYMetre,
double  translationZMetre,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with Geocentric Translations method.

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
translationXMetreValue of the Translation_X parameter (in metre).
translationYMetreValue of the Translation_Y parameter (in metre).
translationZMetreValue of the Translation_Z parameter (in metre).
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createGeographic2DOffsets ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const common::Angle offsetLat,
const common::Angle offsetLon,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with method Geographic 2D offsets.

This method is defined as EPSG:9619

  • Parameters
    propertiesSee General properties of the Transformation. At minimum the name should be defined.
    sourceCRSInSource CRS.
    targetCRSInTarget CRS.
    offsetLatLatitude offset to add.
    offsetLonLongitude offset to add.
    accuraciesVector of positional accuracy (might be empty).
    Returns
    new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createGeographic2DWithHeightOffsets ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const common::Angle offsetLat,
const common::Angle offsetLon,
const common::Length offsetHeight,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with method Geographic 2D with height offsets.

This method is defined as EPSG:9618

  • Parameters
    propertiesSee General properties of the Transformation. At minimum the name should be defined.
    sourceCRSInSource CRS.
    targetCRSInTarget CRS.
    offsetLatLatitude offset to add.
    offsetLonLongitude offset to add.
    offsetHeightGeoid undulation to add.
    accuraciesVector of positional accuracy (might be empty).
    Returns
    new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createGeographic3DOffsets ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const common::Angle offsetLat,
const common::Angle offsetLon,
const common::Length offsetHeight,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with method Geographic 3D offsets.

This method is defined as EPSG:9660

  • Parameters
    propertiesSee General properties of the Transformation. At minimum the name should be defined.
    sourceCRSInSource CRS.
    targetCRSInTarget CRS.
    offsetLatLatitude offset to add.
    offsetLonLongitude offset to add.
    offsetHeightHeight offset to add.
    accuraciesVector of positional accuracy (might be empty).
    Returns
    new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createGravityRelatedHeightToGeographic3D ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const std::string &  filename,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation from GravityRelatedHeight to Geographic3D.

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
filenameGRID filename.
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createLongitudeRotation ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const common::Angle offset 
)
static

Instanciate a transformation with method Longitude rotation.

This method is defined as EPSG:9601

TransformationNNPtr osgeo::proj::operation::Transformation::createMolodensky ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
double  translationXMetre,
double  translationYMetre,
double  translationZMetre,
double  semiMajorAxisDifferenceMetre,
double  flattingDifference,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with Molodensky method.

See also
createAbridgedMolodensky() for a related method.

This method is defined as EPSG:9604

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
translationXMetreValue of the Translation_X parameter (in metre).
translationYMetreValue of the Translation_Y parameter (in metre).
translationZMetreValue of the Translation_Z parameter (in metre).
semiMajorAxisDifferenceMetreThe difference between the semi-major axis values of the ellipsoids used in the target and source CRS (in metre).
flattingDifferenceThe difference between the flattening values of the ellipsoids used in the target and source CRS.
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
Exceptions
InvalidOperation
TransformationNNPtr osgeo::proj::operation::Transformation::createNTv2 ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const std::string &  filename,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with NTv2 method.

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
filenameNTv2 filename.
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createPositionVector ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
double  translationXMetre,
double  translationYMetre,
double  translationZMetre,
double  rotationXArcSecond,
double  rotationYArcSecond,
double  rotationZArcSecond,
double  scaleDifferencePPM,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with Position vector transformation method.

This is similar to createCoordinateFrameRotation(), except that the sign of the rotation terms is inverted.

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
translationXMetreValue of the Translation_X parameter (in metre).
translationYMetreValue of the Translation_Y parameter (in metre).
translationZMetreValue of the Translation_Z parameter (in metre).
rotationXArcSecondValue of the Rotation_X parameter (in arc-second).
rotationYArcSecondValue of the Rotation_Y parameter (in arc-second).
rotationZArcSecondValue of the Rotation_Z parameter (in arc-second).
scaleDifferencePPMValue of the Scale_Difference parameter (in parts-per-million).
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createTimeDependentCoordinateFrameRotation ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
double  translationXMetre,
double  translationYMetre,
double  translationZMetre,
double  rotationXArcSecond,
double  rotationYArcSecond,
double  rotationZArcSecond,
double  scaleDifferencePPM,
double  rateTranslationX,
double  rateTranslationY,
double  rateTranslationZ,
double  rateRotationX,
double  rateRotationY,
double  rateRotationZ,
double  rateScaleDifference,
double  referenceEpochYear,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with Time Dependent Position coordinate frame rotation transformation method.

This is similar to createTimeDependentPositionVector(), except that the sign of the rotation terms is inverted.

This method is defined as EPSG:1056

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
translationXMetreValue of the Translation_X parameter (in metre).
translationYMetreValue of the Translation_Y parameter (in metre).
translationZMetreValue of the Translation_Z parameter (in metre).
rotationXArcSecondValue of the Rotation_X parameter (in arc-second).
rotationYArcSecondValue of the Rotation_Y parameter (in arc-second).
rotationZArcSecondValue of the Rotation_Z parameter (in arc-second).
scaleDifferencePPMValue of the Scale_Difference parameter (in parts-per-million).
rateTranslationXValue of the rate of change of X-axis translation (in metre/year)
rateTranslationYValue of the rate of change of Y-axis translation (in metre/year)
rateTranslationZValue of the rate of change of Z-axis translation (in metre/year)
rateRotationXValue of the rate of change of X-axis rotation (in arc-second/year)
rateRotationYValue of the rate of change of Y-axis rotation (in arc-second/year)
rateRotationZValue of the rate of change of Z-axis rotation (in arc-second/year)
rateScaleDifferenceValue of the rate of change of scale difference (in PPM/year)
referenceEpochYearParameter reference epoch (in decimal year)
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
Exceptions
InvalidOperation
TransformationNNPtr osgeo::proj::operation::Transformation::createTimeDependentPositionVector ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
double  translationXMetre,
double  translationYMetre,
double  translationZMetre,
double  rotationXArcSecond,
double  rotationYArcSecond,
double  rotationZArcSecond,
double  scaleDifferencePPM,
double  rateTranslationX,
double  rateTranslationY,
double  rateTranslationZ,
double  rateRotationX,
double  rateRotationY,
double  rateRotationZ,
double  rateScaleDifference,
double  referenceEpochYear,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with Time Dependent position vector transformation method.

This is similar to createTimeDependentCoordinateFrameRotation(), except that the sign of the rotation terms is inverted.

This method is defined as EPSG:1053

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
translationXMetreValue of the Translation_X parameter (in metre).
translationYMetreValue of the Translation_Y parameter (in metre).
translationZMetreValue of the Translation_Z parameter (in metre).
rotationXArcSecondValue of the Rotation_X parameter (in arc-second).
rotationYArcSecondValue of the Rotation_Y parameter (in arc-second).
rotationZArcSecondValue of the Rotation_Z parameter (in arc-second).
scaleDifferencePPMValue of the Scale_Difference parameter (in parts-per-million).
rateTranslationXValue of the rate of change of X-axis translation (in metre/year)
rateTranslationYValue of the rate of change of Y-axis translation (in metre/year)
rateTranslationZValue of the rate of change of Z-axis translation (in metre/year)
rateRotationXValue of the rate of change of X-axis rotation (in arc-second/year)
rateRotationYValue of the rate of change of Y-axis rotation (in arc-second/year)
rateRotationZValue of the rate of change of Z-axis rotation (in arc-second/year)
rateScaleDifferenceValue of the rate of change of scale difference (in PPM/year)
referenceEpochYearParameter reference epoch (in decimal year)
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createTOWGS84 ( const crs::CRSNNPtr sourceCRSIn,
const std::vector< double > &  TOWGS84Parameters 
)
static

Instanciate a transformation from TOWGS84 parameters.

This is a helper of createPositionVector() with the source CRS being the GeographicCRS of sourceCRSIn, and the target CRS being EPSG:4326

Parameters
sourceCRSInSource CRS.
TOWGS84ParametersThe vector of 3 double values (Translation_X,_Y,_Z) or 7 double values (Translation_X,_Y,_Z, Rotation_X,_Y,_Z, Scale_Difference) passed to createPositionVector()
Returns
new Transformation.
Exceptions
InvalidOperation
TransformationNNPtr osgeo::proj::operation::Transformation::createVERTCON ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const std::string &  filename,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with method VERTCON.

Parameters
propertiesSee General properties of the Transformation. At minimum the name should be defined.
sourceCRSInSource CRS.
targetCRSInTarget CRS.
filenameGRID filename.
accuraciesVector of positional accuracy (might be empty).
Returns
new Transformation.
TransformationNNPtr osgeo::proj::operation::Transformation::createVerticalOffset ( const util::PropertyMap properties,
const crs::CRSNNPtr sourceCRSIn,
const crs::CRSNNPtr targetCRSIn,
const common::Length offsetHeight,
const std::vector< metadata::PositionalAccuracyNNPtr > &  accuracies 
)
static

Instanciate a transformation with method Vertical Offset.

This method is defined as EPSG:9616

  • Parameters
    propertiesSee General properties of the Transformation. At minimum the name should be defined.
    sourceCRSInSource CRS.
    targetCRSInTarget CRS.
    offsetHeightGeoid undulation to add.
    accuraciesVector of positional accuracy (might be empty).
    Returns
    new Transformation.
std::vector< double > osgeo::proj::operation::Transformation::getTOWGS84Parameters ( ) const

Return the TOWGS84 parameters of the transformation.

If this transformation uses Coordinate Frame Rotation, Position Vector transformation or Geocentric translations, a vector of 7 double values using the Position Vector convention (EPSG:9606) is returned. Those values can be used as the value of the WKT1 TOWGS84 parameter or PROJ +towgs84 parameter.

Returns
a vector of 7 values if valid, otherwise a io::FormattingException is thrown.
Exceptions
io::FormattingException
CoordinateOperationNNPtr osgeo::proj::operation::Transformation::inverse ( ) const
overridevirtual

Return the inverse of the coordinate operation.

Exceptions
util::UnsupportedOperationException

Implements osgeo::proj::operation::CoordinateOperation.

const crs::CRSNNPtr & osgeo::proj::operation::Transformation::sourceCRS ( )

Return the source crs::CRS of the transformation.

Returns
the source CRS.
const crs::CRSNNPtr & osgeo::proj::operation::Transformation::targetCRS ( )

Return the target crs::CRS of the transformation.

Returns
the target CRS.

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