mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-28 00:05:04 -04:00
Adds a new QGIS processing provider for 3d algorithms, available only when QGIS is built WITH_3D Currently includes only a single algorithm for tesselating geometries, which exposes the functionality of QgsTesselator to processing. Like the native c++ algorithm provider, algorithms in the 3d provider are transparently merged with the other QGIS providers (i.e. they aren't separated into their own group)
63 lines
1.8 KiB
C++
63 lines
1.8 KiB
C++
/***************************************************************************
|
|
qgs3dalgorithms.cpp
|
|
---------------------
|
|
begin : November 2017
|
|
copyright : (C) 2017 by Nyall Dawson
|
|
email : nyall dot dawson at gmail dot com
|
|
***************************************************************************/
|
|
|
|
/***************************************************************************
|
|
* *
|
|
* This program is free software; you can redistribute it and/or modify *
|
|
* it under the terms of the GNU General Public License as published by *
|
|
* the Free Software Foundation; either version 2 of the License, or *
|
|
* (at your option) any later version. *
|
|
* *
|
|
***************************************************************************/
|
|
|
|
#include "qgs3dalgorithms.h"
|
|
#include "qgsalgorithmtesselate.h"
|
|
#include "qgsapplication.h"
|
|
|
|
///@cond PRIVATE
|
|
|
|
Qgs3DAlgorithms::Qgs3DAlgorithms( QObject *parent )
|
|
: QgsProcessingProvider( parent )
|
|
{}
|
|
|
|
QIcon Qgs3DAlgorithms::icon() const
|
|
{
|
|
return QgsApplication::getThemeIcon( QStringLiteral( "/providerQgis.svg" ) );
|
|
}
|
|
|
|
QString Qgs3DAlgorithms::svgIconPath() const
|
|
{
|
|
return QgsApplication::iconPath( QStringLiteral( "providerQgis.svg" ) );
|
|
}
|
|
|
|
QString Qgs3DAlgorithms::id() const
|
|
{
|
|
return QStringLiteral( "3d" );
|
|
}
|
|
|
|
QString Qgs3DAlgorithms::name() const
|
|
{
|
|
return tr( "QGIS (3D)" );
|
|
}
|
|
|
|
bool Qgs3DAlgorithms::supportsNonFileBasedOutput() const
|
|
{
|
|
return true;
|
|
}
|
|
|
|
void Qgs3DAlgorithms::loadAlgorithms()
|
|
{
|
|
addAlgorithm( new QgsTesselateAlgorithm() );
|
|
}
|
|
|
|
|
|
///@endcond
|
|
|
|
|
|
|