diff options
author | Thomas White <taw@physics.org> | 2015-09-14 16:56:53 +0200 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2015-09-14 17:02:05 +0200 |
commit | 6b13bcfa2b3a23ee6a502ecde41ef5e0a0a468df (patch) | |
tree | 8d3867c7d93b6405285094c9a5c0e4624c418bf7 | |
parent | 0074908ce3f57c650e50044866c6047bf8452a82 (diff) |
Revert "Use old MOSFLM indexing command when using -nocell"
This reverts commit d75b852f52b244796c0386c4f21cf36ca5bfcf70.
-rw-r--r-- | libcrystfel/src/mosflm.c | 29 |
1 files changed, 12 insertions, 17 deletions
diff --git a/libcrystfel/src/mosflm.c b/libcrystfel/src/mosflm.c index d9033399..4eac7874 100644 --- a/libcrystfel/src/mosflm.c +++ b/libcrystfel/src/mosflm.c @@ -520,7 +520,9 @@ static char *spacegroup_for_lattice(UnitCell *cell) static void mosflm_send_next(struct image *image, struct mosflm_data *mosflm) { char tmp[256]; + char cen; double wavelength; + double a = 0, b = 0, c = 0, alpha = 0, beta = 0, gamma = 0; switch ( mosflm->step ) { @@ -578,28 +580,21 @@ static void mosflm_send_next(struct image *image, struct mosflm_data *mosflm) case 8 : if ( mosflm->mp->indm & INDEXING_USE_CELL_PARAMETERS ) { - - char cen; - double a, b, c, alpha, beta, gamma; - cell_get_parameters(mosflm->mp->template, &a, &b, &c, &alpha, &beta, &gamma); cen = cell_get_centering(mosflm->mp->template); - - snprintf(tmp, 255, "AUTOINDEX DPS FILE %s IMAGE 1 " - "MAXCELL 1000 REFINE " - "CELL %.1f %.1f %.1f %.1f %.1f %.1f " - "CENTERING %c\n", - mosflm->sptfile, a*1e10, b*1e10, c*1e10, - rad2deg(alpha), rad2deg(beta), rad2deg(gamma), - cen); - } else { - snprintf(tmp, 255, "AUTOINDEX DPS FILE %s" - " IMAGE 1 MAXCELL 1000 REFINE\n", - mosflm->sptfile); - + cen = 'P'; + a = 0; /* Disables prior-cell algorithm in MOSFLM */ } + /* Old MOSFLM simply ignores CELL and CENTERING subkeywords. + * So this doesn't do any harm. + * TODO: but still better to show WARNING if MOSFLM is old. */ + snprintf(tmp, 255, "AUTOINDEX DPS FILE %s IMAGE 1 MAXCELL 1000" + "REFINE " + "CELL %.1f %.1f %.1f %.1f %.1f %.1f CENTERING %c\n", + mosflm->sptfile, a*1e10, b*1e10, c*1e10, + rad2deg(alpha), rad2deg(beta), rad2deg(gamma), cen); mosflm_sendline(tmp, mosflm); break; |