#include <Space.h>
Classes | |
struct | HashData |
Hash parameters structure. More... | |
struct | QuadData |
Quad parameters structure. More... | |
struct | SimpleData |
struct | SweepAndPruneData |
'Sweep and prune' parameters structure. More... | |
Public Types | |
enum | ESpaceType { SIMPLE, HASH, QUAD, SWEEP_AND_PRUNE } |
enum | ESAPAxesOrder { SAP_AXES_XYZ = dSAP_AXES_XYZ, SAP_AXES_XZY = dSAP_AXES_XZY, SAP_AXES_YXZ = dSAP_AXES_YXZ, SAP_AXES_YZX = dSAP_AXES_YZX, SAP_AXES_ZXY = dSAP_AXES_ZXY, SAP_AXES_ZYX = dSAP_AXES_ZYX } |
'Sweep and prune' axis order. More... | |
Public Member Functions | |
SpaceTypeInfo (ESpaceType type=SIMPLE) | |
Builds a space with all parameters set to default. | |
ESpaceType | getType () const |
Returns the type of the space. | |
void | setType (ESpaceType type) |
HashData & | getHashData () |
Returns the parameters for a hash space. | |
const HashData & | getHashData () const |
QuadData & | getQuadData () |
Returns the parameters for a quad space. | |
const QuadData & | getQuadData () const |
SweepAndPruneData & | getSweepAndPruneData () |
Returns the parameters for a 'sweep and prune' space. | |
const SweepAndPruneData & | getSweepAndPruneData () const |
void | setTypeSimple () |
HashData & | setTypeHash () |
QuadData & | setTypeQuad () |
SweepAndPruneData & | setTypeSweepAndPrune () |
Protected Attributes | |
ESpaceType | type |
Type of the space. Could be deduced from data (of boost::variant type), but preferably stored in the class. | |
boost::variant< HashData, QuadData, SweepAndPruneData, SimpleData > | data |
Empty structure, similar to void for our use. |
Definition at line 78 of file Space.h.
Physics::SpaceTypeInfo::SpaceTypeInfo | ( | ESpaceType | type = SIMPLE |
) | [inline] |
const HashData& Physics::SpaceTypeInfo::getHashData | ( | ) | const [inline] |
HashData& Physics::SpaceTypeInfo::getHashData | ( | ) | [inline] |
Returns the parameters for a hash space.
Definition at line 124 of file Space.h.
References ASSERT, data, HASH, and type.
Referenced by Physics::Space::init(), and setTypeHash().
const QuadData& Physics::SpaceTypeInfo::getQuadData | ( | ) | const [inline] |
QuadData& Physics::SpaceTypeInfo::getQuadData | ( | ) | [inline] |
Returns the parameters for a quad space.
Definition at line 128 of file Space.h.
References ASSERT, data, QUAD, and type.
Referenced by Physics::Space::init(), and setTypeQuad().
const SweepAndPruneData& Physics::SpaceTypeInfo::getSweepAndPruneData | ( | ) | const [inline] |
SweepAndPruneData& Physics::SpaceTypeInfo::getSweepAndPruneData | ( | ) | [inline] |
Returns the parameters for a 'sweep and prune' space.
Definition at line 132 of file Space.h.
References ASSERT, data, SWEEP_AND_PRUNE, and type.
Referenced by Physics::Space::init(), and setTypeSweepAndPrune().
ESpaceType Physics::SpaceTypeInfo::getType | ( | ) | const [inline] |
Returns the type of the space.
Definition at line 86 of file Space.h.
References type.
Referenced by Physics::Space::init().
void Physics::SpaceTypeInfo::setType | ( | ESpaceType | type | ) | [inline] |
Definition at line 88 of file Space.h.
References HASH, QUAD, setTypeHash(), setTypeQuad(), setTypeSimple(), setTypeSweepAndPrune(), SIMPLE, and SWEEP_AND_PRUNE.
Referenced by SpaceTypeInfo().
HashData& Physics::SpaceTypeInfo::setTypeHash | ( | ) | [inline] |
Definition at line 142 of file Space.h.
References data, getHashData(), HASH, Physics::SpaceTypeInfo::HashData::maxLevel, Physics::SpaceTypeInfo::HashData::minLevel, and type.
Referenced by setType().
QuadData& Physics::SpaceTypeInfo::setTypeQuad | ( | ) | [inline] |
Definition at line 152 of file Space.h.
References Physics::SpaceTypeInfo::QuadData::center, data, getQuadData(), Physics::SpaceTypeInfo::QuadData::level, QUAD, type, and Physics::SpaceTypeInfo::QuadData::worldBox.
Referenced by setType().
void Physics::SpaceTypeInfo::setTypeSimple | ( | ) | [inline] |
SweepAndPruneData& Physics::SpaceTypeInfo::setTypeSweepAndPrune | ( | ) | [inline] |
Definition at line 163 of file Space.h.
References Physics::SpaceTypeInfo::SweepAndPruneData::axisOrder, data, getSweepAndPruneData(), SAP_AXES_XYZ, SWEEP_AND_PRUNE, and type.
Referenced by setType().
boost::variant<HashData, QuadData, SweepAndPruneData, SimpleData> Physics::SpaceTypeInfo::data [protected] |
Empty structure, similar to void for our use.
Definition at line 178 of file Space.h.
Referenced by getHashData(), getQuadData(), getSweepAndPruneData(), setTypeHash(), setTypeQuad(), setTypeSimple(), and setTypeSweepAndPrune().
ESpaceType Physics::SpaceTypeInfo::type [protected] |
Type of the space. Could be deduced from data (of boost::variant type), but preferably stored in the class.
Definition at line 173 of file Space.h.
Referenced by getHashData(), getQuadData(), getSweepAndPruneData(), getType(), setTypeHash(), setTypeQuad(), setTypeSimple(), setTypeSweepAndPrune(), and SpaceTypeInfo().