aboutsummaryrefslogtreecommitdiff
path: root/libcrystfel/src
diff options
context:
space:
mode:
Diffstat (limited to 'libcrystfel/src')
-rw-r--r--libcrystfel/src/index.c13
-rw-r--r--libcrystfel/src/index.h7
2 files changed, 15 insertions, 5 deletions
diff --git a/libcrystfel/src/index.c b/libcrystfel/src/index.c
index c8c86414..a2fdb861 100644
--- a/libcrystfel/src/index.c
+++ b/libcrystfel/src/index.c
@@ -3,12 +3,12 @@
*
* Perform indexing (somehow)
*
- * Copyright © 2012-2015 Deutsches Elektronen-Synchrotron DESY,
+ * Copyright © 2012-2017 Deutsches Elektronen-Synchrotron DESY,
* a research centre of the Helmholtz Association.
* Copyright © 2012 Lorenzo Galli
*
* Authors:
- * 2010-2014 Thomas White <taw@physics.org>
+ * 2010-2017 Thomas White <taw@physics.org>
* 2010-2011 Richard Kirian <rkirian@asu.edu>
* 2012 Lorenzo Galli
* 2013 Cornelius Gati <cornelius.gati@cfel.de>
@@ -421,10 +421,16 @@ static int finished_retry(IndexingMethod indm, int r, struct image *image)
}
}
-
void index_pattern(struct image *image,
IndexingMethod *indms, IndexingPrivate **iprivs)
{
+ index_pattern_2(image, indms, iprivs, NULL);
+}
+
+
+void index_pattern_2(struct image *image, IndexingMethod *indms,
+ IndexingPrivate **iprivs, int *ping)
+{
int n = 0;
ImageFeatureList *orig;
@@ -452,6 +458,7 @@ void index_pattern(struct image *image,
ntry++;
done = finished_retry(indms[n], r, image);
if ( ntry > 5 ) done = 1;
+ if ( ping != NULL ) (*ping)++;
} while ( !done );
diff --git a/libcrystfel/src/index.h b/libcrystfel/src/index.h
index 2fb5a13d..e5f7764a 100644
--- a/libcrystfel/src/index.h
+++ b/libcrystfel/src/index.h
@@ -3,13 +3,13 @@
*
* Perform indexing (somehow)
*
- * Copyright © 2012-2016 Deutsches Elektronen-Synchrotron DESY,
+ * Copyright © 2012-2017 Deutsches Elektronen-Synchrotron DESY,
* a research centre of the Helmholtz Association.
* Copyright © 2012 Richard Kirian
* Copyright © 2012 Lorenzo Galli
*
* Authors:
- * 2010-2016 Thomas White <taw@physics.org>
+ * 2010-2017 Thomas White <taw@physics.org>
* 2010 Richard Kirian
* 2012 Lorenzo Galli
* 2015 Kenneth Beyerlein <kenneth.beyerlein@desy.de>
@@ -154,6 +154,9 @@ extern IndexingPrivate **prepare_indexing(IndexingMethod *indm, UnitCell *cell,
extern void index_pattern(struct image *image,
IndexingMethod *indms, IndexingPrivate **iprivs);
+extern void index_pattern_2(struct image *image, IndexingMethod *indms,
+ IndexingPrivate **iprivs, int *ping);
+
extern void cleanup_indexing(IndexingMethod *indms, IndexingPrivate **privs);
#ifdef __cplusplus