嗨,每当我有一个允许用户旋转图像的按钮时。但是,每次用户旋转图像(JPEG)时,质量都会变差。我该如何防止这种情况发生?
.php 文件
//create src image and grab destination image from folder then...
imagecopyresampled($new_image, $src_image, 0, 0, 0, 0, $width, $height, $width, $height);
$rotated_image = imagerotate($new_image, $angle, 0);
imagejpeg($rotated_image, $new_image_file_path, 100);