[gdal-dev] RGB Geotiff with jpeg compress

APM apschwimmer at apmland.de
Wed Sep 23 06:02:42 PDT 2020


Dear all,


I like to compress a Geotiff rastermap with compress=jpeg.


gdalinfo for a .vrt which I like to compress:

Coordinate System is:
PROJCRS["ETRS89 / UTM zone 32N",
     BASEGEOGCRS["ETRS89",
         DATUM["European Terrestrial Reference System 1989",
             ELLIPSOID["GRS 1980",6378137,298.257222101,
                 LENGTHUNIT["metre",1]]],

.

.


Band 1 Block=128x128 Type=Byte, ColorInterp=Palette
   Color Table (RGB with 256 entries)
     0: 255,255,255,255
     1: 255,255,255,255
     2: 255,255,255,255
     3: 191,230,230,255
     4: 153,255,179,255
     5: 230,255,204,255
     6: 191,242,128,255

.

.

gdal_translate dtk25.vrt -co COMPRESS=JPEG out.tiff

Input file size is 201600, 198400

0ERROR 1: JPEGSetupEncode:PhotometricInterpretation 3 not allowed for JPEG
ERROR 1: An error occurred while writing a dirty block from 
GDALRasterBand::IRasterIO
ERROR 1: JPEGSetupEncode:PhotometricInterpretation 3 not allowed for JPEG
ERROR 1: JPEGSetupEncode:PhotometricInterpretation 3 not allowed for JPEG


How can I compress this map, please?

Thank you!

KR

Piet



More information about the gdal-dev mailing list