Isle
Loading...
Searching...
No Matches
MxRect32 Class Reference

[AI] Rectangle using 32-bit signed integer coordinates. More...

#include <mxgeometry.h>

Inheritance diagram for MxRect32:
Collaboration diagram for MxRect32:

Public Member Functions

 MxRect32 ()
 [AI] Default constructor. More...
 
 MxRect32 (const MxRect32 &p_r)
 [AI] Copy constructor. More...
 
 MxRect32 (MxS32 p_l, MxS32 p_t, MxS32 p_r, MxS32 p_b)
 [AI] Construct from explicit coordinates. More...
 
 MxRect32 (MxPoint32 &p_p, MxSize32 &p_s)
 [AI] Construct using MxPoint32 and MxSize32. More...
 
- Public Member Functions inherited from MxRect< MxS32 >
 MxRect ()
 [AI] Default constructor, does not initialize rectangle. More...
 
 MxRect (const MxRect &p_r)
 [AI] Copy constructor. More...
 
 MxRect (MxS32 p_l, MxS32 p_t, MxS32 p_r, MxS32 p_b)
 [AI] Construct from coordinates. More...
 
 MxRect (const MxPoint< MxS32 > &p_p, const MxSize< MxS32 > &p_s)
 [AI] Construct from point and size. More...
 
MxS32 GetLeft () const
 [AI] Get the left edge. More...
 
void SetLeft (MxS32 p_left)
 [AI] Set the left edge. More...
 
MxS32 GetTop () const
 [AI] Get the top edge. More...
 
void SetTop (MxS32 p_top)
 [AI] Set the top edge. More...
 
MxS32 GetRight () const
 [AI] Get the right edge. More...
 
void SetRight (MxS32 p_right)
 [AI] Set the right edge. More...
 
MxS32 GetBottom () const
 [AI] Get the bottom edge. More...
 
void SetBottom (MxS32 p_bottom)
 [AI] Set the bottom edge. More...
 
MxS32 GetWidth () const
 [AI] Get the rectangle's width. More...
 
MxS32 GetHeight () const
 [AI] Get the rectangle's height. More...
 
MxPoint< MxS32GetLT () const
 [AI] Get the top-left point of the rectangle. More...
 
MxPoint< MxS32GetRB () const
 [AI] Get the bottom-right point of the rectangle. More...
 
MxBool Empty () const
 [AI] Returns whether the rectangle is empty or not. More...
 
MxBool Contains (const MxPoint< MxS32 > &p_p) const
 [AI] Test whether a point is inside the rectangle (inclusive). More...
 
MxBool Intersects (const MxRect &p_r) const
 [AI] Returns whether this rectangle intersects another. More...
 
void operator= (const MxRect &p_r)
 [AI] Assignment operator. More...
 
MxBool operator== (const MxRect &p_r) const
 [AI] Equality operator. More...
 
MxBool operator!= (const MxRect &p_r) const
 [AI] Inequality operator. More...
 
void operator+= (const MxPoint< MxS32 > &p_p)
 [AI] Translate the rectangle by a point, in-place. More...
 
void operator-= (const MxPoint< MxS32 > &p_p)
 [AI] Translate the rectangle by the negative of a point, in-place. More...
 
void operator&= (const MxRect &p_r)
 [AI] Intersect rectangle in-place with another. More...
 
void operator|= (const MxRect &p_r)
 [AI] Unites this rectangle with another in-place. More...
 
MxRect operator+ (const MxPoint< MxS32 > &p_p) const
 [AI] Returns a translated rectangle. More...
 
MxRect operator- (const MxPoint< MxS32 > &p_p) const
 [AI] Returns a translated rectangle (by negative). More...
 
MxRect operator& (const MxRect &p_r) const
 [AI] Returns the intersection of this rectangle and another. More...
 
MxRect operator| (const MxRect &p_r) const
 [AI] Returns the bounding rectangle (union) of this and another. More...
 

Additional Inherited Members

- Protected Attributes inherited from MxRect< MxS32 >
MxS32 m_left
 [AI] Left edge (minimum x). More...
 
MxS32 m_top
 [AI] Top edge (minimum y). More...
 
MxS32 m_right
 [AI] Right edge (maximum x). More...
 
MxS32 m_bottom
 [AI] Bottom edge (maximum y). More...
 

Detailed Description

[AI] Rectangle using 32-bit signed integer coordinates.

[AI] Used for describing large regions of space or layers in the engine.

Definition at line 706 of file mxgeometry.h.

Constructor & Destructor Documentation

◆ MxRect32() [1/4]

MxRect32::MxRect32 ( )
inline

[AI] Default constructor.

Definition at line 711 of file mxgeometry.h.

◆ MxRect32() [2/4]

MxRect32::MxRect32 ( const MxRect32 p_r)
inline

[AI] Copy constructor.

Parameters
p_r[AI] Rectangle to copy.

Definition at line 717 of file mxgeometry.h.

◆ MxRect32() [3/4]

MxRect32::MxRect32 ( MxS32  p_l,
MxS32  p_t,
MxS32  p_r,
MxS32  p_b 
)
inline

[AI] Construct from explicit coordinates.

Parameters
p_l[AI] Left coordinate.
p_t[AI] Top coordinate.
p_r[AI] Right coordinate.
p_b[AI] Bottom coordinate.

Definition at line 726 of file mxgeometry.h.

◆ MxRect32() [4/4]

MxRect32::MxRect32 ( MxPoint32 p_p,
MxSize32 p_s 
)
inline

[AI] Construct using MxPoint32 and MxSize32.

Parameters
p_p[AI] Top-left point.
p_s[AI] Size.

Definition at line 734 of file mxgeometry.h.


The documentation for this class was generated from the following file: