aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2022-03-03 10:28:19 +0100
committerThomas White <taw@physics.org>2022-03-03 10:28:19 +0100
commit049d7fb351bfaf4ae2e627fe21f8748504a42778 (patch)
treed4d91083941deba87117914a809cb18717490102
parentf36b114e46eaa93b7a7ecc1837b7c8584bf86ad0 (diff)
GUI: Use fixed profile radius for indexing once
Fixes: https://gitlab.desy.de/thomas.white/crystfel/-/issues/61
-rw-r--r--src/gui_index.c22
1 files changed, 17 insertions, 5 deletions
diff --git a/src/gui_index.c b/src/gui_index.c
index 8524cc79..b5b24248 100644
--- a/src/gui_index.c
+++ b/src/gui_index.c
@@ -622,12 +622,24 @@ static void run_indexing_once(struct crystfelproject *proj)
index_pattern(proj->cur_image, ipriv);
for ( i=0; i<proj->cur_image->n_crystals; i++ ) {
- crystal_set_profile_radius(proj->cur_image->crystals[i], 0.02e9);
crystal_set_mosaicity(proj->cur_image->crystals[i], 0.0);
- if ( refine_radius(proj->cur_image->crystals[i],
- proj->cur_image) )
- {
- ERROR("WARNING: Radius determination failed\n");
+ if ( proj->indexing_params.use_fix_profile_radius ) {
+
+ /* Manual radius */
+ crystal_set_profile_radius(proj->cur_image->crystals[i],
+ proj->indexing_params.fix_profile_radius);
+
+ } else {
+
+ /* Auto radius determination */
+ crystal_set_profile_radius(proj->cur_image->crystals[i],
+ 0.02e9);
+ if ( refine_radius(proj->cur_image->crystals[i],
+ proj->cur_image) )
+ {
+ ERROR("WARNING: Radius determination failed\n");
+ }
+
}
}