You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

41 lines
759 B

  1. #pragma once
  2. typedef union {
  3. struct {
  4. float x, y, z;
  5. };
  6. struct {
  7. float r, g, b;
  8. };
  9. float v[3];
  10. } float3;
  11. typedef struct {
  12. float3 v1;
  13. float3 v2;
  14. } float2x3;
  15. float3 Cross(float3, float3);
  16. float3 Normalize(float3);
  17. float3 Abs(float3);
  18. float2x3 Abs(float2x3);
  19. float2x3 operator/(float2x3, float2x3);
  20. bool operator<=(float2x3, float);
  21. float3 operator-(float3);
  22. float3 operator*(float3, float);
  23. float3 operator*(float, float3);
  24. float3 operator/(float3, float);
  25. float3 operator+(float3, float3);
  26. float3 operator-(float3, float3);
  27. float3 operator/(float3, float3);
  28. float3& operator*=(float3&, float);
  29. float3& operator/=(float3&, float3);
  30. float3& operator+=(float3&, float3);
  31. float3& operator-=(float3&, float3);