Floating-point rectangle class. More...
Public Member Functions | |
| PosRectangle (T l=0, T t=0, T r=0, T b=0) | |
| PosRectangle (Point2D< T > tl, Point2D< T > br) | |
| bool | isOutside (const Point2D< T > &p, T eps) const |
| bool | isInside (const Point2D< T > &, T eps) const |
| bool | isOnSide (const Point2D< T > &p, T eps) const |
| bool | contains (const Point2D< T > &p, T eps) const |
| bool | contains (const PosRectangle< T > &other, T eps) const |
| bool | isInside (const PosRectangle< T > &other, T eps) const |
| PosRectangle< T > | grownBy (T sidesincreasebyfactor=1) const |
Protected Member Functions | |
| bool | xOutside (T, T) const |
| bool | yOutside (T, T) const |
Floating-point rectangle class.
The difference with the integer type rectangle is in range handling. In the float world, everything must be epsiloned. with inside and outside.
| Geom::PosRectangle< T >::PosRectangle | ( | T | l = 0, |
|
| T | t = 0, |
|||
| T | r = 0, |
|||
| T | b = 0 | |||
| ) | [inline] |
| Geom::PosRectangle< T >::PosRectangle | ( | Point2D< T > | tl, | |
| Point2D< T > | br | |||
| ) | [inline] |
| bool Geom::PosRectangle< T >::contains | ( | const Point2D< T > & | p, | |
| T | eps | |||
| ) | const [inline] |
| bool Geom::PosRectangle< T >::contains | ( | const PosRectangle< T > & | other, | |
| T | eps | |||
| ) | const [inline] |
| PosRectangle< T > Geom::PosRectangle< T >::grownBy | ( | T | sidesincreasebyfactor = 1 |
) | const [inline] |
| bool Geom::PosRectangle< T >::isInside | ( | const Point2D< T > & | pt, | |
| T | eps | |||
| ) | const [inline] |
| bool Geom::PosRectangle< T >::isInside | ( | const PosRectangle< T > & | other, | |
| T | eps | |||
| ) | const [inline] |
| bool Geom::PosRectangle< T >::isOnSide | ( | const Point2D< T > & | p, | |
| T | eps | |||
| ) | const [inline] |
| bool Geom::PosRectangle< T >::isOutside | ( | const Point2D< T > & | p, | |
| T | eps | |||
| ) | const [inline] |
| bool Geom::PosRectangle< T >::xOutside | ( | T | x, | |
| T | eps | |||
| ) | const [inline, protected] |
| bool Geom::PosRectangle< T >::yOutside | ( | T | y, | |
| T | eps | |||
| ) | const [inline, protected] |
1.7.1