Skip to content

Commit

Permalink
[processing] reproject extent into input CRS where possible
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbruy committed Oct 11, 2017
1 parent 2c50fd8 commit 67265c6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/gdal/ClipRasterByExtent.py
Expand Up @@ -107,7 +107,7 @@ def commandName(self):

def getConsoleCommands(self, parameters, context, feedback):
inLayer = self.parameterAsRasterLayer(parameters, self.INPUT, context)
bbox = self.parameterAsExtent(parameters, self.EXTENT, context)
bbox = self.parameterAsExtent(parameters, self.EXTENT, context, inLayer.crs())
nodata = self.parameterAsDouble(parameters, self.NODATA, context)
options = self.parameterAsString(parameters, self.OPTIONS, context)
out = self.parameterAsOutputLayer(parameters, self.OUTPUT, context)
Expand Down
3 changes: 2 additions & 1 deletion python/plugins/processing/algs/gdal/ClipVectorByExtent.py
Expand Up @@ -75,7 +75,8 @@ def commandName(self):

def getConsoleCommands(self, parameters, context, feedback):
ogrLayer, layerName = self.getOgrCompatibleSource(self.INPUT, parameters, context, feedback)
extent = self.parameterAsExtent(parameters, self.EXTENT, context)
inLayer = self.parameterAsVectorLayer(parameters, self.INPUT, context)
extent = self.parameterAsExtent(parameters, self.EXTENT, context, inLayer.crs())
options = self.parameterAsString(parameters, self.OPTIONS, context)
outFile = self.parameterAsOutputLayer(parameters, self.OUTPUT, context)

Expand Down

0 comments on commit 67265c6

Please sign in to comment.