Types.h 911 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. #pragma once
  2. #include <cstddef>
  3. #include <cstdint>
  4. namespace gameplay
  5. {
  6. struct Float2
  7. {
  8. float x;
  9. float y;
  10. };
  11. struct Float3
  12. {
  13. float x;
  14. float y;
  15. float z;
  16. };
  17. struct Float4
  18. {
  19. float x;
  20. float y;
  21. float z;
  22. float w;
  23. };
  24. struct Double2
  25. {
  26. double x;
  27. double y;
  28. };
  29. struct Double3
  30. {
  31. double x;
  32. double y;
  33. double z;
  34. };
  35. struct Double4
  36. {
  37. double x;
  38. double y;
  39. double z;
  40. double w;
  41. };
  42. struct Int2
  43. {
  44. int32_t x;
  45. int32_t y;
  46. };
  47. struct Int3
  48. {
  49. int32_t x;
  50. int32_t y;
  51. int32_t z;
  52. };
  53. struct Int4
  54. {
  55. int32_t x;
  56. int32_t y;
  57. int32_t z;
  58. int32_t w;
  59. };
  60. struct Uint2
  61. {
  62. uint32_t x;
  63. uint32_t y;
  64. };
  65. struct Uint3
  66. {
  67. uint32_t x;
  68. uint32_t y;
  69. uint32_t z;
  70. };
  71. struct Uint4
  72. {
  73. uint32_t x;
  74. uint32_t y;
  75. uint32_t z;
  76. uint32_t w;
  77. };
  78. struct Pixmap
  79. {
  80. int32_t width;
  81. int32_t height;
  82. uint8_t* pixels;
  83. };
  84. }