- Notifications
You must be signed in to change notification settings - Fork 0
Closed
Labels
Description
Description
Restructure the Vector2 struct to a Vector2_Base template struct, with same variables, 2 _Ty for x and y axis.
Hold the enumeration for the axis.
At end, add a struct Vector2 and a struct Vector2i with using Vector2_Base with the types float32 and int32.
Details
Projekt: "ecm.math.dll"
Datei: "vector2.hpp" "vector2.inl"
Namespace: "ecm::math"
Tasks
- Restructure struct Vector2 to Vector2_Base
- Remove all inline, only constexpr functions/methods
- Add the template
- Change variables type from float32 to _Ty
- Add a index operator with uint8 to the struct for the axis
- Add Vector2, Vector2A, Vector2i and Vector2iA definitions
- Edit the default operators
- Vector2_Base: Vector2_Base == Vector2_Base
- Vector2_Base: Vector2_Base != Vector2_Base
- Vector2_Base: Vector2_Base + Vector2_Base
- Vector2_Base: Vector2_Base - Vector2_Base
- Vector2_Base: Vector2_Base * Vector2_Base
- Vector2_Base: Vector2_Base / Vector2_Base
- Vector2_Base: Vector2_Base += Vector2_Base
- Vector2_Base: Vector2_Base -= Vector2_Base
- Vector2_Base: Vector2_Base *= Vector2_Base
- Vector2_Base: Vector2_Base /= Vector2_Base
- Edit the vector/float operators
- Vector2_Base: Vector2_Base + float32
- Vector2_Base: Vector2_Base - float32
- Vector2_Base: Vector2_Base * float32
- Vector2_Base: Vector2_Base / float32
- Vector2_Base: Vector2_Base += float32
- Vector2_Base: Vector2_Base -= float32
- Vector2_Base: Vector2_Base *= float32
- Vector2_Base: Vector2_Base /= float32