官术网_书友最值得收藏!

  • QGIS 2 Cookbook
  • Alex Mandel Víctor Olaya Ferrero Anita Graser Alexander Bruy
  • 258字
  • 2021-07-16 11:12:37

Saving a raster layer

Raster layers can be exported to a different file. The export process can be used to crop the layer or perform resampling, creating a modified layer. This recipe shows you how to do this.

Getting ready

Open the elev_lid792_1m layer in your QGIS project.

How to do it…

  1. Right-click on the name of the raster layer in the QGIS table of contents and select the Save as... menu. You will see the following window:
    How to do it…
  2. In the Resolution fields, replace both of them with a value of 2. The original resolution (the size of the cell) is 1, as you saw in a previous recipe.
  3. Enter an output file path in the Save as field.
  4. Click on OK. The layer will be saved with a coarser resolution than the original one.

How it works…

The GDAL library is used to save the file. Not all formats supported for input are also supported for output, but the most common ones are supported for both operations.

There's more…

The layer can be exported with a reduced extent. In the QGIS canvas, zoom to a small part of the raster layer. Then open the Save as dialog. In the Extent section, click on the Map view extent button. The bounding coordinates of the current map view will be placed in the four coordinate fields.

Enter a file path to save the file to and click on OK. A layer with a reduced extent covering only the region shown in the map view will be exported.

主站蜘蛛池模板: 怀仁县| 斗六市| 阿克陶县| 河津市| 定西市| 凤山县| 宁陕县| 淳化县| 忻州市| 霸州市| 德格县| 威信县| 永川市| 遂溪县| 六枝特区| 长垣县| 绥芬河市| 鹤岗市| 苏尼特左旗| 临湘市| 岱山县| 晋城| 山西省| 察哈| 绥棱县| 天台县| 岳阳市| 武陟县| 卫辉市| 平度市| 仁化县| 沙田区| 绥滨县| 特克斯县| 元江| 易门县| 潼关县| 颍上县| 绥棱县| 竹北市| 噶尔县|