aboutsummaryrefslogtreecommitdiff
path: root/src/get_hkl.c
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2021-10-20 15:28:19 +0200
committerThomas White <taw@physics.org>2021-10-20 15:28:19 +0200
commit0211dd487cf8d4f3815273d993838cd8369a9f83 (patch)
tree1126c54b9b611d98b672438f72ba2c26d7de4287 /src/get_hkl.c
parent992b30aae2cedb427637f625d0bf5aef623885c6 (diff)
Add "plain" MTZ file layout, distinct from "Bijvoet" layout
Closes: https://gitlab.desy.de/thomas.white/crystfel/-/issues/52
Diffstat (limited to 'src/get_hkl.c')
-rw-r--r--src/get_hkl.c21
1 files changed, 17 insertions, 4 deletions
diff --git a/src/get_hkl.c b/src/get_hkl.c
index e80383e5..82bf5815 100644
--- a/src/get_hkl.c
+++ b/src/get_hkl.c
@@ -94,9 +94,10 @@ static void show_help(const char *s)
" equivalent reflections.\n"
"\n"
"Don't forget to specify the output filename:\n"
-" -o, --output=<filename> Output filename (default: stdout).\n"
-" --output-format=mtz Output in MTZ format.\n"
-" --output-format=xds Output in XDS format.\n"
+" -o, --output=<filename> Output filename (default: stdout).\n"
+" --output-format=mtz Output in MTZ format.\n"
+" --output-format=mtz-bij Output in MTZ format, Bijvoet pairs together\n"
+" --output-format=xds Output in XDS format.\n"
);
}
@@ -916,7 +917,19 @@ int main(int argc, char *argv[])
r = 1;
} else {
r = write_to_mtz(input, mero, cell, 0, INFINITY, output,
- "dataset", "crystal", "project");
+ "dataset", "crystal", "project", 0);
+ }
+ } else if ( strcasecmp(output_format_str, "mtz-bij") == 0 ) {
+ if ( !libcrystfel_can_write_mtz() ) {
+ ERROR("Sorry, this version of CrystFEL was compiled "
+ "without MTZ support (libccp4 is required)\n");
+ r = 1;
+ } else if ( output == NULL ) {
+ ERROR("You must provide the MTZ output filename.\n");
+ r = 1;
+ } else {
+ r = write_to_mtz(input, mero, cell, 0, INFINITY, output,
+ "dataset", "crystal", "project", 1);
}
} else if ( strcasecmp(output_format_str, "xds") == 0 ) {
if ( output == NULL ) {