ESA Climate Change Initiative landcover to raster mbtiles

by A — last modified 2023-04-04T14:13:57+00:00

For this I had to rebuild my gdal with NETCDF support by installing libnetcdf-dev before compiling gdal, then i ran these commands.

gdalwarp -of Gtiff -co COMPRESS=LZW -co TILED=YES -ot Byte -te -180.0000000 -90.0000000 180.0000000 90.0000000 -tr 0.002777777777778 0.002777777777778 -t_srs EPSG:4326 C3S-LC-L4-LCCS-Map-300m-P1Y-2020-v2.1.1.tif

gdalwarp -co COMPRESS=LZW -ot Byte -t_srs EPSG:3857 C3S-LC-L4-LCCS-Map-300m-P1Y-2020-v2.1.1.tif warp.vrt

gdal_translate warp.vrt landcover.mbtiles

gdaladdo landcover.mbtiles

Document Actions