Skip to content
Permalink
Browse files

[gdaltools] DEM(Terrain Models) tool error (Fix #8116)

  • Loading branch information
m-kuhn committed Jun 19, 2013
1 parent e02459c commit 0b0de71f69f36293aabd824736bd0c468318d414
Showing with 10 additions and 10 deletions.
  1. +9 −9 python/plugins/GdalTools/tools/doDEM.py
  2. +1 −1 python/plugins/GdalTools/tools/doTranslate.py
@@ -133,14 +133,14 @@ def getArguments(self):
outputFn = self.getOutputFileName()
arguments.append( outputFn)
if mode == "hillshade":
arguments.extend( "-z", self.hillshadeZFactorSpin.value())
arguments.extend( "-s" , self.hillshadeScaleSpin.value())
arguments.extend( "-az" , self.hillshadeAzimuthSpin.value())
arguments.extend( "-alt" , self.hillshadeAltitudeSpin.value())
arguments.extend( ["-z", self.hillshadeZFactorSpin.value() ] )
arguments.extend( ["-s" , self.hillshadeScaleSpin.value() ] )
arguments.extend( ["-az" , self.hillshadeAzimuthSpin.value()] )
arguments.extend( ["-alt" , self.hillshadeAltitudeSpin.value() ] )
elif mode == "slope":
if self.slopePercentCheck.isChecked():
arguments.append( "-p")
arguments.extend( "-s" , self.slopeScaleSpin.value())
arguments.extend( [ "-s" , self.slopeScaleSpin.value() ] )
elif mode == "aspect":
if self.aspectTrigonometricCheck.isChecked():
arguments.append( "-trigonometric")
@@ -155,16 +155,16 @@ def getArguments(self):
elif self.colorNearestRadio.isChecked():
arguments.append( "-nearest_color_entry")
if self.algorithmCheck.isChecked():
arguments.extend( "-alg", "ZevenbergenThorne")
arguments.extend( [ "-alg", "ZevenbergenThorne" ] )
if self.computeEdgesCheck.isChecked():
arguments.append( "-compute_edges")
if self.bandCheck.isChecked():
arguments.extend( "-b" , self.bandSpin.value())
arguments.extend( [ "-b" , self.bandSpin.value() ] )
if outputFn:
arguments.extend( "-of", self.outputFormat)
arguments.extend( [ "-of", self.outputFormat ] )
if self.creationOptionsGroupBox.isChecked():
for opt in self.creationOptionsWidget.options():
arguments.extend( "-co", opt)
arguments.extend( [ "-co", opt ] )
# set creation options filename/layer for validation
if self.inSelector.layer():
self.creationOptionsWidget.setRasterLayer(self.inSelector.layer())
@@ -192,7 +192,7 @@ def getArguments(self):
arguments.append( self.targetSRSEdit.text())
if self.creationOptionsGroupBox.isChecked():
for opt in self.creationOptionsWidget.options():
arguments.extend( "-co", opt)
arguments.extend( [ "-co", opt ] )
if self.outsizeCheck.isChecked() and self.outsizeSpin.value() != 100:
arguments.append( "-outsize")
arguments.append( self.outsizeSpin.text())

0 comments on commit 0b0de71

Please sign in to comment.
You can’t perform that action at this time.