CS::SubRectangles::SubRectangles::SubRect Class Reference
Sub-rectangle. More...
#include <csgeom/subrec.h>
Protected Member Functions | |
| SubRect * | Alloc (int w, int h, const AllocInfo &ai, csRect &r) |
| Do the actual allocation. | |
| void | DecideBestSplit (const csRect &rect, int splitX, int splitY, SubRect::SplitType &splitType) |
| Decide whether a H or V split is better. | |
| const csRect & | GetAllocedRect () const |
| Return the area allocated from this subrectangle. | |
| const csRect & | GetRect () const |
| Return the area this subrectangle covers. | |
| bool | IsEmpty () const |
| Test if allocated area is empty. | |
| void | MakeEmpty () |
| Clear allocated area. | |
| void | Reclaim () |
| De-allocate. | |
| void | TestAlloc (int w, int h, AllocInfo &ai) |
| searches for the "ideal" position of a rectangle | |
| void | TestCollapse () |
| Test whether both children are empty. | |
Friends | |
| class | csBlockAllocator< SubRect > |
Detailed Description
Sub-rectangle.Definition at line 54 of file subrec.h.
Member Function Documentation
| SubRect* CS::SubRectangles::SubRectangles::SubRect::Alloc | ( | int | w, | |
| int | h, | |||
| const AllocInfo & | ai, | |||
| csRect & | r | |||
| ) | [protected] |
Do the actual allocation.
| void CS::SubRectangles::SubRectangles::SubRect::DecideBestSplit | ( | const csRect & | rect, | |
| int | splitX, | |||
| int | splitY, | |||
| SubRect::SplitType & | splitType | |||
| ) | [protected] |
Decide whether a H or V split is better.
The better split is the one where the bigger chunk results.
| const csRect& CS::SubRectangles::SubRectangles::SubRect::GetAllocedRect | ( | ) | const [inline, protected] |
| const csRect& CS::SubRectangles::SubRectangles::SubRect::GetRect | ( | ) | const [inline, protected] |
| bool CS::SubRectangles::SubRectangles::SubRect::IsEmpty | ( | ) | const [inline, protected] |
| void CS::SubRectangles::SubRectangles::SubRect::MakeEmpty | ( | ) | [inline, protected] |
| void CS::SubRectangles::SubRectangles::SubRect::Reclaim | ( | ) | [protected] |
De-allocate.
| void CS::SubRectangles::SubRectangles::SubRect::TestAlloc | ( | int | w, | |
| int | h, | |||
| AllocInfo & | ai | |||
| ) | [protected] |
searches for the "ideal" position of a rectangle
| void CS::SubRectangles::SubRectangles::SubRect::TestCollapse | ( | ) | [protected] |
Test whether both children are empty.
The documentation for this class was generated from the following file:
- csgeom/subrec.h
Generated for Crystal Space 1.4.0 by doxygen 1.5.8
