]> Pileus Git - grits/blobdiff - src/objects/grits-tile.h
Add motion threshold when clicking objects
[grits] / src / objects / grits-tile.h
index 309f4bc0386588768208c0a20fbb38fef4e48d88..fc87695ab3718f43de5dd5dde8c6963232930c3b 100644 (file)
@@ -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);