Team Fortress 2 Source Code as on 22/4/2020
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose:
//
// $Workfile: $
// $Date: $
//
//-----------------------------------------------------------------------------
// $Log: $
//
// $NoKeywords: $
//=============================================================================//
#pragma once
#include "BoundBox.h"
#include "MapClass.h"
class CCullTreeNode;
class CCullTreeNode : public BoundBox { public:
CCullTreeNode(void); ~CCullTreeNode(void);
//
// Children.
//
inline int GetChildCount(void) { return(m_Children.Count()); } inline CCullTreeNode *GetCullTreeChild(int nChild) { return(m_Children[nChild]); }
void AddCullTreeChild(CCullTreeNode *pChild); //
// Objects.
//
inline int GetObjectCount(void) { return(m_Objects.Count()); } inline CMapClass *GetCullTreeObject(int nObject) { return(m_Objects[nObject]); }
void AddCullTreeObject(CMapClass *pObject); void AddCullTreeObjectRecurse(CMapClass *pObject);
CCullTreeNode *FindCullTreeObjectRecurse(CMapClass *pObject);
void RemoveAllCullTreeObjects(void); void RemoveAllCullTreeObjectsRecurse(void);
void RemoveCullTreeObject(CMapClass *pObject); void RemoveCullTreeObjectRecurse(CMapClass *pObject);
void UpdateAllCullTreeObjects(void); void UpdateAllCullTreeObjectsRecurse(void);
void UpdateCullTreeObject(CMapClass *pObject); void UpdateCullTreeObjectRecurse(CMapClass *pObject);
protected:
CUtlVector<CCullTreeNode*> m_Children; // The child nodes. This is an octree.
CMapObjectList m_Objects; // The objects contained in this node.
};
|