From 6fecf05e83c13901e86fb84456536d9062a0fc4e Mon Sep 17 00:00:00 2001 From: Thomas White Date: Sun, 21 Oct 2012 18:11:15 -0700 Subject: indexamajig: Record number of saturated reflections in stream --- libcrystfel/src/stream.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'libcrystfel/src/stream.c') diff --git a/libcrystfel/src/stream.c b/libcrystfel/src/stream.c index 6627e7ea..b8ff9238 100644 --- a/libcrystfel/src/stream.c +++ b/libcrystfel/src/stream.c @@ -261,6 +261,9 @@ void write_chunk(FILE *ofh, struct image *i, struct hdfile *hdfile, int f) i->diffracting_resolution/1e9, 1e9 / i->diffracting_resolution); + fprintf(ofh, "num_saturated_reflections" + " = %lli\n", i->n_saturated); + } if ( i->det != NULL ) { @@ -343,6 +346,7 @@ int read_chunk(FILE *fh, struct image *image) image->features = NULL; image->reflections = NULL; image->indexed_cell = NULL; + image->n_saturated = 0; do { @@ -417,6 +421,10 @@ int read_chunk(FILE *fh, struct image *image) have_ev = 1; } + if ( strncmp(line, "num_saturated_reflections = ", 28) == 0 ) { + image->n_saturated = atoi(line+28); + } + if ( strcmp(line, PEAK_LIST_START_MARKER) == 0 ) { if ( read_peaks(fh, image) ) { ERROR("Failed while reading peaks\n"); -- cgit v1.2.3