home *** CD-ROM | disk | FTP | other *** search
- ClockView
-
- by Matt Pharr
- pharr@cs.yale.edu
-
- Here's another module for BackSpace that bounces a 180 point digital clock
- around the screen. Definitely another staple of the screen-saver world, but on
- the other hand, it's not one of those totally great demos of all the neat
- animation the NeXT is capable of. The only notable part of the implementation
- was that it saved the trouble of having to erase the old drawing by making a
- border of about 6 pixels around the edges of the bitmap, so that whenever it
- draws another bitmap, the new, displaced, one will totally cover up the old
- one. I read about that somewhere and only remembered to do it after I wrestled
- with flicker on the redraw for longer than I should have. I guess that's one of
- the more basic animation techniques, but heck, I thought it was pretty cool.
-
- For black and white folks, it keeps the clock at a steady pure white, but for
- you bums with color, it randomly moves the RGB values around between 0 and 1.
- It doesn't end up looking as cool as it could, doing this, because it only
- redraws the bitmap that has the time in it when the time changes- i.e. once
- a second, so the color changes aren't nice and smooth... There's probably
- a neater thing that can be done with color, but given that I can't try out
- any of my ideas, I'm sort of limited in seeing what works and doesn't...
-
- To install it, just copy ClockView.o into your BackSpace.app directory, or
- into /LocalLibrary/BackSpaceViews.
-
- All I ask is that you drop me a letter at pharr@cs.yale.edu if you like it or
- have any suggestions.
-