Andrew D. Keyser wrote:
I find it not quite right that imagecolorallocatealpha is limited to 128 levels 
right now (0-127) ... the png format can support 256 with true 32bit images. I
am concerned about this because I am using php to make an application that 
loads a nonstandard image format (MM2/MC TEX) and converts it to png - but the 
format
supports 256 alpha levels, imagecolorallocatealpha does not, and therefore I am 
losing small amounts of detail in the alpha channel by reducing it to conform to
the max 128 levels idea.

Can I get an explanation as to why it's limited at 128 levels instead of the 
preferred 256, and maybe an estimate or guess to whether or not this limitation
will ever be lifted?

On to the next part of this post.
Is there any way to create an equivalent to imagecreatefrompng for tga (maybe 
imagecreatefromtga), /including/ alpha channel? I've found examples on php.net,
but none of them take an image with more than 256 colors, much less one with an 
alpha channel. I'm not keen on the binary structure of the tga format, but i
might be required to learn it this time..

Andrew


It's likely limitation of gd or png library. Try imagick extension: http://pecl.php.net/packages.php?catpid=12&catname=Images

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to