-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Start bringing back saga algs - split RGB bands
- Loading branch information
1 parent
d00efde
commit 571a5ca
Showing
4 changed files
with
74 additions
and
68 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# -*- coding: utf-8 -*- | ||
|
||
""" | ||
*************************************************************************** | ||
SagaAlgorithmBase.py | ||
--------------------- | ||
Date : August 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. * | ||
* * | ||
*************************************************************************** | ||
""" | ||
|
||
__author__ = 'Nyall Dawson' | ||
__date__ = 'August 2017' | ||
__copyright__ = '(C) 2017, Nyall Dawson' | ||
|
||
# This will get replaced with a git SHA1 when you do a git archive | ||
|
||
__revision__ = '$Format:%H$' | ||
|
||
import os | ||
|
||
from qgis.PyQt.QtCore import QCoreApplication | ||
from qgis.PyQt.QtGui import QIcon | ||
from qgis.core import QgsProcessingAlgorithm | ||
|
||
|
||
pluginPath = os.path.normpath(os.path.join( | ||
os.path.split(os.path.dirname(__file__))[0], os.pardir)) | ||
|
||
|
||
class SagaAlgorithmBase(QgsProcessingAlgorithm): | ||
|
||
def __init__(self): | ||
super().__init__() | ||
self.output_values = {} | ||
|
||
def icon(self): | ||
return QIcon(os.path.join(pluginPath, 'images', 'saga.png')) | ||
|
||
def createInstance(self, config={}): | ||
return self.__class__() | ||
|
||
def tr(self, string, context=''): | ||
if context == '': | ||
context = self.__class__.__name__ | ||
return QCoreApplication.translate(context, string) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters