[SDL] Converting a surface to another color
Viktor Dick
dickviktor at gmx.net
Sun Dec 31 12:10:48 PST 2006
Hello,
I'm trying to write a simple 2D-program with SDL (I do not want to use OpenGL).
It is almost ready, but at the moment I paint the marbles of the players with
filledCircleColor. I have painted a circle with gimp with a gradient from red
(bottom) to white (top) so it looks better. I can load the image to the program,
but I need more colors and I do not want create an extra file for each color. I
need also blue, green etc. marbles. Does anyone know how to change the color in
a loaded surface? In the far future, it should also be possible to let the users
switch their colors, so it would not be possible to give a picture of each
possible color with the package.
Thanks
Viktor
More information about the SDL
mailing list