From 8eab00d6d707b1b3eaa1ea5bdba139985d2bb860 Mon Sep 17 00:00:00 2001 From: hikerstk Date: Thu, 10 Jun 2010 06:19:22 +0000 Subject: [PATCH] Changed the culling algorithm to use the frustum and not the camera box. This results in better culling of items, which can give a good performance benefit. git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@5494 178a84e3-b1eb-0310-8ba1-8eac791a3b58 --- src/items/item.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/items/item.cpp b/src/items/item.cpp index 090e45b0e..84464fe11 100644 --- a/src/items/item.cpp +++ b/src/items/item.cpp @@ -42,6 +42,7 @@ Item::Item(ItemType type, const Vec3& xyz, const Vec3& normal, : -1 ; m_original_mesh = mesh; m_node = irr_driver->addMesh(mesh); + m_node->setAutomaticCulling(scene::EAC_FRUSTUM_BOX); m_node->setPosition(xyz.toIrrVector()); m_node->setRotation(hpr.toIrrHPR()); m_node->grab();