From baedd53629f9b7aa77016cdd9c0f64c9cdb290a5 Mon Sep 17 00:00:00 2001 From: Stan Seibert Date: Fri, 18 May 2012 17:22:43 -0400 Subject: Photons tagged with NAN_ABORT should not continue to be propagated. --- chroma/cuda/propagate.cu | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/chroma/cuda/propagate.cu b/chroma/cuda/propagate.cu index 9520cf8..d336c8f 100644 --- a/chroma/cuda/propagate.cu +++ b/chroma/cuda/propagate.cu @@ -149,7 +149,7 @@ propagate(int first_photon, int nthreads, unsigned int *input_queue, p.history = histories[photon_id]; p.weight = weights[photon_id]; - if (p.history & (NO_HIT | BULK_ABSORB | SURFACE_DETECT | SURFACE_ABSORB)) + if (p.history & (NO_HIT | BULK_ABSORB | SURFACE_DETECT | SURFACE_ABSORB | NAN_ABORT)) return; State s; @@ -205,7 +205,7 @@ propagate(int first_photon, int nthreads, unsigned int *input_queue, weights[photon_id] = p.weight; // Not done, put photon in output queue - if ((p.history & (NO_HIT | BULK_ABSORB | SURFACE_DETECT | SURFACE_ABSORB)) == 0) { + if ((p.history & (NO_HIT | BULK_ABSORB | SURFACE_DETECT | SURFACE_ABSORB | NAN_ABORT)) == 0) { int out_idx = atomicAdd(output_queue, 1); output_queue[out_idx] = photon_id; } -- cgit