GDAL_TRANSLATE(1) GDAL GDAL_TRANSLATE(1) (NAME) gdal_translate - (SYNOPSIS) Usage: gdal_translate [--help] [--long-usage] [--help-general] [-ot Byte|Int8|[U]Int{16|32|64}|CInt{16|32}|[C]Float{32|64}] [-if ]... [-of ] [--quiet] [-b ]... [-mask ] [-expand gray|rgb|rgba] [[-strict]|[-not_strict]] [-outsize ] [-tr ] [-ovr |AUTO|AUTO-|NONE] [-sds] [-r nearest,bilinear,cubic,cubicspline,lanczos,average,mode] [[-scale [ [ ]]]...| [-scale_X [ [ ]]]...| [-unscale]] [[-exponent ]|[-exponent_X ]...] [-srcwin ] [-projwin ] [-projwin_srs ] [-epo] [-eco] [-a_srs ] [-a_coord_epoch ] [-a_ullr ] [-a_nodata |none] [-a_gt ] [-a_scale ] [-a_offset ] [-nogcp] [-gcp []]... [-colorinterp {red|green|blue|alpha|gray|undefined|pan|coastal|rededge|nir|swir|mwir|lwir|...},...] [-colorinterp_X {red|green|blue|alpha|gray|undefined|pan|coastal|rededge|nir|swir|mwir|lwir|...}]... [[-stats]|[-approx_stats]] [-norat] [-noxmp] [-co =]... [-mo =]... [-dmo :=]... [-oo =]... (DESCRIPTION) gdal_translate (subsetting) (resampling) . : "gdal": o gdal raster convert . o gdal raster clip . o gdal raster nodata-to-alpha nodata. o gdal raster resize . o gdal raster scale . o gdal raster set-type . --help . --help-general GDAL . -q, --quiet . -ot : Byte Int8 UInt16 Int16 UInt32 Int32 UInt64 Int64 Float32 Float64 CInt16 CInt32 CFloat32 CFloat64. -strict . GDAL ( ) . . . . -if / () . . . . . 3.2. -of . . . -b band . . -b . band "mask,1" ( "mask") . -mask band . . band "none" . ("auto") ("-b mask"). band "mask,1" ( "mask") . -expand gray|rgb|rgba (RGB) (RGBA). JPEG JPEG2000 MrSID ECW . 'gray' . -outsize [%]|0 [%]|0 . '%' . 0 . -tr . (georeferenced) . . -outsize -a_ullr -a_gt () . -ovr {|AUTO|AUTO-|NONE} 3.6 . (overview) . AUTO . ( 0= ) . AUTO-n n 1 AUTO . NONE ( -r .) -ovr -outsize -tr . -ovr -srcwin . -outsize . -r {nearest|bilinear|cubic|cubicspline|lanczos|average|rms|mode} (resampling). nearest () ( ) . average NODATA . GDAL 3.1 . rms / NODATA (GDAL >= 3.3). bilinear (bilinear) . cubic (cubic) . cubicspline B-Spline . lanczos (Lanczos windowed sinc) . mode . -scale [ [ ]] src_min src_max dst_min dst_max. ( 0 255 Byte) 0 1 . ( -srcwin -projwin ). gdal_translate gdalinfo -stats {source_dataset} (GeoTIFF VRT...) . -scale . src_min src_max (clip) -exponent . src_min src_max dst_min dst_max . -exponent 1 . -scale ( ) . -scale_bn bn ( -scale_2 ) . -exponent . exp_val ( ). -scale . -exponent . . -exponent_bn bn ( -exponent_2 ) . Dst Src : {Dst} = \left( {Dst}_{max} - {Dst}_{min} \right) \times \operatorname{max} \left( 0, \operatorname{min} \left( 1, \left( \frac{{Src} - {Src}_{min}}{{Src}_{max}-{Src}_{min}} \right)^{exp\_val} \right) \right) + {Dst}_{min} -unscale / (scale/offset) . -ot . : {unscaled\_value} = {scaled\_value} * {scale} + {offset} -srcwin / . / (xoff yoff) . NoData -a_nodata . -epo -eco gdal_translate . -projwin ( -srcwin) ( SRS . -projwin_srs ). NoData -a_nodata . -epo -eco gdal_translate . : GDAL 3.11 -projwin SRS . GDAL 3.11 SRS SRS . SRS GDAL 3.11 . : -projwin ( GDAL < 3.11 ) . . -projwin_srs (SRS) -projwin . GDAL/OGR WKT PROJ.4 EPSG:n WKT . : SRS . -epo ( / Error when Partially Outside) -srcwin -projwin . . -eco (Error when Completely Outside) -epo . -a_srs . -a_ullr -a_gt . OGRSpatialReference::SetFromUserInput() CRS EPSG ( EPSG:4296) CRS (WKT) PROJ.4 .prj WKT CRS. : . -a_coord_epoch 3.4 . (coordinate epoch) SRS . SRS CRS . -a_scale . . -unscale -a_scale . -scale 0 1 (offset, scale) : gdal_translate input.tif tmp.vrt -a_scale scale -a_offset offset gdal_translate tmp.vrt output.tif -unscale -a_offset . . -unscale -a_offset . -scale 0 1 (offset, scale) : gdal_translate input.tif tmp.vrt -a_scale scale -a_offset offset gdal_translate tmp.vrt output.tif -unscale -a_ullr / . . SRS . -a_gt . -a_gt / (geotransform) . . SRS . Geotransform Tutorial . -a_ullr . 3.8 . -a_nodata nodata . nodata none nodata . nodata nodata . -colorinterp_X X ( X ). -colorinterp {red|green|blue|alpha|gray|undefined|pan|coastal|rededge|nir|swir|mwir|lwir|...},... . -colorinterp red,green,blue,alpha . -mo = (metadata) . -dmo DOMAIN:META-TAG=VALUE (domain) . 3.9 . -co = . GeoTIFF (tiled) . . --format . Raster drivers . gdal_translate ( GDALTranslate() GDALCreateCopy()) : o APPEND_SUBDATASET=[YES/NO]: NO . YES ( GTIFF NITF). o COPY_SRC_MDD=[AUTO/YES/NO]: (GDAL >= 3.8) AUTO . . AUTO "" (safe) ( IMD RPC GEOLOCATION ). YES ( IMAGE_STRUCTURE DERIVED_SUBDATASETS). GTiff COG VRT PNG JPEG . NO . o SRC_MDD=: (GDAL >= 3.8) . ( COPY_SRC_MDD=YES ). . "" ( "_DEFAULT_" ). GTiff COG VRT PNG JPEG . -nogcp GCP . -gcp [] . GCP . -q . -sds . HDF (subdataset) . -stats ( ) . -norat RAT . -noxmp XMP . 3.2 . -oo = ( ). . URL . . NODATA / (NODATA / SOURCE VALIDITY MASK HANDLING DURING RESAMPLING) nodata ( -outsize -tr) . : o nearest ( ) . . o bilinear cubic cubicspline lanczos . cubic lanczos : overshoot/undershoot . nodata . o . . nodata . (RETURN STATUS CODE) 0 ( ). C (C API) C GDALTranslate() . (EXAMPLES) : GeoTIFF (Tiled) gdal_translate -of GTiff -co "TILED=YES" utm.tif utm_tiled.tif : TIFF JPEG RGBA gdal_translate rgba.tif withmask.tif -b 1 -b 2 -b 3 -mask 4 -co COMPRESS=JPEG \ -co PHOTOMETRIC=YCBCR --config GDAL_TIFF_INTERNAL_MASK YES gdal_translate withmask.tif rgba.tif -b 1 -b 2 -b 3 -b mask : -projwin -outsize gdal_translate -projwin -20037500 10037500 0 0 -outsize 100 100 frmt_wms_googlemaps_tms.xml junk.png : $ gdal_create test.tif -bands 3 -ot Int16 -outsize 1 1 $ gdal_translate -strict test.tif test.webp ERROR 6: WEBP driver doesn't support data type Int16. Only UInt8 bands supported. (AUTHORS) Frank Warmerdam , Silke Reimer (COPYRIGHT) 1998-2026 August 18, 2026 GDAL_TRANSLATE(1)