Skip to content
Permalink
Browse files

added algorithm option to gdaldem

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@15497 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
brushtyler
brushtyler committed Mar 15, 2011
1 parent d288a75 commit c806aa177cdb752aa137ad35973303e24556230a
Showing with 18 additions and 5 deletions.
  1. +6 −0 python/plugins/GdalTools/tools/doDEM.py
  2. +12 −5 python/plugins/GdalTools/tools/widgetDEM.ui
@@ -35,6 +35,7 @@ def __init__(self, iface):
(self.outputFileEdit, SIGNAL("textChanged(const QString &)")),
(self.computeEdgesCheck, SIGNAL("stateChanged(int)"), None, "1.8.0"),
(self.bandSpin, SIGNAL("valueChanged(int)"), self.bandCheck),
(self.algorithmCheck, SIGNAL("stateChanged(int)"), None, "1.8.0"),
(self.creationOptionsTable, [SIGNAL("cellValueChanged(int, int)"), SIGNAL("rowRemoved()")], self.creationGroupBox),
(self.modeCombo, SIGNAL("currentIndexChanged(int)")),
([self.hillshadeZFactorSpin, self.hillshadeScaleSpin, self.hillshadeAltitudeSpin, self.hillshadeAzimuthSpin], SIGNAL("valueChanged(double)")),
@@ -54,6 +55,9 @@ def __init__(self, iface):

def showModeParams(self, index):
self.stackedWidget.setVisible( index < 4 )
self.algorithmCheck.setVisible( index < 3 )
if index >= 3:
self.algorithmCheck.setChecked( False )

def onLayersChanged(self):
self.fillInputLayerCombo()
@@ -120,6 +124,8 @@ def getArguments(self):
arguments << "-exact_color_entry"
elif self.colorNearestRadio.isChecked():
arguments << "-nearest_color_entry"
if self.algorithmCheck.isChecked():
arguments << "-alg" << "ZevenbergenThorne"
if self.computeEdgesCheck.isChecked():
arguments << "-compute_edges"
if self.bandCheck.isChecked():
@@ -6,8 +6,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>418</width>
<height>408</height>
<width>485</width>
<height>437</height>
</rect>
</property>
<property name="sizePolicy">
@@ -104,14 +104,14 @@
</property>
</widget>
</item>
<item row="3" column="0">
<item row="3" column="0" colspan="2">
<widget class="QCheckBox" name="computeEdgesCheck">
<property name="text">
<string>Compute &amp;edges</string>
</property>
</widget>
</item>
<item row="4" column="0">
<item row="5" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>&amp;Mode</string>
@@ -121,7 +121,7 @@
</property>
</widget>
</item>
<item row="4" column="1">
<item row="5" column="1">
<widget class="QComboBox" name="modeCombo">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
@@ -169,6 +169,13 @@
</item>
</widget>
</item>
<item row="4" column="0" colspan="2">
<widget class="QCheckBox" name="algorithmCheck">
<property name="text">
<string>Use Zevenbergen&amp;&amp;Thorne formula (instead of the Horn's one)</string>
</property>
</widget>
</item>
</layout>
</item>
<item>

0 comments on commit c806aa1

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