ID:               39353
 User updated by:  seth at pricepages dot org
 Reported By:      seth at pricepages dot org
 Status:           Bogus
 Bug Type:         GD related
 Operating System: Mac 10.4
 PHP Version:      5CVS-2006-11-02 (snap)
 Assigned To:      pajoye
 New Comment:

That is a workaround. imagecopyresized() isn't working as 
defined in the manual, so you've changed the destination 
image to compensate.

I suppose it's fine if you don't want to fix it, I think I 
can use this workaround for now.

There is a waste of pixel processing, though. You need to 
process the entire final image twice. But I've seen worse 
code in the GD library...


Previous Comments:
------------------------------------------------------------------------

[2006-11-04 18:59:26] [EMAIL PROTECTED]


$img = imagecreatetruecolor($width, $height);
$bgdalpha = imagecolorallocatealpha($img,0,0,0, 127);
imagefill($img, 0,0, $bgdalpha);
imagecopyresized($img, $small, 0,0, 0,0, $width, $height,
$srcW,$srcH);
imagesavealpha($img, 1);
imagepng($img, 'a.png');


------------------------------------------------------------------------

[2006-11-04 18:10:10] seth at pricepages dot org

But I *still* can't produce the image that I want. I simply 
want to enlarge $small. How can I do this?

------------------------------------------------------------------------

[2006-11-04 17:50:39] [EMAIL PROTECTED]

"Shouldn't it be default?"

Backward compatibility... GD is an old library. But things are getting
better.

No bug > bogus.

------------------------------------------------------------------------

[2006-11-04 17:48:46] seth at pricepages dot org

Oh! No, I didn't realize imagesavealpha() existed. Why is 
saving the alpha a separate function? Shouldn't it be default?

------------------------------------------------------------------------

[2006-11-04 17:45:05] seth at pricepages dot org

I am simply trying to enlarge the original image. I can't find 
a work-around in PHP, but I can create the image in Adobe 
Photoshop.

This is what I'm attempting to create:
http://pricepages.org/temp/partialTrans2.png

By the way, this image is the outline of Bermuda. :)

------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/39353

-- 
Edit this bug report at http://bugs.php.net/?id=39353&edit=1

Reply via email to