#include <llsphere.h>
Public Member Functions | |
LLSphere () | |
LLSphere (const LLVector3 ¢er, F32 radius) | |
void | set (const LLVector3 ¢er, F32 radius) |
void | setCenter (const LLVector3 ¢er) |
void | setRadius (F32 radius) |
const LLVector3 & | getCenter () const |
F32 | getRadius () const |
BOOL | contains (const LLSphere &other_sphere) const |
BOOL | overlaps (const LLSphere &other_sphere) const |
F32 | getOverlap (const LLSphere &other_sphere) const |
bool | operator== (const LLSphere &rhs) const |
Static Public Member Functions | |
static void | collapse (std::vector< LLSphere > &sphere_list) |
static LLSphere | getBoundingSphere (const LLSphere &first_sphere, const LLSphere &second_sphere) |
static LLSphere | getBoundingSphere (const std::vector< LLSphere > &sphere_list) |
Protected Attributes | |
LLVector3 | mCenter |
F32 | mRadius |
Friends | |
std::ostream & | operator<< (std::ostream &output_stream, const LLSphere &line) |
Definition at line 32 of file llsphere.h.
LLSphere::LLSphere | ( | ) |
Definition at line 25 of file llsphere.cpp.
Referenced by getBoundingSphere().
Definition at line 30 of file llsphere.cpp.
Definition at line 35 of file llsphere.cpp.
References mCenter, and setRadius().
Referenced by getBoundingSphere().
void LLSphere::setCenter | ( | const LLVector3 & | center | ) |
Definition at line 41 of file llsphere.cpp.
References mCenter.
Referenced by randomize_sphere(), and LLPrimLinkInfo< DATA_TYPE >::transform().
void LLSphere::setRadius | ( | F32 | radius | ) |
Definition at line 46 of file llsphere.cpp.
References mRadius.
Referenced by randomize_sphere(), and set().
const LLVector3 & LLSphere::getCenter | ( | ) | const |
Definition at line 55 of file llsphere.cpp.
References mCenter.
Referenced by LLPrimLinkInfo< DATA_TYPE >::get_span(), LLPrimLinkInfo< DATA_TYPE >::getCenter(), and LLPrimLinkInfo< DATA_TYPE >::transform().
F32 LLSphere::getRadius | ( | ) | const |
Definition at line 60 of file llsphere.cpp.
References mRadius.
Referenced by LLPrimLinkInfo< DATA_TYPE >::canLink(), LLPrimLinkInfo< DATA_TYPE >::get_max_linkable_span(), LLPrimLinkInfo< DATA_TYPE >::get_span(), getBoundingSphere(), LLPrimLinkInfo< DATA_TYPE >::getDiameter(), and LLPrimLinkInfo< DATA_TYPE >::merge().
Definition at line 66 of file llsphere.cpp.
References FALSE, mCenter, mRadius, and TRUE.
Referenced by LLPrimLinkInfo< DATA_TYPE >::append(), and LLPrimLinkInfo< DATA_TYPE >::merge().
void LLSphere::collapse | ( | std::vector< LLSphere > & | sphere_list | ) | [static] |
Definition at line 102 of file llsphere.cpp.
LLSphere LLSphere::getBoundingSphere | ( | const LLSphere & | first_sphere, | |
const LLSphere & | second_sphere | |||
) | [static] |
Definition at line 141 of file llsphere.cpp.
References getRadius(), LLVector3::length(), llmax(), llmin(), LLSphere(), mCenter, LLVector3::normVec(), and LLVector3::setVec().
Referenced by LLPrimLinkInfo< DATA_TYPE >::computeBoundingSphere(), and getBoundingSphere().
Definition at line 174 of file llsphere.cpp.
References getBoundingSphere(), i, LLVector3::length(), llmin(), LLVector3::mV, S32, set(), VX, VY, and VZ.
bool LLSphere::operator== | ( | const LLSphere & | rhs | ) | const |
std::ostream& operator<< | ( | std::ostream & | output_stream, | |
const LLSphere & | line | |||
) | [friend] |
Definition at line 94 of file llsphere.cpp.
LLVector3 LLSphere::mCenter [protected] |
Definition at line 67 of file llsphere.h.
Referenced by contains(), getBoundingSphere(), getCenter(), getOverlap(), operator<<(), operator==(), overlaps(), set(), and setCenter().
F32 LLSphere::mRadius [protected] |
Definition at line 68 of file llsphere.h.
Referenced by contains(), getOverlap(), getRadius(), operator<<(), operator==(), overlaps(), and setRadius().