flipCode - CDX Tech View [an error occurred while processing this directive]
Gaming Technology View: The CDX Library
An interview with Bil Simser


Are you interested in game development but find yourself annoyed at the amount of "grunt work" going on behind the scenes before you can even get something simple on the screen in Windows? Ever wish someone would do all that for you and wrap it all up nicely in easy-to-use C++ classes. Well, guess what? You're in luck. Today we take a look at the CDX Game Development Library, an open source project maintained by Bil Simser. The CDX game development kit is of course free to use and is currently aimed at Windows using Microsoft's Direct X technologies. If this sounds like your bag of chips, read on! Thank you Bil for taking the time to answer the following questions...

Please tell us a bit about yourself and what you're trying to accomplish with the CDX library.

I'm a 33 9/10s year old programmer who's been working with computers for over 15 years now. I first wrote games back in the early 80s for BBS doors and shareware. In the last while I've been working at Canadian Pacific Railway writing train control systems. I found CDX about 3 years ago, originally written by a guy named Dan Farley. After working with it for a year, adding parts to it, I took over the maintenance. CDX then took on a life of its own as I assembled a great team of maintainers and breathed new life into CDX, moving it to DirectX 6.0 and now 7.0. The main goal of CDX is provide a simple, full-featured library that will allow new and old programmers to write games without having to worry about the intricities of DirectX and Windows programming.


What exactly is the CDX game development library? What I mean is both a general overview as well as a specific description of how it works and what it does.

CDX is a set of clean, easy to use C++ wrappers that hide all the ugliness of DirectX from you. It provides some simple components that you can build on to build games and multi-media applications. The components are based on game programmer needs. Things like scrolling tilemaps, sprites, input devices and sounds are all wrapped up in C++ classes. This allows the programmer to concentrate on his game logic rather than how to draw a knight racing across a landscape on the screen or how to make his demon army sound like its banging down the doors. By removing the techno-babble of DirectX from the user, CDX lets you focus on what's important in game programming, the game.


How easy is it to jump in and start developing with the library?

Extremely easy! In fact the simplist DirectX demo that Microsoft provides (page-flipping) that takes up 12 pages of code, only requires about 20 lines using CDX. The C++ objects are simple and require very little knowledge of C++, DirectX or Windows programming for that matter to use them. Given a set of graphics and sounds, you could have a skeleton of a game put together in a few hours.


Why would someone want to use this library over the many other game development libraries out there?

I've only looked at a few libraries out there and haven't spent much time with them. CDX is touted as being easy to use and that's one of the key features. It's what makes it stand out from other libraries. An easy to use clean interface is the foundation of a good set of classes. It's a matter of choice though, so I suggest looking over all the options to anyone thinking about using CDX and make a decision based on your requirements. CDX may not be for you. While I think it's the best game programming library out there, I could be a little biased ;)


Who is using (or has used) CDX to develop games?

CDX has been used by a lot of people for not only games but some great multimedia applications too. While nobody at Microsoft or Blizzard have heard of CDX (let alone used it), there have been some great applications put together with it. One user in Germany wrote a multimedia presentation complete with a mini-game for Coca-Cola using CDX and it looks fabulous. The package was distributed on a CD-ROM in Europe. You can find some links on the homepage to user site that have written things with CDX.


What are your end goals for the library?

The main goal has already been achieved, and that's to help people write games easily. Its very hard these days for new people coming from a DOS or even a Windows background and teach them the ins and outs of DirectX just to write a game. CDX provides this by buffering the user from having to know a lot of under the covers programming. However, if they do want to learn, the source is always available and will help them out that way too.


CDX is open source. How can people get involved and help out with the project?

Anyone is welcome to contribute to the project. First off, if you write a game or application using CDX and don't mind showing off your work, we would love to see it! Better yet, if your project is open source (not a requirement to use the library) then it would be great to show new users how you accomplished things. Secondly you can write an add-on for CDX. An add-on can be anything from adding JPEG or TIFF support to a full-blown GUI sub-system (as some people have done). The add-ons will enhance the use of CDX and provide more game like tools. Third, if you really want to be on the cutting edge of development, you can join the CDX Maintenance team and become a regular maintainer of the library. Maintainers go in and fix problems with the library, add new features and generally keep CDX running smoothly. Anyone is free to join the maintenance team. Information is posted on the website about how.


Any other comments on the project, life, coding, anything?

Well I'm currently writing a book based on CDX and game programming. It will be out in the spring of 2000 and will focus on writing a full game using CDX (as well as learning CDX and game programming in general from the ground up). As for coding, I can't emphasize enough to always do it. Just sit down whenever you have a chance and code. Start a small project if you have to. Just to keep your skills up and increase your knowledge and awareness. Personally I eat, breath and live code from my day-job writing real-time train dispatching system to nights with CDX, my games and some other personal projects. I think I'm a bit of a freak in that I have so much on the go and spend a good 20 hours a day in front of the computer. So I'm not one to follow as an example, but you get the idea.


For more information about obtaining the CDX library, etc... click here!


Return to flipcode





[an error occurred while processing this directive]