Subject: incorrect bg average

From: Mikhael Goikhman <[email-masked]>
Date: Sun, 26 May 2002 14:08:22 +0000

I am a bit puzzled with background/lightsky.png from fvwm-themes cvs.

It is bluish, without any red, but when I do:

  Colorset 14 Pixmap background/lightsky.xpm, bg average, fg contrast

$[bg.cs14] becomes red - rgb:7272/2d2d/4c4c.

If save this 400x300 image scaled to 75% or less, bg becomes blue.
But if I scale it to 90%, it is still red.
Converting to xpm does not change results.

Does someone know how this is possible?

Regards,
Mikhael.
--
Visit the official FVWM web page at <URL:http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm-workers" in the
body of a message to [email-masked].
To report problems, send mail to [email-masked]

---

From: Dominik Vogt <[email-masked]>
Date: Mon, 27 May 2002 12:23:59 +0200

> Does someone know how this is possible?

Maybe an integer overflow?  Can you mail me that picture?

Bye

Dominik ^_^  ^_^

-- 
Dominik Vogt, email: [email-masked]
LifeBits Aktiengesellschaft, Albrechtstr. 9, D-72072 Tuebingen
fon: ++49 (0) 7071/7965-0, fax: ++49 (0) 7071/7965-20
--
Visit the official FVWM web page at <URL:http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm-workers" in the
body of a message to [email-masked].
To report problems, send mail to [email-masked]

---

From: Mikhael Goikhman <[email-masked]>
Date: Mon, 27 May 2002 13:04:38 +0000

> Maybe an integer overflow?  Can you mail me that picture?

http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/*checkout*/fvwm-themes/fvwm-themes/themes/redmondxp/images/background/lightsky.png?rev=HEAD&content-type=image/png

Regards,
Mikhael.

---

From: Dominik Vogt <[email-masked]>
Date: Mon, 27 May 2002 15:46:18 +0200

> > Maybe an integer overflow?  Can you mail me that picture?

Yup, it's an integer overflow in the variable adding the blue
values.  Patch committed.

Bye

Dominik ^_^  ^_^