Skip to content
  • Ell's avatar
    buffer: add gegl_tile_handler_get[_source]_tile() · 4a2a74fd
    Ell authored
    In GeglTileHandler, add new gegl_tile_handler_get[_source]_tile()
    functions, which fetch a tile with a given coordinates from the
    tile handler (or its source).  If the tile doesn't exist, these
    functions return a newly-created tile.
    
    The functions take an additional preserve_data argument.  When it
    is FALSE, the existing tile data doesn't have to be preserved,
    which allow us to perform several optimizations:  Instead of trying
    to fetch the tile using a TILE_GET command, we look up the tile in
    the cache.  If the tile is not in the cache, we return a new tile
    -- this avoids unnecesarily reading the tile from the storage, or
    generating it.  If the tile is in the cache, we fully damage it, so
    that if it's uncloned, its existing data won't be copied (see last
    commit).
    4a2a74fd