|
|
PDS_JP2
|
#include <Dimensions.hh>


Public Member Functions | |
| Rectangle () | |
| Constructs an empty rectangle. | |
| Rectangle (const Point_2D &position, const Size_2D &size) | |
| Constructs a rectangle from a position and a size. | |
| Rectangle (const Size_2D &size) | |
| Constructs a rectangle from a size at position 0,0. | |
| Rectangle (const int x, const int y, const unsigned int width=0, const unsigned int height=0) | |
| Constructs a rectangle from an x,y position and width,height size. | |
| Rectangle (const Rectangle &rectangle) | |
| Constructs a rectangle as a copy of another rectangle. | |
| Rectangle & | operator= (const Rectangle &rectangle) |
| Assign the position and size of another rectangle to this rectangle. | |
| Point_2D | position () const |
| Get the rectangle position. | |
| Rectangle & | position (const Point_2D &point) |
| Set the position of the rectangle. | |
| Rectangle & | position (const int x, const int y) |
| Set the x,y position of the rectangle. | |
| Size_2D | size () const |
| Get the rectangle size. | |
| Rectangle & | size (const Size_2D &size) |
| Set the size of the rectangle. | |
| Rectangle & | size (const unsigned int width, const unsigned int height) |
| Set the width,height of the rectangle. | |
| Rectangle & | operator &= (const Rectangle &rectangle) |
| Take the intersection with another rectangle. | |
| Rectangle | ( | ) |
Constructs an empty rectangle.
The position is 0,0 and the size is 0,0.
| Rectangle | ( | const int | x, | |
| const int | y, | |||
| const unsigned int | width = 0, |
|||
| const unsigned int | height = 0 | |||
| ) |
Constructs a rectangle from an x,y position and width,height size.
| x | The horizontal (x-axis) position. | |
| y | The vertical (y-axis) position. | |
| width | The width of the rectangle size. | |
| height | The height of the recangle size. |
Constructs a rectangle as a copy of another rectangle.
| rectangle | A Rectangle to be copied. |
| Point_2D position | ( | ) | const [inline] |
Get the rectangle position.
| Rectangle& position | ( | const int | x, | |
| const int | y | |||
| ) | [inline] |
Set the x,y position of the rectangle.
| x | The horizontal (x-axis) position. | |
| y | The vertical (y-axis) position. |
| Size_2D size | ( | ) | const [inline] |
Get the rectangle size.
| Rectangle& size | ( | const unsigned int | width, | |
| const unsigned int | height | |||
| ) | [inline] |
Set the width,height of the rectangle.
| width | The width of the rectangle size. | |
| height | The height of the recangle size. |
Take the intersection with another rectangle.
1.5.3