[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: GFX under Linux
"Mark D'voo" <line72@postmark.net> wrote:
>what was so hard about SDL??
>
>#include <SDL/SDL.h>
>
>int main() {
>SDL_Surface *screen;
>if (SDL_Init(SDL_INIT_VIDEO) != 0) {
> printf ("unable to initialize sdl: %s\n", SDL_GetError());
> return 1;
>}
>//make sure sdl quits
>atexit(SDL_Quit);
>//open a screen
>//set the 0 at the end to 1 for full screen mode
>screen = SDL_SetVideoMode(800,600,16,0);
>if (screen == NULL) {
> printf ("unable to set video mode: %s\n", SDL_GetError());
> return 1;
>}
>return 0;
>}
I tried to compile your code, but i got the following error:
"unable to initialize sdl: Unable to open a console terminal"
Thank you
NW