BKE_blender.h 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. /*
  2. * ***** BEGIN GPL LICENSE BLOCK *****
  3. *
  4. * This program is free software; you can redistribute it and/or
  5. * modify it under the terms of the GNU General Public License
  6. * as published by the Free Software Foundation; either version 2
  7. * of the License, or (at your option) any later version.
  8. *
  9. * This program is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU General Public License
  15. * along with this program; if not, write to the Free Software Foundation,
  16. * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  17. *
  18. * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
  19. * All rights reserved.
  20. *
  21. * The Original Code is: all of this file.
  22. *
  23. * Contributor(s): none yet.
  24. *
  25. * ***** END GPL LICENSE BLOCK *****
  26. */
  27. #ifndef __BKE_BLENDER_H__
  28. #define __BKE_BLENDER_H__
  29. /** \file BKE_blender.h
  30. * \ingroup bke
  31. * \since March 2001
  32. * \author nzc
  33. * \brief Blender util stuff
  34. */
  35. #ifdef __cplusplus
  36. extern "C" {
  37. #endif
  38. struct UserDef;
  39. void BKE_blender_free(void);
  40. void BKE_blender_globals_init(void);
  41. void BKE_blender_globals_clear(void);
  42. void BKE_blender_version_string(
  43. char *version_str, size_t maxncpy,
  44. short version, short subversion, bool v_prefix, bool include_subversion);
  45. void BKE_blender_userdef_data_swap(struct UserDef *userdef_dst, struct UserDef *userdef_src);
  46. void BKE_blender_userdef_data_set(struct UserDef *userdef);
  47. void BKE_blender_userdef_data_set_and_free(struct UserDef *userdef);
  48. void BKE_blender_userdef_app_template_data_swap(struct UserDef *userdef_dst, struct UserDef *userdef_src);
  49. void BKE_blender_userdef_app_template_data_set(struct UserDef *userdef);
  50. void BKE_blender_userdef_app_template_data_set_and_free(struct UserDef *userdef);
  51. void BKE_blender_userdef_data_duplicate(struct UserDef *userdef_dst, struct UserDef *userdef_src);
  52. void BKE_blender_userdef_data_free(struct UserDef *userdef, bool clear_fonts);
  53. /* set this callback when a UI is running */
  54. void BKE_blender_callback_test_break_set(void (*func)(void));
  55. int BKE_blender_test_break(void);
  56. /* Blenders' own atexit (avoids leaking) */
  57. void BKE_blender_atexit_register(void (*func)(void *user_data), void *user_data);
  58. void BKE_blender_atexit_unregister(void (*func)(void *user_data), const void *user_data);
  59. void BKE_blender_atexit(void);
  60. #ifdef __cplusplus
  61. }
  62. #endif
  63. #endif /* __BKE_BLENDER_H__ */