VOID DebugDraw::DrawBound( const Bound& bound, D3DCOLOR Color ) { switch( bound.GetType() ) { case Bound::Sphere_Bound: DrawSphere( bound.GetSphere(), Color ); return; case Bound::Frustum_Bound: DrawFrustum( bound.GetFrustum(), Color ); return; case Bound::AABB_Bound: DrawAabb( bound.GetAabb(), Color ); return; case Bound::OBB_Bound: DrawObb( bound.GetObb(), Color ); return; } }
//----------------------------------------------------------------------------- // Name: Bound::Collide // Desc: collides this bound with another bound //----------------------------------------------------------------------------- BOOL Bound::Collide( const Bound& Other ) const { switch( Other.m_Type ) { case Bound::Sphere_Bound: return Collide( Other.GetSphere() ); case Bound::Frustum_Bound: return Collide( Other.GetFrustum() ); case Bound::OBB_Bound: return Collide( Other.GetObb() ); case Bound::AABB_Bound: return Collide( Other.GetAabb() ); case Bound::No_Bound: return TRUE; } return FALSE; }