imagecreate和imagecreatetruecolor()。
php官网中提到
Note:
第一次对 imagecolorallocate() 的调用会给基于调色板的图像填充背景色,即用 imagecreate() 建立的图像。
所以创建image时用imagecreatetruecolor这个方法 具体原因未知
imagecreate和imagecreatetruecolor()。
php官网中提到
Note:
第一次对 imagecolorallocate() 的调用会给基于调色板的图像填充背景色,即用 imagecreate() 建立的图像。
所以创建image时用imagecreatetruecolor这个方法 具体原因未知