masterexploder / PHPThumb

PHP Thumbnail & Image Manipulation Library
http://phpthumb.gxdlabs.com
980 stars 264 forks source link

preserveAlpha uses wrong value for transparent #73

Open ccoltman opened 11 years ago

ccoltman commented 11 years ago

This is in addition to another issue about this not working with a file stream. In the same function, this should be updated to use the proper transparent color, 127. 0 is opaque!

        $colorTransparent = imagecolorallocatealpha
        (
            $this->workingImage, 
            $this->options['alphaMaskColor'][0], 
            $this->options['alphaMaskColor'][1], 
            $this->options['alphaMaskColor'][2], 
            127
        );