Andreas, > 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?
Ubuntu has shipped for a long time libjpeg-turbo as the system libjpeg.so.8. It has the same ABI and behaviour as the corresponding IJG version, so it can be used as a complete replacement. If you want to check: objdump -T /usr/lib/x86_64-linux-gnu/libjpeg.so.8 | grep LIBJPEGTURBO 0000000000000000 g DO *ABS* 0000000000000000 LIBJPEGTURBO_8.0 LIBJPEGTURBO_8.0 (libturbojpeg.so uses a slightly different API, that is only useful for applications directly targetted at it. Not used by GDAL. More details at https://libjpeg-turbo.org/About/TurboJPEG) > > 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| Hum, normally the COG driver makes the internal necessary steps to convert an alpha band to a mask band when using JPEG compression Even -- Spatialys - Geospatial professional services http://www.spatialys.com
_______________________________________________ gdal-dev mailing list [email protected] https://lists.osgeo.org/mailman/listinfo/gdal-dev
