/
V4DEngine.h
64 lines (43 loc) · 1.25 KB
/
V4DEngine.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
//
// Created by Federico Bertossi on 10/07/21.
//
#ifndef INC_4DMATHENGINE_V4DENGINE_H
#define INC_4DMATHENGINE_V4DENGINE_H
namespace V4DEngine {
class V4DMath {
private:
public:
// X and Y dimensions
float x;
float y;
float z;
// Constructors
V4DMath();
V4DMath(float uX, float uY, float uZ);
// Destructors
~V4DMath();
// Copy Constructor
V4DMath(const V4DMath &v);
[[noreturn]] V4DMath &operator=(const V4DMath &v);
// Operations Methods
// Sum
void operator+=(const V4DMath &v);
V4DMath operator+(const V4DMath &v) const;
// Subtraction
void operator-=(const V4DMath &v);
V4DMath operator-(const V4DMath &v) const;
// Multiplication
void operator*=(float s);
V4DMath operator*(float s) const;
// Division
void operator/=(float s);
V4DMath operator/(float s) const;
// Print the vector component;
static void show(const V4DMath &v);
};
}
#endif //INC_4DMATHENGINE_V4DENGINE_H
/*
* TODO: add the DOT product, the MATRIX product, the angle, the CROSS product,
* the conjugate, the normalize and the magnitude functions
* */