Skip to content
Permalink
Browse files

[sextante] force export to shp in grass algorithms, since v.in.ogr sy…

…ntax seems to be not always the same and some formats (i.e. GML) are not working
  • Loading branch information
volaya committed Apr 13, 2013
1 parent ac43402 commit 58c0036340b0af20ccf47ab09af465fbc3faa1a1
Showing with 3 additions and 3 deletions.
  1. +3 −3 python/plugins/sextante/grass/GrassAlgorithm.py
@@ -357,10 +357,10 @@ def postProcessResults(self):
func(self)

def exportVectorLayer(self, orgFilename):
#only export to an intermediate shp if the layer is not file-based.
#We assume that almost all file formats will be supported by ogr
#TODO: improve this. We are now exporting if it is not a shapefile,
#but the functionality of v.in.ogr could be used for this.
#We also export if there is a selection
if not os.path.exists(orgFilename):
if not os.path.exists(orgFilename) or not orgFilename.endswith("shp"):
layer = QGisLayers.getObjectFromUri(orgFilename, False)
if layer:
filename = LayerExporter.exportVectorLayer(layer)

0 comments on commit 58c0036

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