xoreos
0.0.5
|
A class able to sort objects by distance to a target object. More...
#include <objectcontainer.h>
Public Member Functions | |
ObjectDistanceSort (const Sonic::Object &target) | |
bool | operator() (Sonic::Object *a, Sonic::Object *b) |
Private Member Functions | |
float | getDistance (Sonic::Object &a) |
Private Attributes | |
float | xt |
float | yt |
float | zt |
A class able to sort objects by distance to a target object.
Definition at line 47 of file objectcontainer.h.
Engines::Sonic::ObjectDistanceSort::ObjectDistanceSort | ( | const Sonic::Object & | target | ) |
Definition at line 38 of file objectcontainer.cpp.
References Engines::Sonic::Object::getPosition(), xt, yt, and zt.
|
private |
Definition at line 46 of file objectcontainer.cpp.
References ABS(), Engines::Sonic::Object::getPosition(), xt, yt, and zt.
Referenced by operator()().
bool Engines::Sonic::ObjectDistanceSort::operator() | ( | Sonic::Object * | a, |
Sonic::Object * | b | ||
) |
Definition at line 42 of file objectcontainer.cpp.
References getDistance().
|
private |
Definition at line 54 of file objectcontainer.h.
Referenced by getDistance(), and ObjectDistanceSort().
|
private |
Definition at line 54 of file objectcontainer.h.
Referenced by getDistance(), and ObjectDistanceSort().
|
private |
Definition at line 54 of file objectcontainer.h.
Referenced by getDistance(), and ObjectDistanceSort().