# HG changeset patch # User Matthew Turk # Date 1247502791 25200 # Branch raytrace # Node ID b2a83377938656c37e9f0fd6fee1be44e94d47ee # Parent 0e20534ae393978f24f981fd63cb1b85bc5ca1bf Making patch to RTIntegrator.pyx, but not to RTIntegrator.c diff -r 0e20534ae393978f24f981fd63cb1b85bc5ca1bf -r b2a83377938656c37e9f0fd6fee1be44e94d47ee yt/lagos/RTIntegrator.pyx --- a/yt/lagos/RTIntegrator.pyx Wed Jul 08 23:39:42 2009 -0700 +++ b/yt/lagos/RTIntegrator.pyx Mon Jul 13 09:33:11 2009 -0700 @@ -111,7 +111,7 @@ (left_edge[1] <= u[1] <= right_edge[1]) and \ (left_edge[2] <= u[2] <= right_edge[2]): intersect_t = 0 - if intersect_t > 1: return + if not (0 <= intersect_t <= 1): return # Now get the indices of the intersection intersect = u + intersect_t * v for i in range(3): @@ -132,7 +132,8 @@ # Note that we are calculating t on the fly, but we get *negative* t # values from what they should be. # If we've reached t = 1, we are done. - if tmax[0] > 1 and tmax[1] > 1 and tmax[2] > 1: + if tmax[0] >= 1 and tmax[1] >= 1 and tmax[2] >= 1: + grid_t[cur_ind[0], cur_ind[1], cur_ind[2]] = 1.0 - enter_t break if tmax[0] < tmax[1]: if tmax[0] < tmax[2]: