No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.

146 líneas
3.7 KiB

  1. unit ugluMatrixEx;
  2. {$mode objfpc}{$H+}
  3. {$macro on}
  4. {$modeswitch typehelpers}
  5. interface
  6. uses
  7. Classes, SysUtils,
  8. ugluVectorEx, ugluMatrixExHelper;
  9. type
  10. TgluMatrix2f = TgluMatrixF.TMat2;
  11. TgluMatrix3f = TgluMatrixF.TMat3;
  12. TgluMatrix4f = TgluMatrixF.TMat4;
  13. TgluMatrix2d = TgluMatrixD.TMat2;
  14. TgluMatrix3d = TgluMatrixD.TMat3;
  15. TgluMatrix4d = TgluMatrixD.TMat4;
  16. PgluMatrix2f = ^TgluMatrix2f;
  17. PgluMatrix3f = ^TgluMatrix3f;
  18. PgluMatrix4f = ^TgluMatrix4f;
  19. PgluMatrix2d = ^TgluMatrix2d;
  20. PgluMatrix3d = ^TgluMatrix3d;
  21. PgluMatrix4d = ^TgluMatrix4d;
  22. {$DEFINE __MATRIX_HELPER_INTERFACE}
  23. {$DEFINE __VEC2 := TgluVector2f}
  24. {$DEFINE __VEC3 := TgluVector3f}
  25. {$DEFINE __VEC4 := TgluVector4f}
  26. {$DEFINE __IMPL := TgluMatrixF}
  27. {$DEFINE __SIZE := 2}
  28. {$DEFINE __VEC := TgluVector2f}
  29. {$DEFINE __MAT := TgluMatrix2f}
  30. {$DEFINE __HELPER := TgluTypeHelperMatrix2f}
  31. {$I ugluMatrixEx.inc}
  32. {$DEFINE __IMPL := TgluMatrixF}
  33. {$DEFINE __SIZE := 3}
  34. {$DEFINE __VEC := TgluVector3f}
  35. {$DEFINE __MAT := TgluMatrix3f}
  36. {$DEFINE __HELPER := TgluTypeHelperMatrix3f}
  37. {$I ugluMatrixEx.inc}
  38. {$DEFINE __IMPL := TgluMatrixF}
  39. {$DEFINE __SIZE := 4}
  40. {$DEFINE __VEC := TgluVector4f}
  41. {$DEFINE __MAT := TgluMatrix4f}
  42. {$DEFINE __HELPER := TgluTypeHelperMatrix4f}
  43. {$I ugluMatrixEx.inc}
  44. {$DEFINE __VEC2 := TgluVector2d}
  45. {$DEFINE __VEC3 := TgluVector3d}
  46. {$DEFINE __VEC4 := TgluVector4d}
  47. {$DEFINE __IMPL := TgluMatrixD}
  48. {$DEFINE __SIZE := 2}
  49. {$DEFINE __VEC := TgluVector2d}
  50. {$DEFINE __MAT := TgluMatrix2d}
  51. {$DEFINE __HELPER := TgluTypeHelperMatrix2d}
  52. {$I ugluMatrixEx.inc}
  53. {$DEFINE __IMPL := TgluMatrixD}
  54. {$DEFINE __SIZE := 3}
  55. {$DEFINE __VEC := TgluVector3d}
  56. {$DEFINE __MAT := TgluMatrix3d}
  57. {$DEFINE __HELPER := TgluTypeHelperMatrix3d}
  58. {$I ugluMatrixEx.inc}
  59. {$DEFINE __IMPL := TgluMatrixD}
  60. {$DEFINE __SIZE := 4}
  61. {$DEFINE __VEC := TgluVector4d}
  62. {$DEFINE __MAT := TgluMatrix4d}
  63. {$DEFINE __HELPER := TgluTypeHelperMatrix4d}
  64. {$I ugluMatrixEx.inc}
  65. {$UNDEF __MATRIX_HELPER_INTERFACE}
  66. implementation
  67. {$DEFINE __MATRIX_HELPER_IMPL}
  68. {$DEFINE __VEC2 := TgluVector2f}
  69. {$DEFINE __VEC3 := TgluVector3f}
  70. {$DEFINE __VEC4 := TgluVector4f}
  71. {$DEFINE __IMPL := TgluMatrixF}
  72. {$DEFINE __SIZE := 2}
  73. {$DEFINE __VEC := TgluVector2f}
  74. {$DEFINE __MAT := TgluMatrix2f}
  75. {$DEFINE __HELPER := TgluTypeHelperMatrix2f}
  76. {$I ugluMatrixEx.inc}
  77. {$DEFINE __IMPL := TgluMatrixF}
  78. {$DEFINE __SIZE := 3}
  79. {$DEFINE __VEC := TgluVector3f}
  80. {$DEFINE __MAT := TgluMatrix3f}
  81. {$DEFINE __HELPER := TgluTypeHelperMatrix3f}
  82. {$I ugluMatrixEx.inc}
  83. {$DEFINE __IMPL := TgluMatrixF}
  84. {$DEFINE __SIZE := 4}
  85. {$DEFINE __VEC := TgluVector4f}
  86. {$DEFINE __MAT := TgluMatrix4f}
  87. {$DEFINE __HELPER := TgluTypeHelperMatrix4f}
  88. {$I ugluMatrixEx.inc}
  89. {$DEFINE __VEC2 := TgluVector2d}
  90. {$DEFINE __VEC3 := TgluVector3d}
  91. {$DEFINE __VEC4 := TgluVector4d}
  92. {$DEFINE __IMPL := TgluMatrixD}
  93. {$DEFINE __SIZE := 2}
  94. {$DEFINE __VEC := TgluVector2d}
  95. {$DEFINE __MAT := TgluMatrix2d}
  96. {$DEFINE __HELPER := TgluTypeHelperMatrix2d}
  97. {$I ugluMatrixEx.inc}
  98. {$DEFINE __IMPL := TgluMatrixD}
  99. {$DEFINE __SIZE := 3}
  100. {$DEFINE __VEC := TgluVector3d}
  101. {$DEFINE __MAT := TgluMatrix3d}
  102. {$DEFINE __HELPER := TgluTypeHelperMatrix3d}
  103. {$I ugluMatrixEx.inc}
  104. {$DEFINE __IMPL := TgluMatrixD}
  105. {$DEFINE __SIZE := 4}
  106. {$DEFINE __VEC := TgluVector4d}
  107. {$DEFINE __MAT := TgluMatrix4d}
  108. {$DEFINE __HELPER := TgluTypeHelperMatrix4d}
  109. {$I ugluMatrixEx.inc}
  110. {$UNDEF __MATRIX_HELPER_IMPL}
  111. end.