0.44.0
|
#include <iRectangle.h>
Public Member Functions | |
iRectangle ()=default | |
iRectangle (T x, T y, T width=0, T height=0) | |
iRectangle (const iRectangle< T > &rect) | |
void | adjust (T x, T y, T width, T height) |
const T | getX () const |
const T | getY () const |
const T | getWidth () const |
const T | getHeight () const |
const T | getLeft () const |
const T | getRight () const |
const T | getTop () const |
const T | getBottom () const |
const iaVector2< T > | getCenter () const |
void | setX (T x) |
void | setY (T y) |
void | setWidth (T width) |
void | setHeight (T height) |
void | setSize (T width, T height) |
void | set (T x, T y, T width, T height) |
iRectangle< T > | operator= (const iRectangle< T > &rectangle) |
Public Attributes | |
T | _x = (T)0 |
T | _y = (T)0 |
T | _width = (T)0 |
T | _height = (T)0 |
2d rectangle
|
default |
does nothing
|
inline |
ctor with parameters
x | horizontal position |
y | vertical position |
width | width |
height | height |
|
inline |
copy ctor
rect | the rectangle to copy |
void igor::iRectangle< T >::adjust | ( | T | x, |
T | y, | ||
T | width, | ||
T | height | ||
) |
adjust the size of the rectangle
x | the horizontal position adjustment |
y | the vertical position adjustment |
width | the horizontal size adjustment |
height | the vertical size adjustment |
const T igor::iRectangle< T >::getBottom | ( | ) | const |
const iaVector2< T > igor::iRectangle< T >::getCenter | ( | ) | const |
const T igor::iRectangle< T >::getHeight | ( | ) | const |
const T igor::iRectangle< T >::getLeft | ( | ) | const |
const T igor::iRectangle< T >::getRight | ( | ) | const |
const T igor::iRectangle< T >::getTop | ( | ) | const |
const T igor::iRectangle< T >::getWidth | ( | ) | const |
const T igor::iRectangle< T >::getX | ( | ) | const |
const T igor::iRectangle< T >::getY | ( | ) | const |
iRectangle< T > igor::iRectangle< T >::operator= | ( | const iRectangle< T > & | rectangle | ) |
assignment operator
rectangle | the rectangle to assign |
void igor::iRectangle< T >::set | ( | T | x, |
T | y, | ||
T | width, | ||
T | height | ||
) |
sets all values at once
x | the horizontal position |
y | the vertical position |
width | the horizontal size |
height | the vertical size |
void igor::iRectangle< T >::setHeight | ( | T | height | ) |
sets height of rectangle
height | height of rectangle |
void igor::iRectangle< T >::setSize | ( | T | width, |
T | height | ||
) |
sets width and height of rectangle
height | height of rectangle |
width | width of rectangle |
void igor::iRectangle< T >::setWidth | ( | T | width | ) |
sets width of rectangle
width | width of rectangle |
void igor::iRectangle< T >::setX | ( | T | x | ) |
sets horizontal position
x | horizontal position |
void igor::iRectangle< T >::setY | ( | T | y | ) |
sets vertical position
y | vertical position |
T igor::iRectangle< T >::_height = (T)0 |
height of rectangle
T igor::iRectangle< T >::_width = (T)0 |
height of rectangle
T igor::iRectangle< T >::_x = (T)0 |
horizontal position
T igor::iRectangle< T >::_y = (T)0 |
vertical position