take a look at ImageAlphaBlending() On Mon, 20 May 2002, Evan wrote:
> Here is how i fixed the problem: > > //Adding logo > $dst_im = @ImageCreateFromJPEG("../".$pathImg.$NomeFile); > $src_im = @ImageCreateFromPNG("../imgsite/logoxmail.png"); > $dst_size = GetImageSize("../".$pathImg.$NomeFile); > $src_size = GetImageSize("../imgsite/logoxmail.png"); > ImageCopy( $dst_im, $src_im, 0, $dst_size[1] - $src_size[1], 0, 0, > $src_size[0], $src_size[1]); > //*******this makes the difference!!!!! > ImageJPEG($dst_im,"../".$pathImg.$NomeFile); > ImageDestroy($dst_im); > > But now I have another question: > how to mantain the transparency of the png (src_im)? > > Evan > > "Evan" <[EMAIL PROTECTED]> ha scritto nel messaggio > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > What I'm planning to do is to add the logo of the site over every image > > uploaded. > > Here is the code after upload: > > > > $dst_im = @ImageCreateFromJPEG ("../".$pathImg.$NomeFile); > > $src_im = @ImageCreateFromJPEG ("../imgsite/logo.jpg"); > > $dst_size = GetImageSize("../".$pathImg.$NomeFile); //800x600 > > $src_size = GetImageSize("../imgsite/logo.jpg"); //50x50 > > ImageCopy( $dst_im, $src_im, 150, 150, 0, 0, 50, 50); > > > > I don't get errors but it happens nothing to the original img ($dst_im). > > The image logo.jpg is 50x50 and the $dst_img is 800x600. > > > > Thanks for your help, > > Evan > > > > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php