Public Member Functions | Protected Attributes | List of all members
gnsstk::Transformer Class Referenceabstract

Detailed Description

Provide an abstract base class for tools that can transform between coordinate systems, e.g. HelmertTransformer.

Definition at line 57 of file Transformer.hpp.

#include <Transformer.hpp>

Inheritance diagram for gnsstk::Transformer:
Inheritance graph
[legend]

Public Member Functions

const CommonTimegetEpoch () const noexcept
 
const RefFramegetFromFrame () const noexcept
 Return the RefFrame this Transformer will convert from. More...
 
const RefFramegetToFrame () const noexcept
 Return the RefFrame this Transformer will convert to. More...
 
virtual bool transform (const Position &fromPos, Position &toPos) const noexcept=0
 
virtual bool transform (const Triple &fromPos, const RefFrame &srcFrame, Triple &toPos) const noexcept=0
 
virtual bool transform (const Vector< double > &fromPos, const RefFrame &srcFrame, Vector< double > &toPos) const noexcept=0
 
virtual bool transform (const Xvt &fromPos, Xvt &toPos) const noexcept=0
 
virtual bool transform (double fx, double fy, double fz, const RefFrame &srcFrame, double &tx, double &ty, double &tz) const noexcept=0
 
 Transformer ()
 

Protected Attributes

CommonTime epoch
 When this Transformer was first applicable. More...
 
RefFrame fromFrame
 The reference frame we can transform from. More...
 
RefFrame toFrame
 The reference frame we can transform to. More...
 

Constructor & Destructor Documentation

◆ Transformer()

gnsstk::Transformer::Transformer ( )
inline

Definition at line 61 of file Transformer.hpp.

Member Function Documentation

◆ getEpoch()

const CommonTime& gnsstk::Transformer::getEpoch ( ) const
inlinenoexcept

Return the first time this Transformer is applicable. This is not the reference frame publication date. This is to allow the use of transformation sources that use the same reference frame realizations, but the transformation parameters change over time.

Definition at line 153 of file Transformer.hpp.

◆ getFromFrame()

const RefFrame& gnsstk::Transformer::getFromFrame ( ) const
inlinenoexcept

Return the RefFrame this Transformer will convert from.

Definition at line 143 of file Transformer.hpp.

◆ getToFrame()

const RefFrame& gnsstk::Transformer::getToFrame ( ) const
inlinenoexcept

Return the RefFrame this Transformer will convert to.

Definition at line 146 of file Transformer.hpp.

◆ transform() [1/5]

virtual bool gnsstk::Transformer::transform ( const Position fromPos,
Position toPos 
) const
pure virtualnoexcept

Convert a position from the reference frame in fromPos to that in toPos.

Precondition
RefFrame must be set in both fromPos and toPos.
Coordinates must be set in fromPos.
Postcondition
Coordinates in toPos reference frame realization are set in toPos.
Parameters
[in]fromPosThe Position to be converted.
[in,out]toPosThe Position to store the converted position.
Returns
true on success, false on failure (typically if the Position RefFrame objects don't match the ones in this Transformer).

Implemented in gnsstk::HelmertTransformer, and FakeTransformer.

◆ transform() [2/5]

virtual bool gnsstk::Transformer::transform ( const Triple fromPos,
const RefFrame srcFrame,
Triple toPos 
) const
pure virtualnoexcept

Convert a position in fromPos from the reference frame in srcFrame to that in tgtFrame.

Precondition
Coordinates must be set in fromPos.
Postcondition
Coordinates in toFrame reference frame realization are set in toPos. Velocity and clock offset are unaffected.
Parameters
[in]fromPosThe Vector whose position is to be converted.
[in]srcFrameThe RefFrame of the coordinates in fromPos.
[out]toPosThe Vector to store the converted position.
Returns
true on success, false on failure (typically if srcFrame doesn't match fromFrame).

Implemented in gnsstk::HelmertTransformer, and FakeTransformer.

◆ transform() [3/5]

virtual bool gnsstk::Transformer::transform ( const Vector< double > &  fromPos,
const RefFrame srcFrame,
Vector< double > &  toPos 
) const
pure virtualnoexcept

Convert a position from the reference frame in fromPos to that in toPos.

Precondition
Coordinates must be set in fromPos.
Postcondition
Coordinates in toFrame reference frame realization are set in toPos. Velocity and clock offset are unaffected.
Parameters
[in]fromPosThe Vector whose position is to be converted.
[in]srcFrameThe RefFrame of the coordinates in fromPos.
[out]toPosThe Vector to store the converted position.
Returns
true on success, false on failure (typically if srcFrame doesn't match fromFrame).

Implemented in gnsstk::HelmertTransformer, and FakeTransformer.

◆ transform() [4/5]

virtual bool gnsstk::Transformer::transform ( const Xvt fromPos,
Xvt toPos 
) const
pure virtualnoexcept

Convert a position from the reference frame in fromPos to that in toPos.

Precondition
RefFrame must be set in both fromPos and toPos.
Coordinates must be set in fromPos.
Postcondition
Coordinates in toPos reference frame realization are set in toPos. Velocity and clock offset are unaffected.
Parameters
[in]fromPosThe Xvt whose position is to be converted.
[in,out]toPosThe Xvt to store the converted position.
Returns
true on success, false on failure (typically if the Xvt RefFrame objects don't match the ones in this Transformer).

Implemented in gnsstk::HelmertTransformer, and FakeTransformer.

◆ transform() [5/5]

virtual bool gnsstk::Transformer::transform ( double  fx,
double  fy,
double  fz,
const RefFrame srcFrame,
double &  tx,
double &  ty,
double &  tz 
) const
pure virtualnoexcept

Convert 3 doubles from the reference frame in srcFrame to that in tgtFrame.

Precondition
Coordinates must be set in fromPos.
Postcondition
Coordinates in toFrame reference frame realization are set in toPos. Velocity and clock offset are unaffected.
Parameters
[in]fxECEF x coordinate in meters in srcFrame.
[in]fyECEF y coordinate in meters in srcFrame.
[in]fzECEF z coordinate in meters in srcFrame.
[in]srcFrameThe RefFrame of the coordinates in fromPos.
[out]txECEF x coordinate in meters in srcFrame.
[out]tyECEF y coordinate in meters in srcFrame.
[out]tzECEF z coordinate in meters in srcFrame.
Returns
true on success, false on failure (typically if srcFrame doesn't match fromFrame).

Implemented in gnsstk::HelmertTransformer, and FakeTransformer.

Member Data Documentation

◆ epoch

CommonTime gnsstk::Transformer::epoch
protected

When this Transformer was first applicable.

Definition at line 159 of file Transformer.hpp.

◆ fromFrame

RefFrame gnsstk::Transformer::fromFrame
protected

The reference frame we can transform from.

Definition at line 157 of file Transformer.hpp.

◆ toFrame

RefFrame gnsstk::Transformer::toFrame
protected

The reference frame we can transform to.

Definition at line 158 of file Transformer.hpp.


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


gnsstk
Author(s):
autogenerated on Wed Oct 25 2023 02:40:46