Definition at line 5 of file Point.h.
◆ distSq()
Definition at line 40 of file Point.h.
40 {
41 return (a.x - b.x) * (a.x - b.x) + (a.y - b.y) * (a.y - b.y);
42 }
◆ operator*()
| Point Point::operator* |
( |
float |
scalar | ) |
const |
|
inline |
Definition at line 20 of file Point.h.
20 {
21 return Point{x * scalar, y * scalar};
22 }
◆ operator+()
| Point Point::operator+ |
( |
const Point & |
other | ) |
const |
|
inline |
Definition at line 9 of file Point.h.
9 {
10 return Point{x + other.x, y + other.y};
11 }
◆ operator+=()
Definition at line 34 of file Point.h.
34 {
35 x += other.x;
36 y += other.y;
37 return *this;
38 }
◆ operator-()
| Point Point::operator- |
( |
const Point & |
other | ) |
const |
|
inline |
Definition at line 14 of file Point.h.
14 {
15 return Point{x - other.x, y - other.y};
16 }
◆ operator/()
| Point Point::operator/ |
( |
float |
scalar | ) |
const |
|
inline |
Definition at line 24 of file Point.h.
24 {
25 return Point{x / scalar, y / scalar};
26 }
◆ operator*
Definition at line 29 of file Point.h.
29 {
30 return Point{v.x * scalar, v.y * scalar};
31 ;
32 }
The documentation for this struct was generated from the following file: