diff options
author | Cornelius Gati <cgati@cfelsgi.desy.de> | 2013-01-28 15:47:30 +0100 |
---|---|---|
committer | Cornelius Gati <cgati@cfelsgi.desy.de> | 2013-01-28 15:47:30 +0100 |
commit | b163b4d6cc9bc0312b445047b2a057e685237e02 (patch) | |
tree | 88bd5f9b9d284e616bfcc05bc0ded14e4c3f6519 | |
parent | 6594902941cbf9cb1bded9bf11c465766dcf3b6d (diff) |
Changed index.c/.h
-rw-r--r-- | libcrystfel/src/index.c | 16 | ||||
-rw-r--r-- | libcrystfel/src/index.h | 1 | ||||
-rw-r--r-- | libcrystfel/src/xds.h | 11 |
3 files changed, 23 insertions, 5 deletions
diff --git a/libcrystfel/src/index.c b/libcrystfel/src/index.c index 7d912902..49f5636b 100644 --- a/libcrystfel/src/index.c +++ b/libcrystfel/src/index.c @@ -11,6 +11,7 @@ * 2010-2012 Thomas White <taw@physics.org> * 2010-2011 Richard Kirian <rkirian@asu.edu> * 2012 Lorenzo Galli + * 2013 Cornelius Gati <cornelius.gati@cfel.de> * * This file is part of CrystFEL. * @@ -44,6 +45,7 @@ #include "peaks.h" #include "dirax.h" #include "mosflm.h" +#include "xds.h" #include "detector.h" #include "index.h" #include "index-priv.h" @@ -97,6 +99,10 @@ IndexingPrivate **prepare_indexing(IndexingMethod *indm, UnitCell *cell, iprivs[n] = indexing_private(indm[n]); break; + case INDEXING_XDS : + iprivs[n] = indexing_private(indm[n]); + break; + case INDEXING_REAX : iprivs[n] = reax_prepare(); break; @@ -132,6 +138,10 @@ void cleanup_indexing(IndexingPrivate **priv) free(priv[n]); break; + case INDEXING_XDS : + free(priv[n]); + break; + case INDEXING_REAX : reax_cleanup(priv[n]); break; @@ -196,6 +206,10 @@ void index_pattern(struct image *image, UnitCell *cell, IndexingMethod *indm, run_mosflm(image, cell); break; + case INDEXING_XDS : + run_XDS(image, cell); + break; + case INDEXING_REAX : reax_index(ipriv[n], image, cell); break; @@ -294,6 +308,8 @@ IndexingMethod *build_indexer_list(const char *str, int *need_cell) list[i] = INDEXING_DIRAX; } else if ( strcmp(methods[i], "mosflm") == 0) { list[i] = INDEXING_MOSFLM; + } else if ( strcmp(methods[i], "xds") == 0) { + list[i] = INDEXING_xds; } else if ( strcmp(methods[i], "reax") == 0) { list[i] = INDEXING_REAX; *need_cell = 1; diff --git a/libcrystfel/src/index.h b/libcrystfel/src/index.h index 9d23f3fb..406ad317 100644 --- a/libcrystfel/src/index.h +++ b/libcrystfel/src/index.h @@ -48,6 +48,7 @@ typedef enum { INDEXING_NONE, INDEXING_DIRAX, INDEXING_MOSFLM, + INDEXING_xds, INDEXING_REAX, } IndexingMethod; diff --git a/libcrystfel/src/xds.h b/libcrystfel/src/xds.h index 1aedf57f..3521ebc5 100644 --- a/libcrystfel/src/xds.h +++ b/libcrystfel/src/xds.h @@ -1,13 +1,14 @@ /* * grainspotter.h * - * Invoke GrainSpotter for multi-crystal autoindexing + * Invoke xds for crystal autoindexing * * Copyright © 2013 Deutsches Elektronen-Synchrotron DESY, * a research centre of the Helmholtz Association. * * Authors: * 2010-2013 Thomas White <taw@physics.org> + * 2013 Cornelius Gati <cornelius.gati@cfel.de> * * This file is part of CrystFEL. * @@ -26,8 +27,8 @@ * */ -#ifndef GRAINSPOTTER_H -#define GRAINSPOTTER_H +#ifndef xds_H +#define xds_H #ifdef HAVE_CONFIG_H #include <config.h> @@ -36,7 +37,7 @@ #include "cell.h" -extern void run_grainspotter(struct image *image, UnitCell *cell); +extern void run_xds(struct image *image, UnitCell *cell); -#endif /* GRAINSPOTTER_H */ +#endif /* XDS_H */ |