MIssing files
This commit is contained in:
parent
ba009f8edd
commit
d8af125817
2 changed files with 19 additions and 0 deletions
1
src/engine/math/point3d.cpp
Normal file
1
src/engine/math/point3d.cpp
Normal file
|
@ -0,0 +1 @@
|
|||
#include "point3d.hpp"
|
18
src/engine/math/point3d.hpp
Normal file
18
src/engine/math/point3d.hpp
Normal file
|
@ -0,0 +1,18 @@
|
|||
#pragma once
|
||||
|
||||
#include "../../platform/base.hpp"
|
||||
#include "vector3d.hpp"
|
||||
|
||||
namespace engine::math {
|
||||
struct point3d : vector3d {
|
||||
point3d() = default;
|
||||
point3d(float32 x, float32 y, float32 z) : vector3d(x, y, z){};
|
||||
inline point3d operator+(const vector3d &v) {
|
||||
return point3d(this->x + v.x, this->y + v.y, this->z + v.z);
|
||||
};
|
||||
inline vector3d operator-(const point3d &b) {
|
||||
return vector3d(b.x - this->x, b.y - this->y, b.z - this->z);
|
||||
}
|
||||
};
|
||||
|
||||
}; // namespace engine::math
|
Loading…
Reference in a new issue