< Browse > Home / Customization, Game Development, OpenGL, Programming / Blog article: CodeBlocks with SDL Support

CodeBlocks with SDL Support

August 13th, 2008 | 6 Comments | Posted in Customization, Game Development, OpenGL, Programming by Diego

This is a quick and simple tutorial on how to setup CodeBlocks with support for the Simple DirectMedia Layer (SDL).

Lets start…

If you have never installed CodeBlocks before, keep reading until you see the You are done! text. If you already have CodeBlocks installed skip down to where it says I already have CodeBlocks!.

With this method you should be set for any SDL and OpenGL source code that Diego and I give you. Since you don’t already have CodeBlocks, the first thing you need to do is download these two packages. One is the MinGW compiler with SDL support and the second is CodeBlocks by itself.

Download Files

MinGW with SDL

CodeBlocks Core Application Only

Once your downloads are done, install the MinGW with SDL first. Simply click the extract button and wait until it is done.

Next, Install CodeBlocks ( Just click next until it starts the copying process ) and Run it after the install. When it starts up you will see that it has detected the GNU CCC Compiler, simply click OK and that’s it.

If you want to associate .cpp and .h files with CodeBlocks ( highly recommended ) simply do so. That’s it you have CodeBlocks with SDL support.

******************************************************************************************

******************************************************************************************

It’s nice to know that you are using CodeBlocks, but first lets make sure of something. This guide works if you have installed the CodeBlocks package that comes bundled with the MinGW compiler. If you are using a different compiler, simply download the MinGW with SDL package that is linked above and install it. When you are done installing it simply change the default compiler to the GNU CCC Compiler and you are done!

If you have installed the bundled version of CodeBlocks this will not take that long…

First, Download this package and extract it as it is:

Download File

MinGW SDL Add-in

Next, open CodeBlocks ( don’t open it with a project ) and click on the Settings and then Compilers and Debuggers:

After that, simply click on Reset Defaults and OK on the following 3 Message Windows.

That’s it you now have SDL support on CodeBlocks!



Leave a Reply |

Related Posts to CodeBlocks with SDL Support

Follow Discussion

6 Responses to “CodeBlocks with SDL Support”

  1. Andy Says:

    Hey everyone this is great opportunity to start learning about SDL, check out the source code for the Piranha Plant, Wario, and Coin Game and show us what you can do!

  2. Diego Says:

    Wow this is great. You even created an extractor! I’m going to try this out on my desktop later on since I only have this on my laptop!

  3. Andy Says:

    Yeah I did, that’s why I didn’t finish when we were talking earlier, I had to test them. :P

Trackbacks

  1. Open Source Games | Talk Binary  
  2. Classic Pong Source Code Released | Talk Binary  
  3. Modify source code to run or make your own video games | Talk Binary  

Leave a Reply