Hi Thomas,
Interesting - thanks for the hint about turbo-jpeg.
I found out that my gdal is linked against libjpeg.so.8 and not against
libturbojpeg.so.0 which is also present on my system.
Would I have to tell gdal to compile against libturbojpeg with the
--with-jpeg= flag in order to benefit from turbo-jpeg?
And yes, the mask thing is what I was struggling with JPEG compression
and RGB images, but I got the mask to work by using the following
gdal_translate command:
|gdal_translate -b 1 -b 2 -b 3 -b mask -of COG --config
GDAL_DISABLE_READDIR_ON_OPEN TRUE\ -co COMPRESS=JPEG -co BIGTIFF=YES -co
NUM_THREADS=4 -a_srs EPSG:2056\ infile.vrt outfile.tif|
Thanks and greetings,
Andreas
Am 09.10.20 um 17:53 schrieb thomas bonfort:
Andreas,
The size gains compared to JPEG are marginal, at the cost of
noticeably higher compression and decompression times (especially
compared to the optimized turbo jpeg library). WEBP does however
support an alpha channel which can be desirable, as it avoids having
to add a mask IFD to the TIFF.
Regards,
Thomas
On Fri, Oct 9, 2020 at 4:30 PM Andreas Neumann <[email protected]
<mailto:[email protected]>> wrote:
Thanks Thomas,
Yes, compiling it with libtiff=internal and libgeotiff=internal
did the trick - thanks for the hint!
Do you recommending using webp instead of jpeg inside GTIFF or
COG? It seems like the WEBP compression produces smaller file
sizes than JPEG, but how does it look speed-wise regarding
decompression?
Thanks,
Andreas
On 2020-10-09 15:33, thomas bonfort wrote:
You might need to compile with gdal's internal libtiff so that
webp-in-tif support is enabled (i.e. the system libtiff might not
have webp support). Also note you should probably be adding "-co
TILED=YES" to your translate command.
On Fri, Oct 9, 2020 at 3:07 PM Andreas Neumann
<[email protected] <mailto:[email protected]>> wrote:
Hi,
I am using a self-compiled GDAL 3.1.2 version and try to
create a GTIFF file with COMPRESS=WEBP
libwebp-devel and other webp automatic dependencies are
installed on this ubuntu 18.04 machine. I could also compile
against libwebp
However, when running gdal_translate like
gdal_translate -b 1 -b 2 -b 3 -b mask -of GTIFF -co
COMPRESS=WEBP -co PHOTOMETRIC=YCBCR -co BLOCKXSIZE=512 -co
BLOCKYSIZE=512 -co BIGTIFF=YES -co NUM_THREADS=4 -a_srs
EPSG:2056 -projwin 2599700 1226200 2602200 1224650
ch.swisstopo.orthofoto_2018.rgb.vrt test_webp_ycbcr.tif
I get the following error output:
Input file size is 530000, 480000
Warning 6: 'WEBP' is an unexpected value for COMPRESS
creation option of type string-select.
ERROR 1: Cannot create TIFF file due to missing codec for WEBP.
Any idea what might be missing in my installation - where do
I get this missing codec for WEBP?
Thanks,
Andreas
_______________________________________________
gdal-dev mailing list
[email protected] <mailto:[email protected]>
https://lists.osgeo.org/mailman/listinfo/gdal-dev
_______________________________________________
gdal-dev mailing list
[email protected] <mailto:[email protected]>
https://lists.osgeo.org/mailman/listinfo/gdal-dev
_______________________________________________
gdal-dev mailing list
[email protected]
https://lists.osgeo.org/mailman/listinfo/gdal-dev