4 * Created on: Aug 7, 2012
8 #ifndef GRAPHICS_FRAME_H_
9 #define GRAPHICS_FRAME_H_
11 #include "../geometry/Point.h"
20 Frame(SDL_Surface *s, int borderWidth, int borderHeight, int repeatWidth = 1, int repeatHeight = 1, int xOffset = 0, int yOffset = 0)
21 : surface(s), borderWidth(borderWidth), borderHeight(borderHeight), repeatWidth(repeatWidth), repeatHeight(repeatHeight), xOffset(xOffset), yOffset(yOffset) { }
24 int MinWidth() const { return 2 * borderWidth; }
25 int MinHeight() const { return 2 * borderHeight; }
26 int BorderWidth() const { return borderWidth; }
27 int BorderHeight() const { return borderHeight; }
28 void Draw(SDL_Surface *dest, const geometry::Point<int> &position, int width, int height) const;
43 #endif /* GRAPHICS_FRAME_H_ */