Work needs to scale some GIF and then go to Imagecopymerge, but found that the use of Imagecreatetruecolor and imagecopyresampled later found that the background map is not right, the original transparent background image into black, It was later found that some modifications could be made:
|1 2 3 4 5 6||$img = Imagecreatetruecolor (200, 200); 2. Coloring $color =imagecolorallocate ($img, 255,255,255); 3. Setting up transparent Imagecolortransparent ($img, $color); Imagefill ($img, 0,0, $color);|
And then there's no problem with imagecopyresampled and Imagecopymerge.