Using Imager module to resample images



I've been forcing my visitors to resample their images manually to
keep them below 50kb, but this has only had so-so results. A lot of my
visitors don't understand how to resample their image, so I'm getting
high-resolution images that are something like 20px x 20px, but still
take up 50kb!

So, I've been thinking about resampling the images on the fly. The
images would be restricted to JPG, JPEG, GIF, and PNG.

I was planning to use a combination of Image::Resize and Imager, which
I've never used before, but since the load on the server is ALWAYS
high, I had a few questions first:

1. Will the use of Imager take up a lot of CPU resources?

2. How do I recognize an animated GIF from a static GIF?

3. Does Imager compress JPG images automatically? I didn't see an
option to set a compression level in the docs, but it may be called
something else that I'm not recognizing.

4. I assume that I'll need to use Image::Resize to get the current
width and height, and if it exceeds the maximum that I input then I'll
use Imager to resample it. Is there a smarter (read: simpler and/or
less resource-heavy) option that this?

TIA,

Jason
.



Relevant Pages

  • image resampling using IPT
    ... I have some medical images with pixel dimensions of say 1x1x5.5 mm ... transform and then resample them using the image processing toolbox ... array index as a coordinate and this is giving me some problems. ... dimension weighted differently to the x,y dimension when resampling is ...
    (comp.soft-sys.matlab)
  • Re: Using Imager module to resample images
    ... I've been thinking about resampling the images on the fly. ... Will the use of Imager take up a lot of CPU resources? ... use Imager to resample it. ... perldoc Imager::Transformations for converting and scaling ...
    (comp.lang.perl.misc)
  • Re: Image resampling in PPT?
    ... In the future, be sure to have the marketing people, resample the images ... When resampling images it is important change the resolution first, ... into powerpoint via (insert> pictures> from ...
    (microsoft.public.powerpoint)
  • Linux based TIFF resampling
    ... resample TIFF images to a different resolution... ... paper size from 18x24 inches to 36x48 inches or larger, ... from originals at 400 dpi. ...
    (comp.graphics.misc)
  • Re: Back to basics: Interpolation teaser
    ... On Sep 22, 1:10 pm, Martin Leese ... on the resample circle image, the circle profile displays some 'saw ... The interpolated images contain only black ...
    (sci.image.processing)

Loading