|
ACF $AcfVersion:0$
|
Simple rectangle with integer bounds. More...
#include <CRect.h>
Public Member Functions | |
| CRect () | |
| CRect (const CRect &rect) | |
| CRect (int left, int top, int right, int bottom) | |
| CRect (const istd::CIndex2d &leftTop, const istd::CIndex2d &rightBottom) | |
| CRect (const istd::CIndex2d &leftTop, const ibase::CSize &size) | |
| CRect (const i2d::CRectangle &rect) | |
| CRect (const ibase::CSize &size) | |
| i2d::CRectangle | GetRectangle () const |
| istd::CIndex2d | GetLeftTop () const |
| void | SetLeftTop (istd::CIndex2d position) |
| istd::CIndex2d | GetRightTop () const |
| void | SetRightTop (istd::CIndex2d position) |
| istd::CIndex2d | GetLeftBottom () const |
| void | SetLeftBottom (istd::CIndex2d position) |
| istd::CIndex2d | GetRightBottom () const |
| void | SetRightBottom (istd::CIndex2d position) |
| int | GetLeft () const |
| void | SetLeft (int left) |
| int | GetTop () const |
| void | SetTop (int top) |
| int | GetRight () const |
| void | SetRight (int right) |
| int | GetBottom () const |
| void | SetBottom (int bottom) |
| int | GetWidth () const |
| int | GetHeight () const |
| const istd::CIntRange & | GetHorizontalRange () const |
| istd::CIntRange & | GetHorizontalRangeRef () |
| void | SetHorizontalRange (const istd::CIntRange &range) |
| const istd::CIntRange & | GetVerticalRange () const |
| istd::CIntRange & | GetVerticalRangeRef () |
| void | SetVerticalRange (const istd::CIntRange &range) |
| istd::CIndex2d | GetCenter () const |
| bool | IsValid () const |
| Check if rectangle is valid. | |
| bool | IsEmpty () const |
| Check if rectangle is empty. | |
| bool | IsValidNonEmpty () const |
Return true if the rectangle is valid and it is not empty. | |
| bool | IsNull () const |
| Check if all parameters are 0. | |
| ibase::CSize | GetSize () const |
| Get size of rectangle. | |
| bool | IsInside (const istd::CIndex2d &point) const |
| Check if specified point lies inside. | |
| bool | IsInside (const CRect &rect) const |
| Check if specified rectangle lies inside. | |
| bool | IsOutside (const CRect &rect) const |
| Check if specified rectangle lies fully outside. | |
| void | Reset () |
| Set all members to 0. | |
| void | Union (const CRect &rect) |
| Calculate union of this and second rectangle and stores result in this object. | |
| void | GetUnion (const CRect &rect, CRect &result) const |
| Get union of two rectangles. | |
| CRect | GetUnion (const CRect &rect) const |
| Get union of two rectangles. | |
| void | Union (istd::CIndex2d point) |
| Calculate union of this rectangle and point. | |
| CRect | GetUnion (istd::CIndex2d point) const |
| Get union of this rectangle and point. | |
| void | Expand (const CRect &rect) |
| Expand rectangle using second rectangle. | |
| CRect | GetExpanded (const CRect &rect) const |
| Get expanded rectangle. | |
| void | Intersection (const CRect &rect) |
| Calculate intersection of this and second rectangle and stores result in this object. | |
| CRect | GetIntersection (const CRect &rect) const |
| Get intersection of two rectangles. | |
| void | Translate (istd::CIndex2d point) |
| Move rectangle. | |
| CRect | GetTranslated (istd::CIndex2d point) const |
| Get moved rectangle. | |
| CRect & | operator= (const CRect &rect) |
| bool | operator== (const CRect &rect) const |
| bool | operator!= (const CRect &rect) const |
Static Public Member Functions | |
| static const i2d::CRect & | GetEmpty () |
| Get empty rectangle with all values set to 0. | |
| static const i2d::CRect & | GetInvalid () |
| Get invalid rectangle. | |
|
inline |
Definition at line 196 of file CRect.h.
References istd::TRange< int >::GetInvalid().
|
inline |
|
inline |
Definition at line 221 of file CRect.h.
References istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), and IsValid().
|
inline |
Definition at line 230 of file CRect.h.
References istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), and IsValid().
|
inline |
Definition at line 239 of file CRect.h.
References i2d::CRectangle::GetBottom(), i2d::CRectangle::GetLeft(), i2d::CRectangle::GetRight(), i2d::CRectangle::GetTop(), and IsValid().
|
inlineexplicit |
Definition at line 248 of file CRect.h.
References istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), and IsValid().
|
inline |
Expand rectangle using second rectangle.
Expanded rectangle is easy sum of coordinates of both rectangles.
Definition at line 569 of file CRect.h.
References istd::TRange< ValueType >::Expand(), and IsValid().
Referenced by GetExpanded().
|
inline |
Definition at line 354 of file CRect.h.
References istd::TRange< ValueType >::GetMaxValue().
Referenced by Union().
|
inline |
Definition at line 414 of file CRect.h.
References istd::TRange< ValueType >::GetLength(), and istd::TRange< ValueType >::GetMinValue().
|
inlinestatic |
|
inline |
Definition at line 372 of file CRect.h.
References istd::TRange< ValueType >::GetLength().
|
inline |
|
inline |
Get intersection of two rectangles.
Definition at line 606 of file CRect.h.
References Intersection(), and IsValid().
|
inlinestatic |
|
inline |
Definition at line 319 of file CRect.h.
References istd::TRange< ValueType >::GetMinValue().
Referenced by iimg::CScanlineMask::CalculateMaskFromBitmap(), and Union().
|
inline |
Definition at line 293 of file CRect.h.
References istd::TRange< ValueType >::GetMaxValue(), and istd::TRange< ValueType >::GetMinValue().
|
inline |
Definition at line 267 of file CRect.h.
References istd::TRange< ValueType >::GetMinValue().
|
inline |
Definition at line 257 of file CRect.h.
References istd::TRange< ValueType >::GetLength(), and istd::TRange< ValueType >::GetMinValue().
|
inline |
Definition at line 342 of file CRect.h.
References istd::TRange< ValueType >::GetMaxValue().
Referenced by iimg::CScanlineMask::CalculateMaskFromBitmap(), and Union().
|
inline |
Definition at line 306 of file CRect.h.
References istd::TRange< ValueType >::GetMaxValue().
|
inline |
Definition at line 280 of file CRect.h.
References istd::TRange< ValueType >::GetMaxValue(), and istd::TRange< ValueType >::GetMinValue().
|
inline |
Get size of rectangle.
Definition at line 446 of file CRect.h.
References istd::TRange< ValueType >::GetLength().
|
inline |
Definition at line 330 of file CRect.h.
References istd::TRange< ValueType >::GetMinValue().
Referenced by Union().
|
inline |
Get union of two rectangles.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 530 of file CRect.h.
References GetUnion(), and IsValid().
Get union of two rectangles.
Definition at line 510 of file CRect.h.
References IsEmpty(), IsValid(), Reset(), and istd::TRange< ValueType >::Unite().
Referenced by GetUnion().
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 366 of file CRect.h.
References istd::TRange< ValueType >::GetLength().
|
inline |
Calculate intersection of this and second rectangle and stores result in this object.
Definition at line 592 of file CRect.h.
References istd::TRange< ValueType >::Intersection(), IsValid(), istd::TRange< ValueType >::IsValid(), and Reset().
Referenced by GetIntersection().
|
inline |
Check if rectangle is empty.
Definition at line 428 of file CRect.h.
References istd::TRange< ValueType >::IsEmpty().
Referenced by GetUnion(), IsInside(), IsOutside(), and Union().
|
inline |
Check if specified rectangle lies inside.
Definition at line 460 of file CRect.h.
References istd::TRange< ValueType >::Contains(), IsEmpty(), and IsValid().
|
inline |
Check if specified point lies inside.
Definition at line 452 of file CRect.h.
References istd::TRange< ValueType >::Contains(), istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), and IsValid().
|
inline |
Check if all parameters are 0.
Definition at line 440 of file CRect.h.
References istd::TRange< int >::GetNull().
|
inline |
Check if specified rectangle lies fully outside.
Definition at line 474 of file CRect.h.
References IsEmpty(), istd::TRange< ValueType >::IsOutsideOf(), and IsValid().
|
inline |
Check if rectangle is valid.
Definition at line 422 of file CRect.h.
References istd::TRange< ValueType >::IsValid().
Referenced by CRect(), CRect(), CRect(), CRect(), CRect(), Expand(), GetExpanded(), GetIntersection(), GetTranslated(), GetUnion(), GetUnion(), GetUnion(), Intersection(), IsInside(), IsInside(), IsOutside(), Union(), and Union().
|
inline |
Return true if the rectangle is valid and it is not empty.
Definition at line 434 of file CRect.h.
References istd::TRange< ValueType >::IsValidNonEmpty().
|
inline |
Definition at line 655 of file CRect.h.
References operator==().
|
inline |
Definition at line 649 of file CRect.h.
Referenced by operator!=().
|
inline |
Set all members to 0.
Definition at line 488 of file CRect.h.
References istd::TRange< ValueType >::Reset().
Referenced by GetUnion(), Intersection(), and iview::CViewBase::ResetInvalidatedBox().
|
inline |
Definition at line 360 of file CRect.h.
References istd::TRange< ValueType >::SetMaxValue().
|
inline |
|
inline |
Definition at line 324 of file CRect.h.
References istd::TRange< ValueType >::SetMinValue().
|
inline |
Definition at line 299 of file CRect.h.
References istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), istd::TRange< ValueType >::SetMaxValue(), and istd::TRange< ValueType >::SetMinValue().
|
inline |
Definition at line 273 of file CRect.h.
References istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), and istd::TRange< ValueType >::SetMinValue().
|
inline |
Definition at line 348 of file CRect.h.
References istd::TRange< ValueType >::SetMaxValue().
|
inline |
Definition at line 312 of file CRect.h.
References istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), and istd::TRange< ValueType >::SetMaxValue().
|
inline |
Definition at line 286 of file CRect.h.
References istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), istd::TRange< ValueType >::SetMaxValue(), and istd::TRange< ValueType >::SetMinValue().
|
inline |
Definition at line 336 of file CRect.h.
References istd::TRange< ValueType >::SetMinValue().
|
inline |
|
inline |
Move rectangle.
Definition at line 619 of file CRect.h.
References istd::TRange< ValueType >::GetMaxValue(), istd::TRange< ValueType >::GetMinValue(), istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), istd::TRange< ValueType >::SetMaxValue(), and istd::TRange< ValueType >::SetMinValue().
Referenced by GetTranslated().
|
inline |
Calculate union of this and second rectangle and stores result in this object.
Definition at line 495 of file CRect.h.
References IsEmpty(), IsValid(), and istd::TRange< ValueType >::Unite().
Referenced by GetUnion(), and iview::CViewBase::InvalidateBox().
|
inline |
Calculate union of this rectangle and point.
Result is stored in this object.
Definition at line 543 of file CRect.h.
References GetBottom(), GetLeft(), GetRight(), GetTop(), istd::CIndex2d::GetX(), istd::CIndex2d::GetY(), and IsValid().