[QGIS Commit] r15497 - trunk/qgis/python/plugins/GdalTools/tools
svn_qgis at osgeo.org
svn_qgis at osgeo.org
Tue Mar 15 10:21:29 EDT 2011
Author: brushtyler
Date: 2011-03-15 07:21:29 -0700 (Tue, 15 Mar 2011)
New Revision: 15497
Modified:
trunk/qgis/python/plugins/GdalTools/tools/doDEM.py
trunk/qgis/python/plugins/GdalTools/tools/widgetDEM.ui
Log:
added algorithm option to gdaldem
Modified: trunk/qgis/python/plugins/GdalTools/tools/doDEM.py
===================================================================
--- trunk/qgis/python/plugins/GdalTools/tools/doDEM.py 2011-03-15 13:35:26 UTC (rev 15496)
+++ trunk/qgis/python/plugins/GdalTools/tools/doDEM.py 2011-03-15 14:21:29 UTC (rev 15497)
@@ -35,6 +35,7 @@
(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 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 @@
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():
Modified: trunk/qgis/python/plugins/GdalTools/tools/widgetDEM.ui
===================================================================
--- trunk/qgis/python/plugins/GdalTools/tools/widgetDEM.ui 2011-03-15 13:35:26 UTC (rev 15496)
+++ trunk/qgis/python/plugins/GdalTools/tools/widgetDEM.ui 2011-03-15 14:21:29 UTC (rev 15497)
@@ -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 &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>&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&&Thorne formula (instead of the Horn's one)</string>
+ </property>
+ </widget>
+ </item>
</layout>
</item>
<item>
More information about the QGIS-commit
mailing list