webperimental: killstack decides stack protects.
[freeciv.git] / client / gui-gtk-3.0 / sprite.h
blob194cd9a62c7f89666a14476385a01039ccacd64b
1 /**********************************************************************
2 Freeciv - Copyright (C) 1996-2005 - Freeciv Development Team
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation; either version 2, or (at your option)
6 any later version.
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12 ***********************************************************************/
13 #ifndef FC__SPRITE_H
14 #define FC__SPRITE_H
16 #include <gtk/gtk.h>
18 /* client */
19 #include "sprite_g.h"
21 struct sprite
23 cairo_surface_t *surface;
26 struct sprite *sprite_scale(struct sprite *src, int new_w, int new_h);
27 void sprite_get_bounding_box(struct sprite *sprite, int *start_x,
28 int *start_y, int *end_x, int *end_y);
29 struct sprite *crop_blankspace(struct sprite *s);
31 /********************************************************************
32 Note: a sprite cannot be changed after these functions are called!
33 ********************************************************************/
34 GdkPixbuf *sprite_get_pixbuf(struct sprite *sprite);
35 GdkPixbuf *surface_get_pixbuf(cairo_surface_t *surf, int width, int height);
37 #endif /* FC__SPRITE_H */