Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Various fixes to Processing algs; fix for http://hub.qgis.org/issues/…
  • Loading branch information
pcav committed Apr 10, 2015
1 parent 3a55abd commit a911e6e
Show file tree
Hide file tree
Showing 12 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/gdal/ogr2ogrbuffer.py
Expand Up @@ -69,7 +69,7 @@ def defineCharacteristics(self):
self.tr('Additional creation options (see ogr2ogr manual)'),
'', optional=True))

self.addOutput(OutputVector(self.OUTPUT_LAYER, self.tr('Output layer')))
self.addOutput(OutputVector(self.OUTPUT_LAYER, self.tr('Buffer')))

def processAlgorithm(self, progress):
inLayer = self.getParameterValue(self.INPUT_LAYER)
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/gdal/ogr2ogrdissolve.py
Expand Up @@ -78,7 +78,7 @@ def defineCharacteristics(self):
self.tr('Additional creation options (see ogr2ogr manual)'),
'', optional=True))

self.addOutput(OutputVector(self.OUTPUT_LAYER, self.tr('Output layer')))
self.addOutput(OutputVector(self.OUTPUT_LAYER, self.tr('Dissolved')))

def processAlgorithm(self, progress):
inLayer = self.getParameterValue(self.INPUT_LAYER)
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/gdal/rasterize.py
Expand Up @@ -86,7 +86,7 @@ def defineCharacteristics(self):
self.tr("Nodata value"),
'-9999'))
self.addParameter(ParameterSelection(self.COMPRESS,
self.tr('GeoTIFF options. Compression type:'), self.COMPRESSTYPE, 0))
self.tr('GeoTIFF options. Compression type:'), self.COMPRESSTYPE, 5))
self.addParameter(ParameterNumber(self.JPEGCOMPRESSION,
self.tr('Set the JPEG compression level'),
1, 100, 75))
Expand Down
4 changes: 2 additions & 2 deletions python/plugins/processing/algs/gdal/translate.py
Expand Up @@ -90,7 +90,7 @@ def defineCharacteristics(self):
self.addParameter(ParameterSelection(self.RTYPE,
self.tr('Output raster type'), self.TYPE, 5))
self.addParameter(ParameterSelection(self.COMPRESS,
self.tr('GeoTIFF options. Compression type:'), self.COMPRESSTYPE, 0))
self.tr('GeoTIFF options. Compression type:'), self.COMPRESSTYPE, 5))
self.addParameter(ParameterNumber(self.JPEGCOMPRESSION,
self.tr('Set the JPEG compression level'),
1, 100, 75))
Expand All @@ -108,7 +108,7 @@ def defineCharacteristics(self):
self.tr('Force the generation of an associated ESRI world file (.tfw))'), False))
self.addParameter(ParameterString(self.EXTRA,
self.tr('Additional creation parameters'), '', optional=True))
self.addOutput(OutputRaster(self.OUTPUT, self.tr('Output layer')))
self.addOutput(OutputRaster(self.OUTPUT, self.tr('Translated')))

def processAlgorithm(self, progress):
out = self.getOutputValue(translate.OUTPUT)
Expand Down
4 changes: 2 additions & 2 deletions python/plugins/processing/algs/gdal/warp.py
Expand Up @@ -78,7 +78,7 @@ def defineCharacteristics(self):
self.addParameter(ParameterSelection(self.RTYPE,
self.tr('Output raster type'), self.TYPE, 5))
self.addParameter(ParameterSelection(self.COMPRESS,
self.tr('GeoTIFF options. Compression type:'), self.COMPRESSTYPE, 0))
self.tr('GeoTIFF options. Compression type:'), self.COMPRESSTYPE, 5))
self.addParameter(ParameterNumber(self.JPEGCOMPRESSION,
self.tr('Set the JPEG compression level'),
1, 100, 75))
Expand All @@ -96,7 +96,7 @@ def defineCharacteristics(self):
self.tr('Force the generation of an associated ESRI world file (.tfw))'), False))
self.addParameter(ParameterString(self.EXTRA,
self.tr('Additional creation parameters'), '', optional=True))
self.addOutput(OutputRaster(self.OUTPUT, self.tr('Output layer')))
self.addOutput(OutputRaster(self.OUTPUT, self.tr('Warped')))

def processAlgorithm(self, progress):
noData = str(self.getParameterValue(self.NO_DATA))
Expand Down
Expand Up @@ -7,5 +7,5 @@ ParameterNumber|scale|Scaling factor for attribute column values|None|None|1.0
ParameterString|tolerance|Maximum distance between theoretical arc and polygon segments as multiple of buffer|0.01
ParameterBoolean|-s|Make outside corners straight|False
ParameterBoolean|-c|Don't make caps at the ends of polylines|False
OutputVector|output|Output buffer
OutputVector|output|Buffer

Expand Up @@ -6,5 +6,5 @@ ParameterString|distance|Buffer distance in map units|
ParameterString|tolerance|Maximum distance between theoretical arc and polygon segments as multiple of buffer|0.01
ParameterBoolean|-s|Make outside corners straight|False
ParameterBoolean|-c|Don't make caps at the ends of polylines|False
OutputVector|output|Output buffer
OutputVector|output|Buffer

Expand Up @@ -7,4 +7,4 @@ ParameterNumber|scale|Scaling factor for attribute column values|None|None|1.0
ParameterString|tolerance|Maximum distance between theoretical arc and polygon segments as multiple of buffer|0.01
ParameterBoolean|-s|Make outside corners straight|False
ParameterBoolean|-c|Do not make caps at the ends of polylines|False
OutputVector|output|Output buffer
OutputVector|output|Buffer
Expand Up @@ -6,4 +6,4 @@ ParameterString|distance|Buffer distance in map units|
ParameterString|tolerance|Maximum distance between theoretical arc and polygon segments as multiple of buffer|0.01
ParameterBoolean|-s|Make outside corners straight|False
ParameterBoolean|-c|Do not make caps at the ends of polylines|False
OutputVector|output|Output buffer
OutputVector|output|Buffer
Expand Up @@ -2,4 +2,4 @@ Clip Grid with Polygon
shapes_grid
ParameterRaster|INPUT|Input|False
ParameterVector|POLYGONS|Polygons|2|False
OutputRaster|OUTPUT|Output
OutputRaster|OUTPUT|Clipped
Expand Up @@ -11,5 +11,5 @@ ParameterSelection|TARGET_DEFINITION|Target Grid System|[0] user defined;[1] gri
Extent TARGET_USER_XMIN TARGET_USER_XMAX TARGET_USER_YMIN TARGET_USER_YMAX
ParameterNumber|TARGET_USER_SIZE|Cellsize|None|None|100.0
ParameterSelection|TARGET_USER_FITS|Fit|[0] nodes;[1] cells
OutputRaster|TARGET_OUT_GRID|Target Grid
OutputRaster|TARGET_OUT_GRID|Rasterized
OutputRaster|TARGET_COUNT|Number of Values
Expand Up @@ -4,4 +4,4 @@ ParameterRaster|GRID|Grid|False
ParameterSelection|CLASS_ALL|Class Selection|[0] one single class specified by class identifier;[1] all classes|1
ParameterNumber|CLASS_ID|Class Identifier|None|None|0
ParameterSelection|SPLIT|Vectorised class as...|[0] one single (multi-)polygon object;[1] each island as separated polygon|1
OutputVector|POLYGONS|Polygons
OutputVector|POLYGONS|Vectorized

4 comments on commit a911e6e

@gioman
Copy link
Contributor

@gioman gioman commented on a911e6e Apr 10, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes in the saga/grass modules are not about output layer names. The text is what it shows in the modules gui.

@pcav
Copy link
Member Author

@pcav pcav commented on a911e6e Apr 10, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you sure? Just tested python/plugins/processing/algs/saga/description/2.1.3/VectorisingGridClasses.txt

@gioman
Copy link
Contributor

@gioman gioman commented on a911e6e Apr 10, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes. It is also the name given to temp output, but only if in the processing options the option "use filename as layer name" is unchecked.

@pcav
Copy link
Member Author

@pcav pcav commented on a911e6e Apr 10, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Which is what I was aiming for. Rationale: having many layers with generic names makes selecting individual layers for further analyses difficult and confusing.

Please sign in to comment.