#include <Geometry.h>
Public Member Functions | |
| kt_bool | Contains (const Rectangle2< T > &rOther) |
| T | GetBottom () const |
| Vector2< T > | GetBottomLeft () |
| Vector2< T > | GetBottomRight () |
| const Vector2< T > | GetCenter () const |
| T | GetHeight () const |
| T | GetLeft () const |
| const Vector2< T > & | GetPosition () const |
| T | GetRight () const |
| const Size2< T > & | GetSize () const |
| T | GetTop () const |
| Vector2< T > | GetTopLeft () |
| Vector2< T > | GetTopRight () |
| T | GetWidth () const |
| T | GetX () const |
| T | GetY () const |
| kt_bool | operator!= (const Rectangle2 &rOther) const |
| Rectangle2 & | operator= (const Rectangle2 &rOther) |
| kt_bool | operator== (const Rectangle2 &rOther) const |
| Rectangle2 () | |
| Rectangle2 (T x, T y, T width, T height) | |
| Rectangle2 (const Vector2< T > &rPosition, const Size2< T > &rSize) | |
| Rectangle2 (const Vector2< T > &rTopLeft, const Vector2< T > &rBottomRight) | |
| Rectangle2 (const Rectangle2 &rOther) | |
| void | SetBottom (const T &rBottom) |
| void | SetHeight (const T &rHeight) |
| void | SetLeft (const T &rLeft) |
| void | SetPosition (const T &rX, const T &rY) |
| void | SetPosition (const Vector2< T > &rPosition) |
| void | SetRight (const T &rRight) |
| void | SetSize (const Size2< T > &rSize) |
| void | SetTop (const T &rTop) |
| void | SetWidth (const T &rWidth) |
| void | SetX (const T &rX) |
| void | SetY (const T &rY) |
Private Attributes | |
| Vector2< T > | m_Position |
| Size2< T > | m_Size |
Stores x, y, width and height that represents the location and size of a rectangle. Note that (x, y) is at bottom-left in the mapper!
Definition at line 1798 of file Geometry.h.
|
inline |
Rectangle with all parameters set to 0
Definition at line 1804 of file Geometry.h.
|
inline |
Rectangle with given parameters
| x | x-coordinate of left edge of rectangle |
| y | y-coordinate of bottom edge of rectangle |
| width | width of rectangle |
| height | height of rectangle |
Definition at line 1815 of file Geometry.h.
|
inline |
Rectangle with given position and size
| rPosition | (x,y)-coordinate of rectangle |
| rSize | size of the rectangle |
Definition at line 1826 of file Geometry.h.
|
inline |
Rectangle with given top-left and bottom-right coordinates
| rTopLeft | top-left (x,y)-coordinate of rectangle |
| rBottomRight | bottom-right (x,y)-coordinate of rectangle |
Definition at line 1837 of file Geometry.h.
|
inline |
Copy constructor
Definition at line 1846 of file Geometry.h.
|
inline |
Whether this rectangle contains the given rectangle
| rOther | rectangle |
Definition at line 2093 of file Geometry.h.
|
inline |
Get the bottom coordinate of this rectangle
Definition at line 2029 of file Geometry.h.
|
inline |
Get the bottom-left coordinate of this rectangle
Definition at line 2065 of file Geometry.h.
|
inline |
Get the bottom-right coordinate of this rectangle
Definition at line 2074 of file Geometry.h.
|
inline |
Gets the center of this rectangle
Definition at line 2083 of file Geometry.h.
|
inline |
Gets the height of this rectangle
Definition at line 1911 of file Geometry.h.
|
inline |
Get the left coordinate of this rectangle
Definition at line 1975 of file Geometry.h.
|
inline |
Gets the position of this rectangle
Definition at line 1929 of file Geometry.h.
|
inline |
Get the right coordinate of this rectangle
Definition at line 2011 of file Geometry.h.
|
inline |
Gets the size of this rectangle
Definition at line 1957 of file Geometry.h.
|
inline |
Get the top coordinate of this rectangle
Definition at line 1993 of file Geometry.h.
|
inline |
Get the top-left coordinate of this rectangle
Definition at line 2047 of file Geometry.h.
|
inline |
Get the top-right coordinate of this rectangle
Definition at line 2056 of file Geometry.h.
|
inline |
Gets the width of this rectangle
Definition at line 1893 of file Geometry.h.
|
inline |
Gets the x-coordinate of the left edge of this rectangle
Definition at line 1857 of file Geometry.h.
|
inline |
Gets the y-coordinate of the bottom edge of this rectangle
Definition at line 1875 of file Geometry.h.
|
inline |
Inequality operator
Definition at line 2163 of file Geometry.h.
|
inline |
Assignment operator
Definition at line 2144 of file Geometry.h.
|
inline |
Equality operator
Definition at line 2155 of file Geometry.h.
|
inline |
Set the bottom coordinate of this rectangle param rBottom new bottom coordinate of this rectangle
Definition at line 2038 of file Geometry.h.
|
inline |
Sets the height of this rectangle
| rHeight | new height |
Definition at line 1920 of file Geometry.h.
|
inline |
Set the left coordinate of this rectangle param rLeft new left coordinate of this rectangle
Definition at line 1984 of file Geometry.h.
|
inline |
Sets the position of this rectangle
| rX | new x position |
| rY | new y position |
Definition at line 1939 of file Geometry.h.
|
inline |
Sets the position of this rectangle
| rPosition | new position |
Definition at line 1948 of file Geometry.h.
|
inline |
Set the right coordinate of this rectangle param rRight new right coordinate of this rectangle
Definition at line 2020 of file Geometry.h.
|
inline |
Sets the size of this rectangle
| rSize | new size |
Definition at line 1966 of file Geometry.h.
|
inline |
Set the top coordinate of this rectangle param rTop new top coordinate of this rectangle
Definition at line 2002 of file Geometry.h.
|
inline |
Sets the width of this rectangle
| rWidth | new width |
Definition at line 1902 of file Geometry.h.
|
inline |
Sets the x-coordinate of the left edge of this rectangle
| rX | new x-coordinate for the left edge |
Definition at line 1866 of file Geometry.h.
|
inline |
Sets the y-coordinate of the bottom edge of this rectangle
| rY | new y-coordinate for the bottom edge |
Definition at line 1884 of file Geometry.h.
|
private |
Definition at line 2169 of file Geometry.h.
|
private |
Definition at line 2170 of file Geometry.h.