Opened 17 years ago
Last modified 17 years ago
#2378 closed defect
Color binding swaps green and blue values — at Initial Version
Reported by: | sdlime | Owned by: | sdlime |
---|---|---|---|
Priority: | normal | Milestone: | 5.0.1 release |
Component: | MapServer C Library | Version: | unspecified |
Severity: | normal | Keywords: | |
Cc: |
Description
From Jacob D.:
I am trying to make use of the colour binding feature, and it basically works, except... the colours are not quite right. My colours do not match those in MapInfo, although I can make MapInfo emulate the MapServer colours by swapping blue and green around. So basically: my RGB values are interpreted by MapServer as RBG.
and a follow up from Frank W.:
With some pointers from Howard, I found this segment of code in bindColorAttribute() in maputil.c:
attribute->red = atoi(tokens[0]); attribute->blue = atoi(tokens[1]); attribute->green = atoi(tokens[2]);
I think this is responsible. If you are building from source, try just changing it to the more obvious organization. I'd also suggest you file a bug in Trac on the issue we will see if there is a subtle reason for this, or it's just a typo.