Source code for several example savers is distributed with Scrplus.
Because VisualC++ is kind of yucky at handling resources, there is a VisualC++ copy of each example saver. The directory name for this second copy has the letters VC stuck at the end of it.
The list below is in order of increasing complexity.
This is a very simple saver.
This rudimentary screensaver is an adaptation of the 'blobs' example screensaver that is distributed with Borland C++. The screensaver draws blobs and lines and dots on the screen. The source code demonstrates how to use a class to keep track of your screensaver data, and how to put in support for a simple options page without preview.
This saver has mouse interaction: it shows a cursor, and you can click in places to make it display only a certain type of blob, and you can click in the bottom right to pop up a dialog, and the only way to quit it is by clicking the right mouse button, and just before it terminates it pops up a 'goodbye' dialog. Discussion of how to achieve these features is in the MyScreenSaverProc function.
Exact details of the behaviour with passwords, and differences between '95 and NT, are discussed in the MOUSEVC.CPP file.
This saver stores JPEG images as resources in the .scr file. It also stores a copy of K. Nishita's NVIEWLIB.DLL inside itself. Then, when it runs, it checks to see whether it should install NVIEWLIB into the windows directory. This design guarantees that the saver is as easy to run as possible for the user: all they need is the single .scr file, with no installation irritations.
When it runs it takes an image from its resources, breaks it up into tiles, and muddles the tiles around. The user has to restore them using mouse and keyboard.
Actually, the source code for PuzzleVC is designed so that it is easy to write a whole load of different savers all using the same basic source code but with different resources and images each time. 'Massage' is one such puzzle; it would be easy to create others.
And as well as having resources and makefile for the saver itself, each one has resources and makefile for its own little installer. This was done because it is really useful to bundle 'ScrHots' with puzzle (so the user can simply move the mouse to the corner of the screen in order to start playing immediately). The installer bundles both Scrhots and the puzzle saver inside its resources and, when run, extracts them to the appropriate directory. This again is done to make life as easy as possible for the user.
The REBASE utility from Microsoft is included in this saver's directory. I rebased NVIEWLIB so that the screen saver could load as quickly as possible, without having to relocate itself.
This screensaver is based on the 'flame' application for the PowerMac by Brian Stone. It has a small flame at the bottom of the screen. (It has to be small because my computer isn't fast enough to do better). The palette was taken from the Inconexi demo.
This screensaver shows how to write a rudimentary DirectDraw full-screen screensaver. It uses the 'TBits' library to handle most of the work. The screensaver fills the screen with static and gently changes its colours.
This screensaver has a screen of static. Sometimes just at the edge of perception, ghosts of faces appear and then vanish. The source code is fairly complex. (If you're looking for a simpler example of using DirectDraw in a screensaver, look at 'static' or 'scotch'.)
This saver has wierd diagonal fading grey lines and fronts. It's hard to describe.