php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #42201 imagecolortransparent
Submitted: 2007-08-03 12:06 UTC Modified: 2007-08-03 12:47 UTC
From: filipe dot martins at i-senso dot com Assigned: pajoye (profile)
Status: Not a bug Package: GD related
PHP Version: 5.2.4RC1 OS: Windows XP
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: filipe dot martins at i-senso dot com
New email:
PHP Version: OS:

 

 [2007-08-03 12:06 UTC] filipe dot martins at i-senso dot com
Description:
------------
imagecolortransparent doesn't return the alpha color index though the given PNG is transparent.


Filipe Martins
www.i-senso.com

Reproduce code:
---------------
$img = imagecreatefrompng ('test-imagecreatefrompng.png');
echo imagecolortransparent ($img);


Expected result:
----------------
The PNG is transparent, so the function shouldn't return -1.

Actual result:
--------------
It returns -1.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-08-03 12:08 UTC] filipe dot martins at i-senso dot com
You can get the PNG here:
http://www.i-senso.com/tmp/test-imagecreatefrompng.png

Thanks.
 [2007-08-03 12:47 UTC] pajoye@php.net
The transparent area is not the transparent color but rgba(255,138,138,0) (here alpha is the level of opacity, 0=transparent, 255=opaque).

not a bug > bogus.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Sun Aug 17 01:00:02 2025 UTC