Big Pixels 0.0.7
A screensaver for Linux
The point of a screensaver is to protect the screen from displaying the same picture for a prolonged period of time due to inactivity of the user. Why? Because some monitors (LCD, plasma) can burn out pixles if the pixels continue to display the same color for a long time. I don't know the theory, but have always believed this to be true. Now the best way to save a monitor from this problem is to turn it off. However, people are lazy. That's why there are these automated programs to do it for us. Well, not turn off the monitor (they can do that too, by the way), but to display something else, preferably animated, instead of that stale emacs window (xterm, firefox, ...). However, some screensavers completely ignore the fact that ALL of the pixels must cycle through various colors. Not just portions of the screen. An example that comes to mind is "Pop art squares". What's wrong with it? There are black borders around the squares! And they stay in the same place all the time, not even bothering to change color.
The most simple screensaver that comes to mind that would solve the problem would be to paint the screen with one color and repaint it with random color at a resoanable interval. However, this would not be plesant to look at. The next thing that comes to mind is to change the fill smoothly over time, so that you get one continuos color change, and not "abrupt flickers". However, this is also to simplish and not aethetic for the human being. The human will quickly get bored of this. The next logical step would be to increase the number of colors. So, say, divide the screen into quadrants each that would smoothly change from one color to the next. This, too, seemed like a trivial screensaver idea to me. Then I came to the realization that maybe if the number of quadrants was variable, and changed randomly, it would be neat to llok at. The transition should be as seemingly invisible as possible. To do this, first all of the quadrants must smoothly arrive at one color. And then the number of quadrants should change. This way, there is no "flicker".
And this is how the Big Pixels screensaver came to be.
gcc -pedantic -Wall -Wunreachable-code -Wextra -O3 -o main main.c `pkg-config --libs --cflags gtk+-2.0 gthread-2.0`
NOTE: because gcc does some heavy optimizations, the foollowing is reported (using -O3 switch)
main.c: In function ‘thread_func’:
main.c:110: warning: will never be executed
main.c:108: warning: will never be executed