[GRASS-dev] Re: [grass-code I] r.out.gdal: COMPRESS=JPEG
yields "ERROR 1: JPEGSetupEncode:PhotometricInterpretation 3 not
allowed for JPEG"
tutey at o2.pl
Sat Apr 28 04:44:25 EDT 2007
Glynn Clements wrote:
> Maciej Sieczka wrote:
>> This bug still applies. I don't know why "format=GTiff type=Byte
>> createopt=COMPRESS=JPEG" do not work together. The output raster is all
>> black. According to GeoTIFF spec JPEG compression should work just fine
>> with integer raster: "JPEG should only be used with Byte data" .
> I thought that I had replied to this already.
> Oh; I did, but none of the addresses in the original message accept
> replies, so it went into the bit-bucket.
Too bad, yes.
>> r.out.gdal creates paletted images (i.e. the map data is saved as a
>> single band; it isn't expanded to RGB).
>> Note that the argument to creatopt= is passed directly to GDAL.
>> r.out.gdal has no knowledge of which options are allowed or
>> meaningful, so it's up to the user not to pass options which won't work.
I guess I comply.
$ g.region rast=vegcover
$ r.out.gdal in=vegcover format=GTiff type=Byte
Is there something wrong with: "format=GTiff type=Byte
createopt=COMPRESS=JPEG" when exporting an integer raster, value range 1-6:
$ r.info -t vegcover
$ r.info -r vegcover
in the context of what GDAL's GeoTIFF spec says: "JPEG should only be
used with Byte data"?
More information about the grass-dev