Isle
|
[AI] 2D point class templated on its coordinate type. More...
#include <mxgeometry.h>
Public Member Functions | |
MxPoint () | |
[AI] Default constructor, does not initialize coordinates. More... | |
MxPoint (const MxPoint &p_p) | |
[AI] Copy constructor. More... | |
MxPoint (T p_x, T p_y) | |
[AI] Constructor with explicit coordinates. More... | |
T | GetX () const |
[AI] Get X coordinate. More... | |
T | GetY () const |
[AI] Get Y coordinate. More... | |
void | SetX (T p_x) |
[AI] Set X coordinate. More... | |
void | SetY (T p_y) |
[AI] Set Y coordinate. More... | |
void | operator+= (const MxPoint &p_p) |
[AI] Add another point's coordinates to this point. More... | |
void | operator-= (const MxPoint &p_p) |
[AI] Subtract another point's coordinates from this point. More... | |
MxPoint | operator+ (const MxPoint &p_p) const |
[AI] Add another point, returning the result. More... | |
MxPoint | operator- (const MxPoint &p_p) const |
[AI] Subtract another point, returning the result. More... | |
Protected Attributes | |
T | m_x |
[AI] X coordinate. More... | |
T | m_y |
[AI] Y coordinate. More... | |
[AI] 2D point class templated on its coordinate type.
[AI] Represents a point in 2D space, supporting basic arithmetic and access/modification of its coordinates.
T | [AI] Underlying type for coordinates (e.g., int, float, etc.) |
Definition at line 13 of file mxgeometry.h.
[AI] Default constructor, does not initialize coordinates.
Definition at line 22 of file mxgeometry.h.
[AI] Copy constructor.
p_p | [AI] The point to copy. |
Definition at line 28 of file mxgeometry.h.
[AI] Constructor with explicit coordinates.
p_x | [AI] X coordinate. |
p_y | [AI] Y coordinate. |
Definition at line 39 of file mxgeometry.h.
|
inline |
[AI] Get X coordinate.
Definition at line 48 of file mxgeometry.h.
|
inline |
[AI] Get Y coordinate.
Definition at line 53 of file mxgeometry.h.
[AI] Add another point, returning the result.
p_p | [AI] The point to add. |
Definition at line 91 of file mxgeometry.h.
[AI] Add another point's coordinates to this point.
p_p | [AI] The point to add. |
Definition at line 71 of file mxgeometry.h.
[AI] Subtract another point, returning the result.
p_p | [AI] The point to subtract. |
Definition at line 97 of file mxgeometry.h.
[AI] Subtract another point's coordinates from this point.
p_p | [AI] The point to subtract. |
Definition at line 81 of file mxgeometry.h.
|
inline |
[AI] Set X coordinate.
p_x | [AI] The new X coordinate. |
Definition at line 59 of file mxgeometry.h.
|
inline |
[AI] Set Y coordinate.
p_y | [AI] The new Y coordinate. |
Definition at line 65 of file mxgeometry.h.
|
protected |
[AI] X coordinate.
Definition at line 15 of file mxgeometry.h.
|
protected |
[AI] Y coordinate.
Definition at line 16 of file mxgeometry.h.