Dear members,
When using the image_lib with the following config
$config['source_image'] = '/path/to/image/mypic.jpg';
$config['maintain_ratio'] = TRUE;
$config['width'] = 75;
and using a picture thats e.g. 400px x 200px (w x h) I get a real strange result
Instead of resizing the picture to a width of 75px and height of 38px (or something like that) as one would expect it just creates a picture being
75px wide and 200px high!
And I dont think that this is wanted behaviour.
Its obviously caused by the following lines within libraries/Image_lib.php
264: * Should we maintain image proportions?
265: *
266: * When creating thumbs or copies, the target width/height
267: * might not be in correct proportion with the source
268: * image's width/height. We'll recalculate it here.
269: *
270: */
271: if ($this->maintain_ratio === TRUE && ($this->width != '' AND $this->height != ''))
272: {
273: $this->image_reproportion();
274: }
275:
Maybe it should be like
271: if ($this->maintain_ratio === TRUE && ($this->width != '' OR $this->height != ''))
I hope this can be fixed because I doesnt make sense to set an arbitrary height of ...lets say 300px too in order to prevent the picture from being malformed!
Thank you very much in advance!
greets Rico
