pool.h 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. /*
  2. (c) Copyright 2001-2009 The world wide DirectFB Open Source Community (directfb.org)
  3. (c) Copyright 2000-2004 Convergence (integrated media) GmbH
  4. All rights reserved.
  5. Written by Denis Oliver Kropp <dok@directfb.org>,
  6. Andreas Hundt <andi@fischlustig.de>,
  7. Sven Neumann <neo@directfb.org>,
  8. Ville Syrjälä <syrjala@sci.fi> and
  9. Claudio Ciccani <klan@users.sf.net>.
  10. This library is free software; you can redistribute it and/or
  11. modify it under the terms of the GNU Lesser General Public
  12. License as published by the Free Software Foundation; either
  13. version 2 of the License, or (at your option) any later version.
  14. This library is distributed in the hope that it will be useful,
  15. but WITHOUT ANY WARRANTY; without even the implied warranty of
  16. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  17. Lesser General Public License for more details.
  18. You should have received a copy of the GNU Lesser General Public
  19. License along with this library; if not, write to the
  20. Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  21. Boston, MA 02111-1307, USA.
  22. */
  23. #ifndef __FUSION__SHM__POOL_H__
  24. #define __FUSION__SHM__POOL_H__
  25. #include <fusion/types.h>
  26. DirectResult fusion_shm_pool_create ( FusionWorld *world,
  27. const char *name,
  28. unsigned int max_size,
  29. bool debug,
  30. FusionSHMPoolShared **ret_pool );
  31. DirectResult fusion_shm_pool_destroy ( FusionWorld *world,
  32. FusionSHMPoolShared *pool );
  33. DirectResult fusion_shm_pool_attach ( FusionSHM *shm,
  34. FusionSHMPoolShared *pool );
  35. DirectResult fusion_shm_pool_detach ( FusionSHM *shm,
  36. FusionSHMPoolShared *pool );
  37. DirectResult fusion_shm_pool_allocate ( FusionSHMPoolShared *pool,
  38. int size,
  39. bool clear,
  40. bool lock,
  41. void **ret_data );
  42. DirectResult fusion_shm_pool_reallocate( FusionSHMPoolShared *pool,
  43. void *data,
  44. int size,
  45. bool lock,
  46. void **ret_data );
  47. DirectResult fusion_shm_pool_deallocate( FusionSHMPoolShared *pool,
  48. void *data,
  49. bool lock );
  50. #endif