c++ and SDL

Started by
4 comments, last by Lazy Foo 18 years ago
please be gentle ._. i'm still a newbie i'm using VC++ 2005 express and i'm taking a look at some of the SDL sample source, and it looks like it uses C (printf statements and manual character arrays as opposed to strings). so i gotta ask, can i use SDL with c++? so i can use my couts and strings and such? if this is a stupid question then i'm sorry i asked ._. but i don't know.
Advertisement
Yup, I use c++ with sdl regularly. Works fine. Good luck.
Quote:Original post by econobeing
...can i use SDL with c++?
Yes.
ok cool.

could i possibly trouble you guys for one more thing? the source for a little sample c++ sdl program, i can't seem to find one anywhere...
Quote:Original post by econobeing
ok cool.

could i possibly trouble you guys for one more thing? the source for a little sample c++ sdl program, i can't seem to find one anywhere...
There are a lot of code samples in the documentation. Also, more good stuff here and here.
Quote:Original post by econobeing
ok cool.

could i possibly trouble you guys for one more thing? the source for a little sample c++ sdl program, i can't seem to find one anywhere...


Here's the sample code I use for my tutorials:
#include "SDL/SDL.h"int main( int argc, char* args[] ){    //Start SDL    SDL_Init( SDL_INIT_EVERYTHING );        //Quit SDL    SDL_Quit();        return 0;    }


It's used to make sure SDL is set up right.

Learn to make games with my SDL 2 Tutorials

This topic is closed to new replies.

Advertisement