Vector4.pkg 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. $#include "Math/Vector4.h"
  2. class Vector4
  3. {
  4. Vector4();
  5. Vector4(const Vector4& vector);
  6. Vector4(const Vector3& vector, float w);
  7. Vector4(float x, float y, float z, float w);
  8. ~Vector4();
  9. bool operator ==(const Vector4& rhs) const;
  10. Vector4 operator + (const Vector4& rhs) const;
  11. Vector4 operator - () const;
  12. Vector4 operator - (const Vector4& rhs) const;
  13. Vector4 operator * (float rhs) const;
  14. Vector4 operator * (const Vector4& rhs) const;
  15. Vector4 operator / (float rhs) const;
  16. Vector4 operator / (const Vector4& rhs) const;
  17. Vector4 operator / (const Vector4& rhs) const;
  18. float DotProduct(const Vector4& rhs) const;
  19. float AbsDotProduct(const Vector4& rhs) const;
  20. float ProjectOntoAxis(const Vector3& axis) const;
  21. Vector4 Abs() const;
  22. Vector4 Lerp(const Vector4& rhs, float t) const;
  23. bool Equals(const Vector4& rhs) const;
  24. bool IsNaN() const;
  25. String ToString() const;
  26. float x_ @ x;
  27. float y_ @ y;
  28. float z_ @ z;
  29. float w_ @ w;
  30. static const Vector4 ZERO;
  31. static const Vector4 ONE;
  32. };
  33. Vector4 VectorLerp(const Vector4& lhs, const Vector4& rhs, const Vector4& t);
  34. Vector4 VectorMin(const Vector4& lhs, const Vector4& rhs);
  35. Vector4 VectorMax(const Vector4& lhs, const Vector4& rhs);
  36. Vector4 VectorFloor(const Vector4& vec);
  37. Vector4 VectorRound(const Vector4& vec);
  38. Vector4 VectorCeil(const Vector4& vec);