I'm using PHP HTTP uploading to add photos to a gallery. I'm resizing the images using PHP functions, creating small thumbnails and larger images which display when the thumbnails are clicked.
The quality of the larger images is not great but is acceptable. Some of the thumbnails are pretty bad though. They're choppy and pixelated.
I'll put the resize code I'm using below. Does anyone have any tweaks I could use to improve the quality of the final images? I've already got jpeg quality cranked up to 100.
The quality of the larger images is not great but is acceptable. Some of the thumbnails are pretty bad though. They're choppy and pixelated.
I'll put the resize code I'm using below. Does anyone have any tweaks I could use to improve the quality of the final images? I've already got jpeg quality cranked up to 100.
Code:
$src2=ImageCreateFromJpeg($upfile);
$dst2=ImageCreateTrueColor($thumbwidth,$thumbheight);
ImageCopyResized($dst2,$src2,0,0,0,0,$thumbwidth,$thumbheight,$width,$height);
$thumbpath='ups/covers/';
$thumbname='cov_'.$filename;
$thumbfile=$thumbpath.$thumbname;
ImageJpeg($dst2,$thumbfile,100);
ImageDestroy($dst2);
ImageDestroy($src2);