## Ancient programming projects, part 1

Once in a while, I think most people develop a certain amount of nostalgia for their childhoods. This past week, I’ve somewhat started a trip down memory lane, and have resurrected some of my earliest projects, which brings me plenty of good memories. I will maybe share more of these projects in some of the future posts.

First, a bit of background: When I was young, my parents would never allow me to have a video gaming console, even though I wanted one badly and all my friends were immersed in the technology glut of always wanting to upgrade to fastest and computationally powerful gaming consoles. While I was living in Chicago, I briefly owned a Sega Genesis console, which my dad had bought for me along with a few games to play. I am not sure what happened to the console eventually, but it seemed to just disappear from my life; perhaps my dad saw I was spending a large amount of time with it and eventually gave it away without me knowing? Eventually, I was given a Nintendo Game boy, and after a rather uncomfortable episode of my dad discovering I had stolen batteries from him to power it on, he essentially destroyed the Game Boy. This was around 1995.

## Random Shape Generator

One of the projects that turned out surprisingly well was a screen saver I had created which generated random shapes. I cannot get this screen saver to work in Windows 10, but it works fine in Windows XP. In this project, it started by me experimenting with a series of vectors with varying length and diverging at random angles, and I wondered what it might look like if you take this series of vectors and then keep repeating it several times. For instance, your typical square consists of a single vector with an angle of 90° repeated end-to-end four times; and most common geometric shapes could be reconstructed using this same process. What I was surprised to learn is that as long as the series of vectors doesn’t have a tendency to shoot off in 180° will eventually end up exactly where they started. In the process, the repetition of groups of vectors would create a shape which has interesting features. Some how out of your chaotic array of random vectors, there tended to appear order, and that to me was beautiful. I took this concept, and figured out how to turn it into a screensaver. I added some variability into color gradients used to draw the shapes which added an extra dimension to the graphics. These color gradients also behaved in a random way.

In the above video (best viewed in high-resolution full-screen), I took around 10 minutes of screen video of the screen saver running on the Windows XP virtual machine I set up, and overlaid it with some Bach. The screen saver appears to run faster now than I remember it running almost 20 years ago, and at some point the animations appear jumpy. However, it’s a relic of the past which has a certain amount of meaning for me, and I think most people can appreciate.

In Windows XP, the screen saver installs and has various customization features. On the Screen Saver setup screen, the screen saver resizes to display in a miniature preview screen image. When you click on the settings button, you can adjust the number of shapes which show up on the screen at once, the time between screens and shapes, and line thickness. An “about” button shows a dialog which gives credit to another Planet Source Code contributor who had provided much of the code I used to develop the screen saver.

Another piece of software included with the screen saver submission allowed for designing various shapes. The interface provided a way of defining the number of vectors in a segment, the length and angle of those vectors, the gradient colors, and display settings such as grid and axis display.

The Visual Basic source code and installer packages can be downloaded using the following links. Keep in mind, it probably won’t work on Windows 10 — and need I even mention, DAD, it won’t work on Macintosh (unless you start a Windows XP virtual machine, which you can do using Parallels). The recommended operating system is Windows XP (which very few people even use anymore). Also, note that the software also has quirks. I think this should be understandable, because it was developed by a 16-year-old.

/