[nycphp-talk] Resample Image on the Fly

Kenneth Downs ken at
Mon Jan 29 09:55:35 EST 2007

Randal Rust wrote:
> On 1/29/07, Dan Cech <dcech at> wrote:
>> I'm not entirely sure what you're asking...can you give us a general
>> idea of what you're trying to achieve?
> Sure. Take a look here:

If you are on a *nix machine, take a look at the 'convert' tool, it is a 
CLI tool that will do nigh-well anything to an image.

Convert has always given resizing results completely satisfactory to me, 
though I am not a graphics pro.

> What I have done is used getimagesize(0 to get the original width and
> height of the image. Then I modify those values proportionally with a
> script I wrote and do this:
> <img src="'.$url.'" width="'.$newW.'" height="'.$newH.'" />
> The issue is that the images don't look as clear as I'd like them to
> after resizing. I think they just need to be resampled.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: ken.vcf
Type: text/x-vcard
Size: 261 bytes
Desc: not available
URL: <>

More information about the talk mailing list