Open ambs opened 6 years ago
Hi! Image magick does work with big images. I have converted successfully image with size 19469x5000.
Sorry, it was a typo. More than 30K width.
Sorry, more 30k requires changes in script - looks like issue in 32 bit calculations in shell math. May be in some modern shell versions it can works.
Not sure how shell math is handling it. But swapping from imagemagick to gdal_translate was enough for now.
0033-vila_nova_milfontes/image.jpg JPEG 32327x2796 32327x2796+0+0 8-bit sRGB 15.74MB 0.000u 0:00.000
Result here: http://eremita.di.uminho.pt/~ambs/panoramics/0033-vila_nova_milfontes/index.html But yes, this one is still bellow the (2^16)/2 limit. But in the other hand, shell math looks good:
echo $((30000 + 30000 * 2)) 90000
Best
Hm, maybe. There in code image sizes is multiply to get more accurate sizes for new images. Right now I don't remember details, sorry - need deep script debug.
No stress. For me, for now, all working good. Just though it would be nice to share.
Thank you! Can you share code parts for GDAL tools? I'll add it to script.
I do not have everything working. Here goes my current script. -- https://gist.github.com/ambs/0c55e775ed27584e2d798017e8d7babc
Note that GDAL tools does not like small files, so this script uses gdal tools in some places, and image magick in others. Also, the tile funcionality from imagemagick is not available, thus I needed to create two loops and crop manually the image.
Cheers
Unfortunately image magick does not work when a dimension is larger than 30000 pixels. GDAL tools seem to support bigger raster files, but the interface is different from convert. I am trying to understand how can I tweak your great script to use them. Cheers!
EDIT: I have portions of the script working with
gdalinfo
andgdal_translate
. But they are tuned for my standard use case, and would need work for other cases. Anyway, would be happy to share them.http://eremita.di.uminho.pt/~ambs/panoramics/0013-vez/index.html