Complete.Org: Mailing Lists: Archives: freeciv-dev: December 2004:
[Freeciv-Dev] (PR#11692) New fogging broken on 16-bit displays
Home

[Freeciv-Dev] (PR#11692) New fogging broken on 16-bit displays

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Subject: [Freeciv-Dev] (PR#11692) New fogging broken on 16-bit displays
From: "Robert Smith" <r_q_smith@xxxxxxxxx>
Date: Sat, 25 Dec 2004 14:05:34 -0800
Reply-to: bugs@xxxxxxxxxxx

<URL: http://bugs.freeciv.org/Ticket/Display.html?id=11692 >

The new fogging code produces some very odd results on my 16-bit
display.  To be honest, I'm not entirely sure what the logic behind the
current gode in fog_sprite is, but this:

guint8 red = ((pixel & ftile->visual->red_mask) >>
ftile->visual->red_shift) / 2;
guint8 green = ((pixel & ftile->visual->green_mask) >>
ftile->visual->green_shift) / 2;
guint8 blue = ((pixel & ftile->visual->blue_mask) >>
ftile->visual->blue_shift) / 2;

to produce the new red, green, and blue components is both simpler and 
works on both 16 and 24-bit displays.


=====
RQS


                
__________________________________ 
Do you Yahoo!? 
Jazz up your holiday email with celebrity designs. Learn more. 
http://celebrity.mail.yahoo.com





[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] (PR#11692) New fogging broken on 16-bit displays, Robert Smith <=