From ddea4e11d1f1a22aacd43de50e8249614c6ffd29 Mon Sep 17 00:00:00 2001 From: Seth Hillbrand Date: Thu, 11 Oct 2018 05:11:53 -0700 Subject: [PATCH] 3d-viewer: Fix intersection bug Bounding box check always returned false, leading to incorrect BBox checks when one bbox is interior to the other --- .../3d_render_raytracing/shapes2D/croundsegment2d.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/3d-viewer/3d_rendering/3d_render_raytracing/shapes2D/croundsegment2d.cpp b/3d-viewer/3d_rendering/3d_render_raytracing/shapes2D/croundsegment2d.cpp index f8aad7228b..bb1de266c7 100644 --- a/3d-viewer/3d_rendering/3d_render_raytracing/shapes2D/croundsegment2d.cpp +++ b/3d-viewer/3d_rendering/3d_render_raytracing/shapes2D/croundsegment2d.cpp @@ -76,7 +76,7 @@ bool CROUNDSEGMENT2D::Intersects( const CBBOX2D &aBBox ) const return false; if( (aBBox.Max().x > m_bbox.Max().x) && - (aBBox.Max().y > m_bbox.Max().x) && + (aBBox.Max().y > m_bbox.Max().y) && (aBBox.Min().x < m_bbox.Min().x) && (aBBox.Min().y < m_bbox.Min().y) )