From c59d30febbfdef450fec6775ebc8098b9829bbea Mon Sep 17 00:00:00 2001 From: Tim Moore Date: Sun, 15 Feb 2009 01:55:21 +0100 Subject: [PATCH] Fix off-by-one problem in new ground intersection code --- src/FDM/groundcache.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/FDM/groundcache.cxx b/src/FDM/groundcache.cxx index b1cd2947c..fd1893065 100644 --- a/src/FDM/groundcache.cxx +++ b/src/FDM/groundcache.cxx @@ -382,7 +382,7 @@ void FGGroundCache::getWireIntersectorResults(WireIntersector* wireInt, // Trick to get the ends in the right order. // Use the x axis in the original coordinate system. Choose the // most negative x-axis as the one pointing forward - if (linePrim.vertices[1][0] > linePrim.vertices[2][0]) { + if (linePrim.vertices[0][0] > linePrim.vertices[1][0]) { cat.start = gv1; cat.end = gv2; } else { -- 2.39.5