#include "FrustumCullingManager.h" #include namespace GtpVisibility { //----------------------------------------------------------------------- void FrustumCullingManager::RenderScene() { //InitFrame(); while (!mHierarchyInterface->GetQueue()->empty()) { HierarchyNode *node = mHierarchyInterface->GetQueue()->top(); mHierarchyInterface->GetQueue()->pop(); // interesting for visualization purpose mHierarchyInterface->SetNodeVisible(node, false); mHierarchyInterface->SetLastVisited(node, mHierarchyInterface->GetFrameId()); if (!mHierarchyInterface->CheckFrustumVisible(node)) {//if (mHierarchyInterface->mIsShadowPass) mNumFrustumCulledNodes ++; if (mVisualizeCulledNodes) { mHierarchyInterface->VisualizeCulledNode(node, FRUSTUM_CULLED); } } else { mHierarchyInterface->SetNodeVisible(node, true); mHierarchyInterface->TraverseNode(node); } } } } // namespace GtpVisibility