34 |
#define PG_DRAW_H |
#define PG_DRAW_H |
35 |
|
|
36 |
#include "pgrect.h" |
#include "pgrect.h" |
37 |
|
#include "pgcolor.h" |
38 |
|
|
39 |
#ifndef M_PI |
#ifndef M_PI |
40 |
/** |
/** |
44 |
#define M_PI 3.14159265359 |
#define M_PI 3.14159265359 |
45 |
#endif // M_PI |
#endif // M_PI |
46 |
|
|
47 |
|
|
48 |
|
// Background modes |
49 |
|
|
50 |
|
/** |
51 |
|
Backgroundmode TILE. |
52 |
|
Macro defining the background mode for tiling |
53 |
|
*/ |
54 |
|
#define BKMODE_TILE 1 |
55 |
|
/** |
56 |
|
Backgroundmode STRETCH. |
57 |
|
Macro defining the background mode for stretching |
58 |
|
*/ |
59 |
|
#define BKMODE_STRETCH 2 |
60 |
|
/** |
61 |
|
Backgroundmode 3TILEH. |
62 |
|
Macro defining the background mode for horizontal 3 part tiling |
63 |
|
*/ |
64 |
|
#define BKMODE_3TILEH 3 |
65 |
|
/** |
66 |
|
Backgroundmode 3TILEV. |
67 |
|
Macro defining the background mode for vertical 3 part tiling |
68 |
|
*/ |
69 |
|
#define BKMODE_3TILEV 4 |
70 |
|
/** |
71 |
|
Backgroundmode 9TILE. |
72 |
|
Macro defining the background mode for 9 part tiling |
73 |
|
*/ |
74 |
|
#define BKMODE_9TILE 5 |
75 |
|
|
76 |
/** |
/** |
77 |
@short ParaGUI drawing functions |
@short ParaGUI drawing functions |
78 |
|
|
114 |
DECLSPEC SDL_Surface* ScaleSurface(SDL_Surface *src, double zoomx, double zoomy, |
DECLSPEC SDL_Surface* ScaleSurface(SDL_Surface *src, double zoomx, double zoomy, |
115 |
bool smooth = true); |
bool smooth = true); |
116 |
|
|
|
#ifndef SWIG |
|
117 |
//! Scale an SDL_Surface |
//! Scale an SDL_Surface |
118 |
/*! |
/*! |
119 |
Scales a 32bit or 8bit SDL_Surface to newly created destination |
Scales a 32bit or 8bit SDL_Surface to newly created destination |
149 |
return ScaleSurface(src, static_cast<double>(newx) / src->w, |
return ScaleSurface(src, static_cast<double>(newx) / src->w, |
150 |
static_cast<double>(newy) / src->h, smooth); |
static_cast<double>(newy) / src->h, smooth); |
151 |
} |
} |
|
#endif |
|
152 |
|
|
153 |
//! Scale and blit surface |
//! Scale and blit surface |
154 |
/*! |
/*! |