Cross Platform support using SDL 2.0

Besides the fact that C/C++ is my favored development language, one of the main reasons that I choose to use C++ and OpenGL for game development when Decade Engine was born, may years ago, is that I have always wanted to create cross platform games and 3D engine. SDL 2.0 was officially released a few weeks ago and presented a nice opportunity to achieve this goal.

“Simple DirectMedia Layer is a cross-platform development library designed to provide low level access to audio, keyboard, mouse, joystick, and graphics hardware via OpenGL…. SDL officially supports Windows, Mac OS X, Linux, iOS, and Android. Support for other platforms may be found in the source code.”

Over the past week I have ported my iOS code to OSX, Windows, Android and Linux (Ubuntu). With the help of a limited number of pre-compile directives (including the correct header files, libraries etc..), the same codebase works on all platforms. Check out my new Tutorials section over the coming weeks to see information on how to set up SDL 2.0 uses OpenGL and C++ 11 as well as the SDL extensions (Mixer, Image, TTF and Net).