Re: RFI: Image_Resize
| From: | Bertrand Mansion | Date: | Tue, 16 Apr 2002 08:41:13 +0000 |
| Subject: | Re: RFI: Image_Resize | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-5545@lists.php.net to get a copy of this message | ||
le 16/04/02 5:17, Alan Knowles à alan@akbkhome.com a écrit :
> I think this would be a good next step - rename the class Image_Transform::
>
> -- and look at adding the matrix abilities later. - although they would
> probably have to be done at the pixel level in php unless any of the
> libraries support this.
>
> attached is a semi-Pearified version of Image_resize.php and
> Image_Resize_GD.php, havent had time to look at the _IM...
>
> Ive added percentage '10%' and <1 (0.13) factor scaling, - the
> resizeX(n) are public methods, although Resize(0,n) sounds like it would
> be the first choice for alot of developers -I cant see any big issues
> with leaving resizeX public and having it as an 'added extra' anyway....
>
> it does a bit more error checking etc. - It would be good to start
> getting this into PEAR, so that there is a base to start working on -
> even if it changes a little :)
I don't understand this in the resize method :
if ($new_x == 0)
return $this->resizeY($new_y);
if ($new_y == 0)
return $this->resizeX($new_x);
What if both are equal to 0 ?
Bertrand