Extension class with functions for quick line & point drawing.
 
Defines an axis aligned bounding box.
 
SLfloat rectCoverageInSS()
Calculates the bounding rectangle in screen space and returns coverage in SS.
 
SLGLVertexArrayExt _vao
Vertex array object for rendering.
 
void generateVAO()
Generates the vertex buffer for the line visualization.
 
SLVec3f _centerOS
Center of AABB in object space.
 
void reset()
Resets initial state without contents.
 
SLVec3f _minOS
Min. corner in object space.
 
void minOS(const SLVec3f &minC)
 
SLVec3f _axisZWS
World space z-axis vector.
 
SLfloat _radiusWS
Radius of sphere around AABB in WS.
 
void mergeWS(SLAABBox &bb)
Merges the bounding box bb to this one by extending this one axis aligned.
 
SLVec3f _parent0WS
World space vector to the parent position.
 
SLbool isHitInWS(SLRay *ray)
SLAABBox::isHitInWS: Ray - AABB Intersection Test in world space.
 
SLRectf _rectSS
Bounding rectangle in screen space.
 
SLVec3f _maxWS
Max. corner in world space.
 
SLVec3f _axisXWS
World space x-axis vector.
 
SLAABBox()
Default constructor with default zero vector initialization.
 
void fromOStoWS(const SLVec3f &minOS, const SLVec3f &maxOS, const SLMat4f &wm)
Recalculate min and max after transformation in world coords.
 
void calculateRectSS()
Calculates the AABBs min. and max. corners in screen space.
 
SLVec3f _maxOS
Max. corner in object space.
 
SLfloat _sqrViewDist
Squared dist. from center to viewpoint.
 
SLVec3f _axisYWS
World space y-axis vector.
 
void isVisible(SLbool visible)
 
SLVec3f _centerWS
Center of AABB in world space.
 
void minWS(const SLVec3f &minC)
 
void drawAxisWS()
Draws the axis in world space with lines in a color.
 
SLVec3f _axis0WS
World space axis center point.
 
SLfloat _radiusOS
Radius of sphere around AABB in OS.
 
void sqrViewDist(SLfloat sqrVD)
 
void drawWS(const SLCol4f &color)
Draws the AABB in world space with lines in a color.
 
void fromWStoOS(const SLVec3f &minWS, const SLVec3f &maxWS, const SLMat4f &wmI)
Recalculate min and max before transformation in object coords.
 
void maxWS(const SLVec3f &maxC)
 
void updateAxisWS(const SLMat4f &wm)
Updates the axis of the owning node.
 
void updateBoneWS(const SLMat4f &parentWM, SLbool isRoot, const SLMat4f &nodeWM)
Updates joints axis and the bone line from the parent to us.
 
SLbool _boneIsOffset
Flag if the connection parent to us is a bone or an offset.
 
void drawBoneWS()
Draws the joint axis and the parent bone in world space.
 
SLbool isHitInOS(SLRay *ray)
SLAABBox::isHitInWS: Ray - AABB Intersection Test in object space.
 
SLbool _isVisible
Flag if AABB is in the view frustum.
 
void setCenterAndRadiusWS()
Calculates center & radius of the bounding sphere around the AABB.
 
SLVec3f _minWS
Min. corner in world space.
 
void maxOS(const SLVec3f &maxC)
 
SLGLVertexArray adds Helper Functions for quick Line & Point Drawing.
 
Ray class with ray and intersection properties.