diff options
author | Stan Seibert <stan@mtrr.org> | 2012-05-18 17:22:43 -0400 |
---|---|---|
committer | tlatorre <tlatorre@uchicago.edu> | 2021-05-09 08:42:39 -0700 |
commit | baedd53629f9b7aa77016cdd9c0f64c9cdb290a5 (patch) | |
tree | a80730a75c66032260ce41fd016fdea608f02851 | |
parent | d75473e3e57e972f8b91d3debdbe65681fbeb0ef (diff) | |
download | chroma-baedd53629f9b7aa77016cdd9c0f64c9cdb290a5.tar.gz chroma-baedd53629f9b7aa77016cdd9c0f64c9cdb290a5.tar.bz2 chroma-baedd53629f9b7aa77016cdd9c0f64c9cdb290a5.zip |
Photons tagged with NAN_ABORT should not continue to be propagated.
-rw-r--r-- | chroma/cuda/propagate.cu | 4 |
1 files 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; } |