#define             TILE_DATA_POINTER                   (tile,
struct              TileLink;




#define             TILE_DATA_POINTER(tile,x,y)


typedef struct {
  gshort  ref_count;    /* reference count. when the reference count is
                          *  non-zero then the "data" for this tile must
                         *  be valid. when the reference count for a tile
                         *  is 0 then the "data" for this tile must be
                         *  NULL.
  gshort  write_count;  /* write count: number of references that are
                           for write access */
  guint   share_count;  /* share count: number of tile managers that
                           hold this tile */
  guint   dirty : 1;    /* is the tile dirty? has it been modified? */
  guint   valid : 1;    /* is the tile valid? */
  guint  cached : 1;    /* is the tile cached */


  guint zorched : 1;    /* was the tile flushed due to cache pressure
			   [zorched]? */
  guint zorchout: 1;    /* was the tile swapped out due to cache
			   pressure [zorched]? */
  guint  inonce : 1;    /* has the tile been swapped in at least once? */
  guint outonce : 1;    /* has the tile been swapped out at least once? */


  guchar  bpp;          /* the bytes per pixel (1, 2, 3 or 4) */
  gushort ewidth;       /* the effective width of the tile */
  gushort eheight;      /* the effective height of the tile
                         *  a tile's effective width and height may be smaller
                         *  (but not larger) than TILE_WIDTH and TILE_HEIGHT.
                         *  this is to handle edge tiles of a drawable.
  gint    size;         /* size of the tile data (ewidth * eheight * bpp) */

  TileRowHint *rowhint; /* An array of hints for rendering purposes */

  guchar *data;         /* the data for the tile. this may be NULL in which
                         *  case the tile data is on disk.

  gint64  swap_offset;  /* the offset within the swap file of the tile data.
                         * if the tile data is in memory this will be set
                         * to -1.

  TileLink *tlink;

  Tile     *next;       /* List pointers for the tile cache lists */
  Tile     *prev;
} Tile;

struct TileLink

struct TileLink {
  TileLink    *next;
  gint         tile_num; /* the number of this tile within the drawable */
  TileManager *tm;       /* A pointer to the tile manager for this tile.
                          *  We need this in order to call the tile managers
                          *  validate proc whenever the tile is referenced
                          *  yet invalid.