Mercurial > sdl-ios-xcode
view INSTALL @ 688:c0522010bb6d
Date: Tue, 12 Aug 2003 14:26:19 +0200 (MEST)
From: "Mattias Engdeg?rd"
Subject: bug in SDL_GetRGB/GetRGBA
There's an embarrassing bug in GetRGB/GetRGBA which apparently has been there
for years. It incorrectly converts colours with < 8 bits/channel.
It came to my attention today in #sdl.
What it does now is (for each channel):
rv = (pixel & fmt->Rmask) >> fmt->Rshift;
*r = (rv << fmt->Rloss) + (rv >> (8 - fmt->Rloss));
which is wrong; the last line should be
*r = (rv << fmt->Rloss) + (rv >> (8 - (fmt->Rloss << 1)));
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Tue, 12 Aug 2003 15:17:20 +0000 |
parents | 263e4884f70d |
children | 0a45995a7fc3 |
line wrap: on
line source
To compile and install SDL: 1. Run './configure; make; make install' If you are cross-compiling from Linux to Win32, you should read the file README.Win32 If you are compiling using Visual C++ on Win32, you should read the file VisualC.html 2. Look at the example programs in ./test, and check out the HTML documentation in ./docs to see how to use the SDL library. 3. Join the SDL developer mailing list by sending E-mail to sdl-request@libsdl.org and put "subscribe" in the subject of the message. Or alternatively you can use the web interface: http://www.libsdl.org/mailing-list.php That's it! Sam Lantinga <slouken@libsdl.org>