Cycles: Remove unused SAH from BVH pack
authorSergey Sharybin <sergey.vfx@gmail.com>
Mon, 11 Apr 2016 14:18:33 +0000 (16:18 +0200)
committerSergey Sharybin <sergey.vfx@gmail.com>
Mon, 11 Apr 2016 15:18:14 +0000 (17:18 +0200)
intern/cycles/bvh/bvh.cpp
intern/cycles/bvh/bvh.h

index b1273d64098b23c57a7717afad22bc0cebe696f8..9e63485c04ec8e0f2f2029f6ff01c0973e13f6c4 100644 (file)
@@ -89,15 +89,6 @@ void BVH::build(Progress& progress)
                return;
        }
 
-       /* compute SAH */
-       if(!params.top_level)
-               pack.SAH = root->computeSubtreeSAHCost(params);
-
-       if(progress.get_cancel()) {
-               root->deleteSubtree();
-               return;
-       }
-
        /* pack triangles */
        progress.set_substatus("Packing BVH triangles and strands");
        pack_primitives();
index 4b9f1bae80125865dbb9574801b216c46b253e6a..6076c25ca3128e635bd4c586a8aebcc8c3c62811 100644 (file)
@@ -67,13 +67,9 @@ struct PackedBVH {
        /* index of the root node. */
        int root_index;
 
-       /* surface area heuristic, for building top level BVH */
-       float SAH;
-
        PackedBVH()
        {
                root_index = 0;
-               SAH = 0.0f;
        }
 };