|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2002-01-18 20:39 UTC] cyril at pernin dot net
[2002-06-07 07:44 UTC] edink@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Oct 30 04:00:02 2025 UTC |
with GD if i copy a part of a pict2.png (with tranparency set) in an other pict1.png. GD 1.0.6 give me : the picct1.png image is visible under the tranparency zone of the copied image (pict1.png)... :) GD 2.0 (same script) the same zone is transparent :( what can i do? here is the script: <?php function LoadGif ($xxxmgname) { $xxxm = @ImageCreateFromPNG ($xxxmgname); $bg = ImageColorAllocate ($xxxm, 255, 255, 255); return $xxxm; } header ("Content-type: image/PNG "); $xxxm = @ImageCreate (450, 300) or die ("Cannot Initialize new GD image stream"); $bg = ImageColorAllocate ($xxxm, 255, 255, 255); imagecolortransparent($xxxm, $bg); $couleurnoms = ImageColorAllocate ($xxxm, 250, 250, 250); $xxxm=loadgif ("vierge.png"); $paysages=loadgif ("images.png"); ImageCopy ($xxxm,$paysages, 150, 100, 261, 196, 63, 63); $color=imagecolorstotal ($xxxm); ImageString ($xxxm, 2, 10, 250, "$color couleurs", $couleurnoms); ImagePNG ($xxxm);// Imagejpeg($im,'',20); ImageDestroy ($xxxm); ?>