Fix distance-to-surface calculationg for general plane surface.

This commit is contained in:
Paul Romano 2014-07-28 20:12:02 -04:00
parent ec21addbee
commit 4439de571f

View file

@ -892,7 +892,7 @@ contains
if (on_surface .or. tmp == ZERO) then
d = INFINITY
else
d = -(A*x + B*y + C*w - D)/tmp
d = -(A*x + B*y + C*z - D)/tmp
if (d < ZERO) d = INFINITY
end if