www.NewsDownload.co.uk Page 5
Overview
Asteroids.hpp
Asteroids.cpp
Number.hpp
Number.cpp
Text.hpp
Text.cpp
AstroRock.hpp
AstroRock.cpp
AstroShip.hpp
AstroShip.cpp
AstroShot.hpp
AstroShot.cpp
Astro_UFO.hpp
Astro_UFO.cpp
GNU License

Coding a Windows Screen Saver

2012-02-23 16:15 By Jason Birch

First in a series of how to code articles. Demonstrating coding an Asteroids Clone game with various technologies. This example using C++ and implementing as a Windows screen saver.

Back in 1997 I wrote a screen saver for Windows NT 4, later I converted it to DirectX and then Java. Recently I dug out the source code and converted it to Linux. I am now publishing the source code here under the GNU General Public License License as a series of articles describing how to write code using various technologies.

The code here can be freely distributed, but only on the condition that a credit to Jason Birch is maintained in the source code files and running application.

The source code is broken down into the classes which make the application, in the tabs on the left of this article. The tabs are placed in order from the simplest classes to the more complex classes last. There is a commentary accompanying each source code file explaining how the code operates.

A compiled version of the screen saver is available here, it is just 65KB in size.


Screen Shot Of Linux Conversion

Having reviewed the code now for this article, fifteen years on, I would write the code significantly differently today, as the code could be simplified by using inheritance. There are also some untidy parts of the code which could do with being refined. However, the code does provide a good simple example of what it achieves.

Required Environment
To run the screen saver application, a Windows operating system is required.
To develop the screen saver application, Microsoft Visual Studio Express is required, which is freely available from www.microsoft.com.

Writing Code
Visual Studio is the best tool as it provides support for resources and good inline tools.

Compiling Code
Visual Studio is the best tool to compile the project.

Distributing Application
The application can only be run on a Microsoft Windows operating system. Copy the file into the Windows install directory so it appears in the list of installed screen savers.

Running Application
The application can either be run by double clicking on the application icon or by configuring it as the screen saver in Control Panel.

Loading...