BFPlatform.h 941 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. #pragma once
  2. #define BFSTDCALL
  3. #include "../darwin/DarwinCommon.h"
  4. #include "TargetConditionals.h"
  5. #ifndef __IPHONEOS__
  6. #define __IPHONEOS__
  7. #endif
  8. #define BF_PLATFORM_IOS
  9. #define BF_PLATFORM_POSIX
  10. #define BF_PLATFORM_OPENGL_ES2
  11. #define BF_PLATFORM_FULLSCREEN
  12. #if !TARGET_IPHONE_SIMULATOR
  13. #ifdef __LP64__
  14. #ifdef __I386__
  15. #define BF_PLATFORM_X64
  16. #else
  17. #define BF_PLATFORM_ARM64
  18. #endif
  19. #define BF64
  20. #else ////
  21. #ifdef __I386__
  22. #define BF_PLATFORM_I386
  23. #else
  24. #define BF_PLATFORM_ARM32
  25. #endif
  26. #define BF32
  27. #endif
  28. #else
  29. #ifdef __LP64__
  30. #define BF_PLATFORM_X64
  31. #define BF64
  32. #else ////
  33. #define BF_PLATFORM_I386
  34. #define BF32
  35. #endif
  36. #endif
  37. #ifdef BFSYSLIB_DYNAMIC
  38. #define BF_EXPORT extern "C" __declspec(dllexport)
  39. #define BF_CALLTYPE
  40. #else
  41. #define BF_EXPORT extern "C"
  42. #define BF_CALLTYPE
  43. #endif
  44. #ifdef BF_PLATFORM_ARM32
  45. #define BF_REGISTER_COUNT 15
  46. #elif defined BF32
  47. #define BF_REGISTER_COUNT 7
  48. #else
  49. #define BF_REGISTER_COUNT 15
  50. #endif