From 6910e4ef415ea627d95e99ded041725d16874eb7 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Fri, 24 May 2013 12:07:09 +0200 Subject: Assign rigid group for panels which don't have one --- libcrystfel/src/detector.c | 7 +++++-- libcrystfel/src/detector.h | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) (limited to 'libcrystfel/src') diff --git a/libcrystfel/src/detector.c b/libcrystfel/src/detector.c index 09f33d5d..f7ff135e 100644 --- a/libcrystfel/src/detector.c +++ b/libcrystfel/src/detector.c @@ -984,7 +984,7 @@ out: det->max_fs = max_fs; det->max_ss = max_ss; - /* Calculate matrix inverse */ + /* Calculate matrix inverses and other stuff */ for ( i=0; in_panels; i++ ) { struct panel *p; @@ -1006,8 +1006,11 @@ out: p->w = p->max_fs - p->min_fs + 1; p->h = p->max_ss - p->min_ss + 1; - } + if ( p->rigid_group == NULL ) { + p->rigid_group = find_or_add_rg(det, p->name); + } + } find_min_max_d(det); diff --git a/libcrystfel/src/detector.h b/libcrystfel/src/detector.h index c8d36396..0f9be817 100644 --- a/libcrystfel/src/detector.h +++ b/libcrystfel/src/detector.h @@ -62,7 +62,7 @@ struct panel double res; /* Resolution in pixels per metre */ char badrow; /* 'x' or 'y' */ int no_index; /* Don't index peaks in this panel if non-zero */ - char *rigid_group; /* Rigid group, or -1 for none */ + char *rigid_group; /* Rigid group name */ double adu_per_eV; /* Number of ADU per eV */ double max_adu; /* Treat pixel as unreliable if higher than this */ -- cgit v1.2.3