]> git.mxchange.org Git - simgear.git/blobdiff - simgear/scene/bvh/BVHSubTreeCollector.cxx
Fixes for headless mode.
[simgear.git] / simgear / scene / bvh / BVHSubTreeCollector.cxx
index 1e3484ece3990644d20ca549acd1ad8bf5590fb2..5c8a915ce431c989366976cac03cd39da6c904de 100644 (file)
@@ -18,6 +18,7 @@
 #include "BVHSubTreeCollector.hxx"
 
 #include <simgear/math/SGGeometry.hxx>
+#include <cassert>
 
 #include "BVHNode.hxx"
 #include "BVHGroup.hxx"
@@ -183,7 +184,7 @@ void
 BVHSubTreeCollector::apply(const BVHStaticTriangle& node,
                            const BVHStaticData& data)
 {
-    if (!intersects(_sphere, node.computeBoundingBox(data)))
+    if (!intersects(_sphere, node.getTriangle(data)))
         return;
     _staticNode = &node;
 }