GD图片添加水印,png图片背景也黑色解决方法
imagecopy($bg, $rotate, $dst_x, $dst_y, 0, 0, imagesx($rotate), imagesy($rotate)); imagealphablending($bg, FALSE);//取消默认的混色模式 imagesavealpha($bg, TRUE);
使用imagecopy方法,手册说使用imagecopymerge方法最后pct传值100时有效,未能测试出来~
imagecopy($bg, $rotate, $dst_x, $dst_y, 0, 0, imagesx($rotate), imagesy($rotate)); imagealphablending($bg, FALSE);//取消默认的混色模式 imagesavealpha($bg, TRUE);
使用imagecopy方法,手册说使用imagecopymerge方法最后pct传值100时有效,未能测试出来~