QGIS API Documentation 3.29.0-Master (006c3c0232)
Classes | Public Member Functions | List of all members
QgsHelmertGeorefTransform Class Reference

2-dimensional helmert transform, parametrised by isotropic scale, rotation angle and translation. More...

#include <qgsgcptransformer.h>

Inheritance diagram for QgsHelmertGeorefTransform:
Inheritance graph
[legend]

Public Member Functions

 QgsHelmertGeorefTransform ()=default
 Constructor for QgsHelmertGeorefTransform. More...
 
QgsGcpTransformerInterfaceclone () const override
 Clones the transformer, returning a new copy of the transformer with the same parameters as this one. More...
 
GDALTransformerFunc GDALTransformer () const override
 Returns function pointer to the GDALTransformer function. More...
 
void * GDALTransformerArgs () const override
 Returns pointer to the GDALTransformer arguments. More...
 
bool getOriginScaleRotation (QgsPointXY &origin, double &scale, double &rotation) const
 Returns the origin, scale and rotation for the transform. More...
 
TransformMethod method () const override
 Returns the transformation method. More...
 
int minimumGcpCount () const override
 Returns the minimum number of Ground Control Points (GCPs) required for parameter fitting. More...
 
bool updateParametersFromGcps (const QVector< QgsPointXY > &sourceCoordinates, const QVector< QgsPointXY > &destinationCoordinates, bool invertYAxis=false) override
 Fits transformation parameters using the specified Ground Control Points (GCPs) lists of source and destination coordinates. More...
 
- Public Member Functions inherited from QgsGcpTransformerInterface
 QgsGcpTransformerInterface ()=default
 Constructor for QgsGcpTransformerInterface. More...
 
 QgsGcpTransformerInterface (const QgsGcpTransformerInterface &other)=delete
 QgsGcpTransformerInterface cannot be copied - use clone() instead. More...
 
virtual ~QgsGcpTransformerInterface ()=default
 
virtual QgsGcpTransformerInterfaceclone () const =0
 Clones the transformer, returning a new copy of the transformer with the same parameters as this one. More...
 
virtual GDALTransformerFunc GDALTransformer () const =0
 Returns function pointer to the GDALTransformer function. More...
 
virtual void * GDALTransformerArgs () const =0
 Returns pointer to the GDALTransformer arguments. More...
 
virtual TransformMethod method () const =0
 Returns the transformation method. More...
 
virtual int minimumGcpCount () const =0
 Returns the minimum number of Ground Control Points (GCPs) required for parameter fitting. More...
 
QgsGcpTransformerInterfaceoperator= (const QgsGcpTransformerInterface &other)=delete
 QgsGcpTransformerInterface cannot be copied - use clone() instead. More...
 
bool transform (double &x, double &y, bool inverseTransform=false) const
 Transforms the point (x, y) from source to destination coordinates. More...
 
virtual bool updateParametersFromGcps (const QVector< QgsPointXY > &sourceCoordinates, const QVector< QgsPointXY > &destinationCoordinates, bool invertYAxis=false) SIP_THROW(QgsNotSupportedException)=0
 Fits transformation parameters using the specified Ground Control Points (GCPs) lists of source and destination coordinates. More...
 

Additional Inherited Members

- Public Types inherited from QgsGcpTransformerInterface
enum class  TransformMethod : int {
  Linear , Helmert , PolynomialOrder1 , PolynomialOrder2 ,
  PolynomialOrder3 , ThinPlateSpline , Projective , InvalidTransform = 65535
}
 Available transformation methods. More...
 
- Static Public Member Functions inherited from QgsGcpTransformerInterface
static QgsGcpTransformerInterfacecreate (TransformMethod method)
 Creates a new QgsGcpTransformerInterface subclass representing the specified transform method. More...
 
static QgsGcpTransformerInterfacecreateFromParameters (TransformMethod method, const QVector< QgsPointXY > &sourceCoordinates, const QVector< QgsPointXY > &destinationCoordinates) SIP_THROW(QgsNotSupportedException)
 Creates a new QgsGcpTransformerInterface subclass representing the specified transform method, initialized using the given lists of source and destination coordinates. More...
 
static QString methodToString (TransformMethod method)
 Returns a translated string representing the specified transform method. More...
 

Detailed Description

2-dimensional helmert transform, parametrised by isotropic scale, rotation angle and translation.

Note
Not available in Python bindings
Since
QGIS 3.20

Definition at line 190 of file qgsgcptransformer.h.

Constructor & Destructor Documentation

◆ QgsHelmertGeorefTransform()

QgsHelmertGeorefTransform::QgsHelmertGeorefTransform ( )
default

Constructor for QgsHelmertGeorefTransform.

Member Function Documentation

◆ clone()

QgsGcpTransformerInterface * QgsHelmertGeorefTransform::clone ( ) const
overridevirtual

Clones the transformer, returning a new copy of the transformer with the same parameters as this one.

Caller takes ownership of the returned object.

Implements QgsGcpTransformerInterface.

Definition at line 236 of file qgsgcptransformer.cpp.

◆ GDALTransformer()

GDALTransformerFunc QgsHelmertGeorefTransform::GDALTransformer ( ) const
overridevirtual

Returns function pointer to the GDALTransformer function.

Implements QgsGcpTransformerInterface.

Definition at line 213 of file qgsgcptransformer.cpp.

◆ GDALTransformerArgs()

void * QgsHelmertGeorefTransform::GDALTransformerArgs ( ) const
overridevirtual

Returns pointer to the GDALTransformer arguments.

Implements QgsGcpTransformerInterface.

Definition at line 218 of file qgsgcptransformer.cpp.

◆ getOriginScaleRotation()

bool QgsHelmertGeorefTransform::getOriginScaleRotation ( QgsPointXY origin,
double &  scale,
double &  rotation 
) const

Returns the origin, scale and rotation for the transform.

Definition at line 228 of file qgsgcptransformer.cpp.

◆ method()

QgsGcpTransformerInterface::TransformMethod QgsHelmertGeorefTransform::method ( ) const
overridevirtual

Returns the transformation method.

Implements QgsGcpTransformerInterface.

Definition at line 223 of file qgsgcptransformer.cpp.

◆ minimumGcpCount()

int QgsHelmertGeorefTransform::minimumGcpCount ( ) const
overridevirtual

Returns the minimum number of Ground Control Points (GCPs) required for parameter fitting.

Implements QgsGcpTransformerInterface.

Definition at line 208 of file qgsgcptransformer.cpp.

◆ updateParametersFromGcps()

bool QgsHelmertGeorefTransform::updateParametersFromGcps ( const QVector< QgsPointXY > &  sourceCoordinates,
const QVector< QgsPointXY > &  destinationCoordinates,
bool  invertYAxis = false 
)
overridevirtual

Fits transformation parameters using the specified Ground Control Points (GCPs) lists of source and destination coordinates.

If invertYAxis is set to true then the y-axis of source coordinates will be inverted, e.g. to allow for transformation of raster layers with ascending top-to-bottom vertical axis coordinates.

Returns
true on success, false on failure

Implements QgsGcpTransformerInterface.

Definition at line 198 of file qgsgcptransformer.cpp.


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