16
16
***************************************************************************/
17
17
18
18
19
- #include " qgsalgorithmdensifygeometries .h"
19
+ #include " qgsalgorithmdensifygeometriesbyinterval .h"
20
20
21
- QString QgsDensifyGeometriesAlgorithm ::name () const
21
+ QString QgsDensifyGeometriesByIntervalAlgorithm ::name () const
22
22
{
23
23
return QStringLiteral ( " densifygeometriesgivenaninterval" );
24
24
}
25
25
26
- QString QgsDensifyGeometriesAlgorithm ::displayName () const
26
+ QString QgsDensifyGeometriesByIntervalAlgorithm ::displayName () const
27
27
{
28
28
return QObject::tr ( " Densify by interval" );
29
29
}
30
30
31
- QStringList QgsDensifyGeometriesAlgorithm ::tags () const
31
+ QStringList QgsDensifyGeometriesByIntervalAlgorithm ::tags () const
32
32
{
33
33
return QObject::tr ( " add,vertex,vertices,points,nodes" ).split ( ' ,' );
34
34
}
35
35
36
- QString QgsDensifyGeometriesAlgorithm ::group () const
36
+ QString QgsDensifyGeometriesByIntervalAlgorithm ::group () const
37
37
{
38
38
return QObject::tr ( " Vector geometry" );
39
39
}
40
40
41
- QString QgsDensifyGeometriesAlgorithm ::groupId () const
41
+ QString QgsDensifyGeometriesByIntervalAlgorithm ::groupId () const
42
42
{
43
43
return QStringLiteral ( " vectorgeometry" );
44
44
}
45
45
46
- QString QgsDensifyGeometriesAlgorithm ::shortHelpString () const
46
+ QString QgsDensifyGeometriesByIntervalAlgorithm ::shortHelpString () const
47
47
{
48
48
return QObject::tr ( " Geometries are densified by adding additional vertices on "
49
49
" edges that have a maximum distance of the interval parameter "
50
50
" in map units." );
51
51
}
52
52
53
- QString QgsDensifyGeometriesAlgorithm ::shortDescription () const
53
+ QString QgsDensifyGeometriesByIntervalAlgorithm ::shortDescription () const
54
54
{
55
55
return QObject::tr ( " Creates a densified version of geometries." );
56
56
}
57
57
58
- QgsDensifyGeometriesAlgorithm * QgsDensifyGeometriesAlgorithm ::createInstance () const
58
+ QgsDensifyGeometriesByIntervalAlgorithm * QgsDensifyGeometriesByIntervalAlgorithm ::createInstance () const
59
59
{
60
- return new QgsDensifyGeometriesAlgorithm ;
60
+ return new QgsDensifyGeometriesByIntervalAlgorithm ;
61
61
62
62
}
63
63
64
- QList<int > QgsDensifyGeometriesAlgorithm ::inputLayerTypes () const
64
+ QList<int > QgsDensifyGeometriesByIntervalAlgorithm ::inputLayerTypes () const
65
65
{
66
66
return QList<int >() << QgsProcessing::TypeVectorLine << QgsProcessing::TypeVectorPolygon;
67
67
}
68
68
69
- void QgsDensifyGeometriesAlgorithm ::initParameters ( const QVariantMap &configuration )
69
+ void QgsDensifyGeometriesByIntervalAlgorithm ::initParameters ( const QVariantMap &configuration )
70
70
{
71
71
Q_UNUSED ( configuration )
72
72
addParameter ( new QgsProcessingParameterDistance ( QStringLiteral ( " INTERVAL" ),
73
73
QObject::tr ( " Interval between vertices to add" ),
74
74
1 , QStringLiteral ( " INPUT" ), false , 0 , 10000000 ) );
75
75
}
76
76
77
- QString QgsDensifyGeometriesAlgorithm ::outputName () const
77
+ QString QgsDensifyGeometriesByIntervalAlgorithm ::outputName () const
78
78
{
79
79
return QObject::tr ( " Densified" );
80
80
}
81
81
82
- QgsFeatureList QgsDensifyGeometriesAlgorithm ::processFeature ( const QgsFeature &feature, QgsProcessingContext &context, QgsProcessingFeedback *feedback )
82
+ QgsFeatureList QgsDensifyGeometriesByIntervalAlgorithm ::processFeature ( const QgsFeature &feature, QgsProcessingContext &context, QgsProcessingFeedback *feedback )
83
83
{
84
84
Q_UNUSED ( context );
85
85
Q_UNUSED ( feedback );
@@ -90,7 +90,7 @@ QgsFeatureList QgsDensifyGeometriesAlgorithm::processFeature( const QgsFeature &
90
90
return QgsFeatureList () << modifiedFeature;
91
91
}
92
92
93
- bool QgsDensifyGeometriesAlgorithm ::prepareAlgorithm ( const QVariantMap ¶meters, QgsProcessingContext &context, QgsProcessingFeedback *feedback )
93
+ bool QgsDensifyGeometriesByIntervalAlgorithm ::prepareAlgorithm ( const QVariantMap ¶meters, QgsProcessingContext &context, QgsProcessingFeedback *feedback )
94
94
{
95
95
Q_UNUSED ( feedback );
96
96
mInterval = parameterAsDouble ( parameters, QStringLiteral ( " INTERVAL" ), context );
0 commit comments