aboutsummaryrefslogtreecommitdiff
path: root/src/mrc.h
diff options
context:
space:
mode:
authortaw27 <taw27@bf6ca9ba-c028-0410-8290-897cf20841d1>2007-02-05 21:12:57 +0000
committertaw27 <taw27@bf6ca9ba-c028-0410-8290-897cf20841d1>2007-02-05 21:12:57 +0000
commit05b5d261682b9136fb46476a64eab6980b0dba64 (patch)
treed7faa450b69cf2104ffff7fc89a95914284d23af /src/mrc.h
Initial import
git-svn-id: svn://cook.msm.cam.ac.uk:745/diff-tomo/dtr@1 bf6ca9ba-c028-0410-8290-897cf20841d1
Diffstat (limited to 'src/mrc.h')
-rw-r--r--src/mrc.h121
1 files changed, 121 insertions, 0 deletions
diff --git a/src/mrc.h b/src/mrc.h
new file mode 100644
index 0000000..8633f05
--- /dev/null
+++ b/src/mrc.h
@@ -0,0 +1,121 @@
+/*
+ * mrc.h
+ *
+ * Read the MRC tomography format
+ *
+ * (c) 2007 Thomas White <taw27@cam.ac.uk>
+ * dtr - Diffraction Tomography Reconstruction
+ *
+ */
+
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#ifndef MRC_H
+#define MRC_H
+
+#include <stdint.h>
+
+#include "control.h"
+
+typedef struct struct_mrcheader {
+
+ int32_t nx;
+ int32_t ny;
+ int32_t nz;
+ int32_t mode;
+ int32_t nxstart;
+ int32_t nystart;
+ int32_t nzstart;
+ int32_t mx;
+ int32_t my;
+ int32_t mz;
+ float xlen;
+ float ylen;
+ float zlen;
+ float alpha;
+ float beta;
+ float gamma;
+ int32_t mapc;
+ int32_t mapr;
+ int32_t maps;
+ float amin;
+ float amax;
+ float amean;
+ int16_t ispg; /* Space group number */
+ int16_t nsymbt;
+ int32_t next;
+ int16_t dvid;
+ char extra[30];
+ int16_t numintegers;
+ int16_t numfloats;
+ int16_t sub;
+ int16_t zfac;
+ float min2;
+ float max2;
+ float min3;
+ float max3;
+ float min4;
+ float max4;
+ int16_t idtype;
+ int16_t lens;
+ int16_t nd1;
+ int16_t nd2;
+ int16_t vd1;
+ int16_t vd2;
+ float tiltangles[9];
+ float zorg;
+ float xorg;
+ float yorg;
+ int32_t nlabl;
+ char data[10][80];
+
+} MRCHeader;
+
+typedef struct struct_mrcextheader {
+
+ float a_tilt;
+ float b_tilt;
+ float x_stage;
+ float y_stage;
+ float z_stage;
+ float x_shift;
+ float y_shift;
+ float defocus;
+ float exp_time;
+ float mean_int;
+ float tilt_axis;
+ float pixel_size;
+ float magnification;
+ float mic_type;
+ float gun_type;
+ float d_number;
+ float voltage;
+ float focus_spread;
+ float mtf;
+ float df_start;
+ float focus_step;
+ float dac_setting;
+ float cs;
+ float semi_conv;
+ float info_limit;
+ float num_images;
+ float num_in_series;
+ float coma1;
+ float coma2;
+ float astig21;
+ float astig22;
+ float astig31;
+ float astig32;
+ float cam_type;
+ float cam_pos;
+ float padding[64]; /* Need to guarantee that reading an extended header (of any size)
+ will never write beyond the boundary of this structure... */
+
+} MRCExtHeader;
+
+extern int mrc_read(ControlContext *ctx);
+
+#endif /* MRC_H */