Date: Wed, 1 Apr 2009 01:42:05 -0700 From: Doug Hardie <bc979@lafn.org> To: freebsd-questions@freebsd.org Subject: Use of libgd Message-ID: <FA5EBE39-473C-42F8-B979-31B1AF8C4269@lafn.org>
next in thread | raw e-mail | index | archive | help
I am trying to use libgd to create some images. They are creating properly except there are color changes that I can't seem to figure out. The initial image is basically black and white PNG. I have converted it to GD2 format. There are a number of secondary images that have a couple of colors (black, red, blue etc). Each of them has been converted to GD2 format. When any of these are converted back to PNG format they display properly. However when I load the initial image, and then overlay it with one of the secondary images, the colors in the secondary images change. For example, red can become yellow or black etc. I tried gdImageCopyPalette from the secondary to the primary before the overlay but that seems to have no effect. Clearly I am missing something but can't seem to figure it out. Any ideas? Thanks.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?FA5EBE39-473C-42F8-B979-31B1AF8C4269>