QGIS API Documentation 3.36.0-Maidenhead (09951dc0acf)
Loading...
Searching...
No Matches
qgsgcpgeometrytransformer.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsgcpgeometrytransformer.h
3 ----------------------
4 begin : February 2021
5 copyright : (C) 2021 by Nyall Dawson
6 email : nyall dot dawson at gmail dot com
7 ***************************************************************************/
8
9/***************************************************************************
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 ***************************************************************************/
17
18#ifndef QGSGCPGEOMETRYTRANSFORMER_H
19#define QGSGCPGEOMETRYTRANSFORMER_H
20
21#include "qgis_analysis.h"
23#include "qgsgcptransformer.h"
24#include "qgsfeedback.h"
25#include <memory>
26
27class QgsGeometry;
28
37{
38 public:
39
47
52 QgsGcpGeometryTransformer( QgsGcpTransformerInterface::TransformMethod method, const QVector<QgsPointXY> &sourceCoordinates, const QVector<QgsPointXY> &destinationCoordinates );
53
55
58
61
62 bool transformPoint( double &x SIP_INOUT, double &y SIP_INOUT, double &z SIP_INOUT, double &m SIP_INOUT ) override;
63
74 QgsGeometry transform( const QgsGeometry &geometry, bool &ok SIP_OUT, QgsFeedback *feedback = nullptr );
75
81 QgsGcpTransformerInterface *gcpTransformer() const;
82
90 void setGcpTransformer( QgsGcpTransformerInterface *transformer SIP_TRANSFER );
91
92 private:
93#ifdef SIP_RUN
95#endif
96
97 std::unique_ptr< QgsGcpTransformerInterface > mGcpTransformer;
98
99};
100
101#endif // QGSGCPGEOMETRYTRANSFORMER_H
An abstract base class for classes which transform geometries by transforming input points to output ...
virtual bool transformPoint(double &x, double &y, double &z, double &m)=0
Transforms the point defined by the coordinates (x, y, z) and the specified m value.
Base class for feedback objects to be used for cancellation of something running in a worker thread.
Definition qgsfeedback.h:44
A geometry transformer which uses an underlying Ground Control Points (GCP) based transformation to m...
~QgsGcpGeometryTransformer() override
QgsGcpGeometryTransformer & operator=(const QgsGcpGeometryTransformer &other)=delete
QgsGcpGeometryTransformer cannot be copied.
QgsGcpGeometryTransformer(const QgsGcpGeometryTransformer &other)=delete
QgsGcpGeometryTransformer cannot be copied.
An interface for Ground Control Points (GCP) based transformations.
TransformMethod
Available transformation methods.
A geometry is the spatial representation of a feature.
#define SIP_TRANSFER
Definition qgis_sip.h:36
#define SIP_OUT
Definition qgis_sip.h:58
#define SIP_INOUT
Definition qgis_sip.h:71