I am using QGIS 3.10.2 and I am trying to clip a raster layer of the World just to capture Africa. The raster layer was imported from ESRI (https://planet.qgis.org/planet/tag/world%20imagery/) with the following code in the Python console:
qgis.utils.iface.addRasterLayer("http://server.arcgisonline.com/arcgis/rest/services/ESRI_Imagery_World_2D/MapServer?f=json&pretty=true","raster")
Now I click on Raster>Extraction>Cut by Extent, I select my Entry layer. I chose to select on Canvas the extent, draw a polygon and obtain the coordinates. Last, I select the output file. Here is what it looks like (sorry in Spanish)
I click execute and I get the following error:
Versión de QGIS: 3.10.2-A Coruña
Revisión del código de QGIS: d4cd3cfe5a
Versión de Qt: 5.11.2
Versión de GDAL: 3.0.3
Versión de GEOS: 3.8.0-CAPI-1.13.1
Versión de PROJ: Rel. 6.3.0, January 1st, 2020
Procesando algoritmo...
Algoritmo 'Cortar ráster por extensión' comenzando…
Input parameters:
{ 'DATA_TYPE' : 0, 'EXTRA' : '', 'INPUT' : 'http://server.arcgisonline.com/arcgis/rest/services/ESRI_Imagery_World_2D/MapServer?f=json&pretty=true', 'NODATA' : None, 'OPTIONS' : '', 'OUTPUT' : 'C:/Users/Javier.DESKTOP-EEJENVF/Documents/fires/cut1.tif', 'PROJWIN' : '-21.94386249283079,56.234657100783124,-39.64277198356078,36.88988403966126 [EPSG:4326]' }
GDAL command:
gdal_translate -projwin -21.94386249283079 36.88988403966126 56.234657100783124 -39.64277198356078 -of GTiff http://server.arcgisonline.com/arcgis/rest/services/ESRI_Imagery_World_2D/MapServer?f=json&pretty=true C:/Users/Javier.DESKTOP-EEJENVF/Documents/fires/cut1.tif
GDAL command output:
FAILURE: No target dataset specified.
Usage: gdal_translate [--help-general] [--long-usage]
[-ot {Byte/Int16/UInt16/UInt32/Int32/Float32/Float64/
CInt16/CInt32/CFloat32/CFloat64}] [-strict]
[-of format] [-b band] [-mask band] [-expand {gray|rgb|rgba}]
[-outsize xsize[%]|0 ysize[%]|0] [-tr xres yres]
[-r {nearest,bilinear,cubic,cubicspline,lanczos,average,mode}]
[-unscale] [-scale[_bn] [src_min src_max [dst_min dst_max]]]* [-exponent[_bn] exp_val]*
[-srcwin xoff yoff xsize ysize] [-epo] [-eco]
[-projwin ulx uly lrx lry] [-projwin_srs srs_def]
[-a_srs srs_def] [-a_ullr ulx uly lrx lry] [-a_nodata value]
[-a_scale value] [-a_offset value]
[-nogcp] [-gcp pixel line easting northing [elevation]]*
|-colorinterp{_bn} {red|green|blue|alpha|gray|undefined}]
|-colorinterp {red|green|blue|alpha|gray|undefined},...]
[-mo "META-TAG=VALUE"]* [-q] [-sds]
[-co "NAME=VALUE"]* [-stats] [-norat]
[-oo NAME=VALUE]*
src_dataset dst_dataset
"pretty" no se reconoce como un comando interno o externo,
programa o archivo por lotes ejecutable.
Execution completed in 0.30 seconds
Results:
{'OUTPUT': 'C:/Users/Alum.DESKTOP-EEJENVF/Documents/fires/cut1.tif'}
Apparently the problem is that I did not specify a target dataset.
Can anyone help me?