aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/utils/point.cpp7
-rw-r--r--src/utils/point.hpp1
2 files changed, 8 insertions, 0 deletions
diff --git a/src/utils/point.cpp b/src/utils/point.cpp
index f4fd0184..c4306ea7 100644
--- a/src/utils/point.cpp
+++ b/src/utils/point.cpp
@@ -36,6 +36,13 @@ namespace usdx
{
}
+ Point& Point::operator=(const Point& point)
+ {
+ x = point.x;
+ y = point.y;
+ return *this;
+ }
+
float Point::get_x(void) const
{
return x;
diff --git a/src/utils/point.hpp b/src/utils/point.hpp
index f4d23c4f..7c1ec727 100644
--- a/src/utils/point.hpp
+++ b/src/utils/point.hpp
@@ -37,6 +37,7 @@ namespace usdx
public:
Point(float x, float y);
Point(const Point& point);
+ Point& operator=(const Point& point);
float get_x(void) const;
float get_y(void) const;