X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=src%2Fobjects%2Fgrits-tile.h;h=fc87695ab3718f43de5dd5dde8c6963232930c3b;hb=d55c77bbf477e582a8525ac831ad97b035b8185d;hp=309f4bc0386588768208c0a20fbb38fef4e48d88;hpb=f383c18c9f85a1b439c6bfb2a27d652278ed019a;p=grits diff --git a/src/objects/grits-tile.h b/src/objects/grits-tile.h index 309f4bc..fc87695 100644 --- a/src/objects/grits-tile.h +++ b/src/objects/grits-tile.h @@ -37,6 +37,7 @@ struct _GritsTile { /* Pointer to the tile data */ gpointer data; + gboolean load; /* Drawing order */ gint zindex; @@ -53,6 +54,17 @@ struct _GritsTile { /* Last access time (for garbage collection) */ time_t atime; + + /* Projection used by tile data */ + GritsProj proj; + + /* Internal data to the tile */ + guint tex; + GdkPixbuf *pixbuf; + guchar *pixels; + gint width; + gint height; + gint alpha; }; struct _GritsTileClass { @@ -121,6 +133,16 @@ void grits_tile_update(GritsTile *root, GritsPoint *eye, gdouble res, gint width, gint height, GritsTileLoadFunc load_func, gpointer user_data); +/* Load tile data from pixel buffer */ +gboolean grits_tile_load_pixels(GritsTile *tile, guchar *pixels, + gint width, gint height, gint channels); + +/* Load tile data from a GdkPixbuf */ +gboolean grits_tile_load_pixbuf(GritsTile *tile, GdkPixbuf *pixbuf); + +/* Load tile data from an image file */ +gboolean grits_tile_load_file(GritsTile *tile, const gchar *file); + /* Find the leaf tile containing lat-lon */ GritsTile *grits_tile_find(GritsTile *root, gdouble lat, gdouble lon);