0

Don't know if this is the right place to post this but...
I just started with SDL, and get the error:

expected constructor, destructor, or type conversion before '*' token


With this code:

#pragma comment(lib, "SDL.lib")
#pragma comment(lib, "SDLmain.lib")


#include "C:\Documents and Settings\Mikael\Mina dokument\SDL\SDL-1.2.14\include\SDL\SDL.h"
#include <cstdlib>
#include <iostream>
#include <string>


using namespace std;


const int SCREEN_WIDTH = 640;
const int SCREEN_HEIGHT = 480;
const int SCREEN_BPP = 32;

SDL_SURFACE *message = NULL;
SDL_SURFACE *screen = NULL;
SDL_SURFACE *background = NULL;

Why is this?

2
Contributors
4
Replies
5
Views
8 Years
Discussion Span
Last Post by DawnOfIkaros
0

Try changing SDL_SURFACE to SDL_Surface.

Also, for ease of use, you might try dumping the SDL headers into your IDE's header folder - a wee easier than typing that long string per source file.

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.