OK, Image::Epeg-new(\$jpg_data); does work. The $epg->resize function fails occasionally -- even though they're valid jpegs and larger than the crop size. (And the call is more likely to fail, the larger the crop size). And $epg->get_data occasionally fails (sticking exactly 64k zeroes at the beginning of the data, and then ever larger amounts of junk (?) on the end) -- even though resize returned 1.
There's not much point in posting code yet. I'm still trying to figure out if there's anything wrong with the input files. Or whether there's something wrong with my installation -- or even the hardware! Anyway -- whatever's going on, it has nothing to do with extracting a blob from DBI. :-)
I'm running perl 5.28.2 on Mac OS X 10.14.6 with MacPorts. I recently re-installed Xcode (and the command line tools, and MacPorts and Perl etc.) -- a software update to Xcode had changed some directories to from 10.14 to 10.15 (!) Some builds still fail (arm-none-eabi-gdb in MacPorts, and Image::Magick in CPAN) soooo, not sure what (if anything) is wrong...If I manage to narrow things down to a nice test I'll start a different thread.
In reply to Re^2: Extracting a blob from DBI to a buffer
by Serene Hacker
in thread Extracting a blob from DBI to a buffer
by Serene Hacker
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |