gimptile.h 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. /* LIBGIMP - The GIMP Library
  2. * Copyright (C) 1995-1997 Peter Mattis and Spencer Kimball
  3. *
  4. * gimptile.h
  5. *
  6. * This library is free software: you can redistribute it and/or
  7. * modify it under the terms of the GNU Lesser General Public
  8. * License as published by the Free Software Foundation; either
  9. * version 3 of the License, or (at your option) any later version.
  10. *
  11. * This library is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  14. * Lesser General Public License for more details.
  15. *
  16. * You should have received a copy of the GNU Lesser General Public
  17. * License along with this library. If not, see
  18. * <http://www.gnu.org/licenses/>.
  19. */
  20. #if !defined (__GIMP_H_INSIDE__) && !defined (GIMP_COMPILATION)
  21. #error "Only <libgimp/gimp.h> can be included directly."
  22. #endif
  23. #ifndef __GIMP_TILE_H__
  24. #define __GIMP_TILE_H__
  25. G_BEGIN_DECLS
  26. /* For information look into the C source or the html documentation */
  27. struct _GimpTile
  28. {
  29. guint ewidth; /* the effective width of the tile */
  30. guint eheight; /* the effective height of the tile */
  31. guint bpp; /* the bytes per pixel (1, 2, 3 or 4 ) */
  32. guint tile_num; /* the number of this tile within the drawable */
  33. guint16 ref_count; /* reference count for the tile */
  34. guint dirty : 1; /* is the tile dirty? has it been modified? */
  35. guint shadow: 1; /* is this a shadow tile */
  36. guchar *data; /* the pixel data for the tile */
  37. GimpDrawable *drawable; /* the drawable this tile came from */
  38. };
  39. GIMP_DEPRECATED
  40. void gimp_tile_ref (GimpTile *tile);
  41. GIMP_DEPRECATED
  42. void gimp_tile_ref_zero (GimpTile *tile);
  43. GIMP_DEPRECATED
  44. void gimp_tile_unref (GimpTile *tile,
  45. gboolean dirty);
  46. GIMP_DEPRECATED
  47. void gimp_tile_flush (GimpTile *tile);
  48. GIMP_DEPRECATED
  49. void gimp_tile_cache_size (gulong kilobytes);
  50. GIMP_DEPRECATED
  51. void gimp_tile_cache_ntiles (gulong ntiles);
  52. /* private function */
  53. G_GNUC_INTERNAL void _gimp_tile_cache_flush_drawable (GimpDrawable *drawable);
  54. G_END_DECLS
  55. #endif /* __GIMP_TILE_H__ */