aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPascal Hogan-Lamarre <pascal.hogan@gmail.com>2020-07-19 21:27:02 +0200
committerPascal Hogan-Lamarre <pascal.hogan@gmail.com>2020-07-19 21:27:02 +0200
commitf34c46f087108a293d471eec4235b292a13daa69 (patch)
tree26dd8d8942802cdcfe7eb025cd674afc07be56ef
parentf1a24d0e4c32735fa016cbb262b61a1cce5960fc (diff)
last minute changes
-rw-r--r--libcrystfel/src/index.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/libcrystfel/src/index.c b/libcrystfel/src/index.c
index ab451c41..3ac3dad5 100644
--- a/libcrystfel/src/index.c
+++ b/libcrystfel/src/index.c
@@ -68,6 +68,7 @@
struct skip_private
{
char path_to_sol[50];
+ UnitCell *cellTemplate;
float solutions[];
};
@@ -153,7 +154,7 @@ static void show_indexing_flags(IndexingFlags flags)
}
-void *skip_prepare(char *solution_filename)
+void *skip_prepare(char *solution_filename, UnitCell *cell)
{
FILE *fh;
int nlines;
@@ -277,6 +278,9 @@ void *skip_prepare(char *solution_filename)
{
dp->solutions[k] = params[k];
}
+
+
+ dp->cellTemplate = cell;
free(params);
@@ -366,6 +370,9 @@ static int skip_index(struct image *image, void *mpriv)
cr = crystal_new();
cell = cell_new();
cell_set_reciprocal(cell, asx * 1e9, asy * 1e9, asz* 1e9, bsx * 1e9, bsy * 1e9, bsz * 1e9, csx * 1e9, csy * 1e9, csz* 1e9);
+ cell_set_lattice_type(cell, cell_get_lattice_type(dp->cellTemplate));
+ cell_set_centering(cell, cell_get_centering(dp->cellTemplate));
+ cell_set_unique_axis(cell, cell_get_unique_axis(dp->cellTemplate));
crystal_set_cell(cr, cell);
crystal_set_det_shift(cr, xshift * 1e-3, yshift * 1e-3);
@@ -496,7 +503,7 @@ static void *prepare_method(IndexingMethod *m, UnitCell *cell,
break;
case INDEXING_FILE :
- priv = skip_prepare(filename);
+ priv = skip_prepare(filename, cell);
break;
case INDEXING_FELIX :