I am trying to clip a raster layer by a shape define by a polygon.
(A previous question was about a line layer clipping, whereas this one relates to raster layer)
The resulting layer is however an empty layer. To be more specific the resulting layer is raster of 1846×1202 pixels, but it seems to be filled with no-data value.
I am clipping the raster via menu Raster -> Extract -> Clip
Here are some views of the work:
-
Polygon Shape (Mask):
-
Raster Layer to clip
-
Resulting layer (after clipping): Nothing !
-
Layers' icons in QGIS Layer Windows
If I do a clipping using a Extent
(rectangular selection) instead of Mask Layer
(clipping with shape), it works: so I suspect I have a problem with my polygon layer.
Best Answer
You can't clip a raster file working with ESPG 3857 (WGS 84 / Pseudo-Mercator).
Here is how you can to it:
Richg click on your rasterfile
Save as...
chose a UTM CRS (look up the right zone before) eg. EPSG 32632) and save the raster filedo the same for you shapefile you want to use for clipping.
Use the raster clipper with your new files
Raster -> Extract -> Clip