Color distortion still

Bart van den Eijnden bartvde at XS4ALL.NL
Mon Jan 3 09:29:31 EST 2005


Hi Abe,

> I have yet to file a bug but would be happy to do so.  Would you mind
> pointing me to some info on how to get started?

Filing a bug is done through the Mapserver bugzilla.

http://mapserver.gis.umn.edu/bugs/

First you need to register in order to being able to file a bug, you can
do this by following the link: "Open a new Bugzilla account".

The bugzilla system is quite easy to follow, so I am sure you will manage.
One of the most important things is to add an attachment to the bug, which
can only be done after the bug has been submitted (there is a link then
called "create an attachment" or something similar).

> Also, what do I need to do to change my image to a higher quality?

You have to use RGBA imagemode instead of PC256, for instance for png use:

  OUTPUTFORMAT
    NAME png
    MIMETYPE image/png
    DRIVER GD/PNG
    EXTENSION png
    IMAGEMODE RGBA
    TRANSPARENT TRUE
  END

Please note this will increase color depth to 24 bit instead of 8 bit,
which will make the file size of the images larger.

Best regards,
Bart

>
> Thanks.
> -Abe
>
> On Jan 3, 2005, at 9:07 AM, Frank Warmerdam wrote:
>
>> On Mon, 3 Jan 2005 09:01:44 -0500, Abe Gillespie <agillesp at vt.edu>
>> wrote:
>>> I'm using the latest version but am still getting color changing
>>> problems.  Now, however, it only happens when I have a layer with
>>> transparency.  You can see the problems here:
>>>
>>> layer w/o transparency:
>>> http://141.152.79.120/temp/color.png
>>>
>>> layer w/ transparency:
>>> http://141.152.79.120/temp/grey.png
>>>
>>> The layer with the transparency I change is the one that goes from a
>>> pinkish color to grey.
>>
>> Abe,
>>
>> I have reviewed the gdImageCopyMerge() used by mapserver
>> to apply transparent layers to the master copy, and the problem
>> seems to be there.  It appears it deliberately uses only a greyscale
>> value from the layer being overlaid on the master, presumably to
>> moderate the number of colors used.
>>
>> Generally speaking I would advise against using transparent
>> layers in 8bit mode anyways due to the difficult to predict number
>> of colors that will be needed.
>>
>> The gdImageCopyMerge() function is a part of the GD library and
>> so not under out (the mapserver developers) direct control.
>> However, if you want to file a bug on the problem we could try
>> and incorporate a special case in our higher level logic to handle
>> transparency with 8bit (pseudocolored) images.  If you file a bug on
>> this issue please include this email so we don't have to re-discover
>> what is going on.
>>
>> Best regards,
>> --
>> ---------------------------------------
>> +--------------------------------------
>> I set the clouds in motion - turn up   | Frank Warmerdam,
>> warmerdam at pobox.com
>> light and sound - activate the windows | http://pobox.com/~warmerdam
>> and watch the world go round - Rush    | Geospatial Programmer for Rent
>>
>



More information about the mapserver-users mailing list