GDI+ Postmortem

Let's be honest. GDI+ was never the first choice when it came to high performance graphics or games in a windows environment. Before there was Managed DirectX, the option was Win32 with a mixture of C and C++ form that would hijack the windows messages to create a game loop. Now we have WPF with amazing graphical capabilities and 3D support and the question applies: Why should you care about GDI+?

In this article

  • A simulation game loop will be created.
  • A simple collision system will be added to our objects.
  • The simplest of life cycle will be created.


The sample program is simple. We will handle the mouse click and from that location a new object will be added with a random vector to update position on each update. On the example you could see black and gray squares. The black represent newly added objects, gray represent aged objects, and finally the object will vanish once the life cycle ends.

The question was why anyone should care about GDI+. I consider one of the reasons to be education. Many traditional schools don't always teach the latest and greatest. No matter what the reason is and even though you wont be writing the next AAA game using GDI+, it proves to be a good and simple tool to learn concepts regarding 2D collision and 2D coordinate systems.