Re: Image resize

From: Date: Thu, 13 Mar 2003 01:09:27 +0000
Subject: Re: Image resize
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-139420@lists.php.net to get a copy of this message
if your system suports the commands, try imagecreatetruecolor() instead of imagecreate(), and imagecopyresampled() instead of imagecopyresized(), hope this helps, Hugh ----- Original Message ----- From: "Michael P. Carel" <mikecarel@teamglac.com> To: <php-general@lists.php.net> Sent: Wednesday, March 12, 2003 3:23 PM Subject: [PHP] Image resize > hi to all, > > I have a problem here in image resizing, after the image has been resized > , the image has been discolorized. How can i recreate the image with the > same resolution and color properties. > > Here's the sample code from my class file: > > $origPic = ImageCreateFromJpeg( $this -> iOrig[ 'tmp_name' ] ); > $this -> iNew = ImageCreate($nWidth,$nHeight); > ImageCopyResized($this -> iNew, $origPic, 0, 0, 0, 0, $nWidth, $nHeight, > $width, $height); > > Thanx in advance. > > > > Mike > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.general (#139420) next »