Topic: Specify Width ,Height is auto
Hello,
Is it possible to specify a width and have the height be auto to prevent distortion?
Thanks!
Randy
Plupload Forum → General discussion → Specify Width ,Height is auto
Hello,
Is it possible to specify a width and have the height be auto to prevent distortion?
Thanks!
Randy
Do you mean when resizing an image? If so the height and width specified are maximums. The image aspect ratio is always preserved.
So specifying a resize width and height of 320x240 doesn't mean all of the images will be made exactly 320x240 - but they will be resized such that one of the dimensions will be 320 or 240 (or it will be exactly 320x240 if your source image happens to have an aspect ratio of 320/240).
Oh and if you want every image resized to have the same width, but the height varies to match the aspect ratio of the source image you could try setting the resize width to your chosen width, and the resize height to a very large number (larger than the height of any possible source image).
Mike,
Thank you, that's awesome!
Randy
Very useful info, thanks mate.
Is this how the image resizing works in version 1.3 in the Yii extension? Thanks
I'm pretty sure the basics of how a resized image's dimensions are determined has not changed in a very long time. It sill works the same in 1.3.
But I don't know what a Yii extension is so I can't help you there?
They're saying the width and height should have an option to be minimums, yet keep the same aspect ratio. Like this image: http://www.omega-webdesign.nl/plupload-demo.jpg
Plupload Forum → General discussion → Specify Width ,Height is auto
You are not logged in. Please login or register.
Powered by PunBB, supported by Informer Technologies, Inc.
The pun_repository official extension is installed. Copyright © 2003–2009 PunBB.
Generated in 0.086 seconds (86% PHP - 14% DB) with 10 queries