= 128) $alphay = 127; $alpha = imagecolorallocatealpha($imgsrc, 255, 255, 255, $alphay); imagefilledrectangle($imgsrc, $x1, ($y2-$i-1), $x2, ($y2-$i), $alpha); // 修改此处,从下往上渐变 } header('content-type: image/jpeg'); imagejpeg($imgsrc,'09.jpg'); imagedestroy($imgsrc); ? 修改以下代码让它的渐变效果从下到上。php $imgsrc = imagecreatefromstringfile_get_contentsimagejpg; $imgsrcw = imagesx$imgsrc; $imgsrch = imagesy$imgsrc; $height = 1080; $x1 = 0; $x2 = $imgsrcw - $x1; $y1 = 0; $y2 = $hei

原文地址: https://www.cveoy.top/t/topic/c8Wo 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录