23 lines
574 B
C++
23 lines
574 B
C++
/* A class with some handy surface handling statics */
|
|
|
|
#ifndef _DRAWUTILS_H_
|
|
#define _DRAWUTILS_H_
|
|
|
|
#include <SDL/SDL.h>
|
|
#include <string>
|
|
|
|
using std::string;
|
|
|
|
class DrawUtils
|
|
{
|
|
public:
|
|
DrawUtils() {}
|
|
static SDL_Surface* load(string file);
|
|
static bool draw(SDL_Surface* dest, SDL_Surface* drawable, int x, int y);
|
|
static bool draw(SDL_Surface* dest, SDL_Surface* drawable, int x, int y,
|
|
int x2, int y2, int w, int h);
|
|
static void draw_line(Sint16 x1, Sint16 y1, Sint16 x2, Sint16 y2, Uint16 width, Uint32 colour, SDL_Surface* dest);
|
|
};
|
|
|
|
#endif
|