aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2014-03-28 14:09:04 +0100
committerThomas White <taw@physics.org>2014-03-28 14:09:04 +0100
commit9f6233c33890008ca4a7d5bb8de271acbf9b9c49 (patch)
treed0fb5a1cba0d1700356636af94bf2a9de8d78a59
parent9740409b10319a46529575876b5ddf54d468ef3c (diff)
validate_peaks(): Count saturated peaks only if they are being rejected
-rw-r--r--libcrystfel/src/peaks.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libcrystfel/src/peaks.c b/libcrystfel/src/peaks.c
index 2b326cc0..47bec10c 100644
--- a/libcrystfel/src/peaks.c
+++ b/libcrystfel/src/peaks.c
@@ -707,8 +707,10 @@ void validate_peaks(struct image *image, double min_snr,
}
if ( saturated ) {
- n_sat++;
- if ( !use_saturated ) continue;
+ if ( !use_saturated ) {
+ n_sat++;
+ continue;
+ }
}
/* It is possible for the centroid to fall outside the image */