| Bsoft 2.0.5 Bernard's software package

rwIMAGIC.h
Go to the documentation of this file.
1
11 #include "rwimg.h"
12
13 #define IMAGICSIZE 1024 // Size of the IMAGIC header for each image
14
15 struct IMAGIChead { // file header for IMAGIC data
16 int imn; // 0 image location number (1,2,...)
17 int ifn; // 1 # images following
18 int ierror; // 2 error code: error if >0
19 int nhfr; // 3 # header records per image
20 int ndate; // 4 creation day
21 int nmonth; // 5 creation month
22 int nyear; // 6 creation year
23 int nhour; // 7 creation hour
24 int nminut; // 8 creation minute
25 int nsec; // 9 creation second
26 int npix2; // 10 # 4-byte reals in image
27 int npixel; // 11 # image elements
28 int ixlp; // 12 lines per image (Y)
29 int iylp; // 13 pixels per line (X)
30 char type[4]; // 14 image type
31 int ixold; // 15 top-left X coordinate
32 int iyold; // 16 top-left Y coordinate
33 float avdens; // 17 average
34 float sigma; // 18 standard deviation
35 float varian; // 19 variance
36 float oldavd; // 20 old average
37 float densmax; // 21 maximum
38 float densmin; // 22 minimum
39 int complex; // 23 label indicating that data is complex
40 float cxlength; // 24 cell dimension in Angstr. (x-direction)
41 float cylength; // 25 cell dimension in Angstr. (y-direction)
42 float czlength; // 26 cell dimension in Angstr. (z-direction)
43 float calpha; // 27 cell angle alpha
44 float cbeta; // 28 cell angle beta
45 char name[80]; // 29-48 image name
46 float cgamma; // 49 cell angle gamma
47 int mapc; // 50 axis corresponding to columns
48 int mapr; // 51 axis corresponding to rows
49 int maps; // 52 axis corresponding to sections
50 int ispg; // 53 space group
51 int nxstart; // 54 number of 1st column in map
52 int nystart; // 55 number of 1st row in map
53 int nzstart; // 56 number of 1st section in map
54 int nxintv; // 57 number of intervals along X
55 int nyintv; // 58 number of intervals along Y
56 int nzintv; // 59 number of intervals along Z
57 int izlp; // 60 number of 2D planes in 3D data
58 int i4lp; // 61 number of images
59 int i5lp; // 62
60 int i6lp; // 63
61 float alpha; // 64 Euler angle alpha
62 float beta; // 65 Euler angle beta
63 float gamma; // 66 Euler angle gamma
64 int imavers; // 67 IMAGIC-5 version (yyyymmdd)
65 int realtype; // 68 floating point type, machine stamp
66 int buffer[29]; // 69-97 Variables that control the buffering
67 int ronly; // 98 flag in calling program to open file readonly
68 float angle; // 99 last rotation angle
69 float rcp; // 100 rotational correlation peak
70 int ixpeak; // 101 shift correlation peak in X direction
71 int iypeak; // 102 shift correlation peak in Y direction
72 float ccc; // 103 cross correlation peak hight
73 float errar; // 104 error in angular reconstitution
74 float err3d; // 105 error in 3D reconstruction
75 int ref; // 106 (multi-) reference number
76 float classno; // 107 class number in classification
77 float locold; // 108 location number before CUT-IMAGE (boxing)
78 float oldavd2; // 109 old average density
79 float oldsigma; // 110 old sigma
80 float xshift; // 111 last shift in X direction
81 float yshift; // 112 last shift in Y direction
82 float numcls; // 113 number of class members
83 float ovqual; // 114 overall class quality
84 float eangle; // 115 equivalent angle
85 float exshift; // 116 equivalent shift in X direction
86 float eyshift; // 117 equivalent shift in Y direction
87 float cmtotvar; // 118 used in MSA/IMAGECOOS
88 float informat; // 119 Gauss norm / real*FT Space information of the data set
89 int numeigen; // 120 number of eigen values in MSA
90 int niactive; // 121 number of active images in MSA
91 float resolx; // 122 Angstrom per pixel/voxel in X direction
92 float resoly; // 123 Angstrom per pixel/voxel in Y direction
93 float resolz; // 124 Angstrom per pixel/voxel in Z direction
94 float alpha2; // 125 Euler angle alpha (from projection matching)
95 float beta2; // 126 Euler angle beta (from projection matching)
96 float gamma2; // 127 Euler angle gamma (from projection matching)
97 float nmetric; // 128 Metric used in MSA calculations
98 float actmsa; // 129 a flag indicating whether the "image" is
99 float coosmsa[69]; // 130-198 co-ordinates of "image" along factorial axis
100 char history[228]; // 199-255 history
101 } ;
102
103 /*
104 Machine stamp:
105 16777216 for VAX/VMS
106 33686018 for DEC/OSF,ULTRIX, LINUX, MS Windows
107 67372036 for SiliconGraphics, SUN, HP, IBM
108 */
109
110 struct IMAGIChead_old { // file header for IMAGIC data
111 int imn; // 0 image location number (1,2,...)
112 int ifn; // 1 # images following
113 int ierror; // 2 error code: error if >0
114 int nhfr; // 3 # header records per image
115 int ndate; // 4 creation day
116 int nmonth; // 5 creation month
117 int nyear; // 6 creation year
118 int nhour; // 7 creation hour
119 int nminut; // 8 creation minute
120 int nsec; // 9 creation second
121 int npix2; // 10 # 4-byte reals in image
122 int npixel; // 11 # image elements
123 int ixlp; // 12 lines per image (Y)
124 int iylp; // 13 pixels per line (X)
125 char type[4]; // 14 image type
126 int ixold; // 15 top-left X coordinate
127 int iyold; // 16 top-left Y coordinate
128 float avdens; // 17 average
129 float sigma; // 18 standard deviation
130 float varian; // 19 variance
131 float oldavd; // 20 old average
132 float densmax; // 21 maximum
133 float densmin; // 22 minimum
134 // double sum; // 23+24 sum of densities
135 // double squares; // 25+26 sum of squares
136 float dummy[4]; // 23-26 dummy place holder
137 char lastpr[8]; // 27+28 last program writing file
138 char name[80]; // 29-48 image name
139 float extra_1[8]; // 49-56 additional parameters
140 float eman_alt; // 57 EMAN: equiv to psi & PFT omega
141 float eman_az; // 58 EMAN: equiv to theta
142 float eman_phi; // 59 EMAN: equiv to phi
143 float extra_2[69]; // 60-128 additional parameters
144 float euler_alpha; // 129 Euler angles: psi
145 float euler_beta; // 130 theta
146 float euler_gamma; // 131 phi
147 float proj_weight; // 132 weight of each projection
148 float extra_3[66]; // 133-198 additional parameters
149 char history[228]; // 199-255 history
150 } ;
151
152
153 // I/O prototypes
154 int readIMAGIC(Bimage* p, int readdata, int img_select);
155 int writeIMAGIC(Bimage* p);
IMAGIChead_old::nsec
int nsec
Definition: rwIMAGIC.h:120
IMAGIChead::xshift
float xshift
Definition: rwIMAGIC.h:80
IMAGIChead_old::ndate
int ndate
Definition: rwIMAGIC.h:115
IMAGIChead_old::euler_alpha
float euler_alpha
Definition: rwIMAGIC.h:144
IMAGIChead::resolx
float resolx
Definition: rwIMAGIC.h:91
IMAGIChead::numeigen
int numeigen
Definition: rwIMAGIC.h:89
IMAGIChead::npix2
int npix2
Definition: rwIMAGIC.h:26
IMAGIChead_old::ifn
int ifn
Definition: rwIMAGIC.h:112
IMAGIChead::iyold
int iyold
Definition: rwIMAGIC.h:32
IMAGIChead::ixold
int ixold
Definition: rwIMAGIC.h:31
IMAGIChead_old::nmonth
int nmonth
Definition: rwIMAGIC.h:116
IMAGIChead::i6lp
int i6lp
Definition: rwIMAGIC.h:60
IMAGIChead::locold
float locold
Definition: rwIMAGIC.h:77
IMAGIChead::ndate
int ndate
Definition: rwIMAGIC.h:20
IMAGIChead::sigma
float sigma
Definition: rwIMAGIC.h:34
IMAGIChead::alpha2
float alpha2
Definition: rwIMAGIC.h:94
IMAGIChead::alpha
float alpha
Definition: rwIMAGIC.h:61
IMAGIChead_old::nhfr
int nhfr
Definition: rwIMAGIC.h:114
IMAGIChead::cgamma
float cgamma
Definition: rwIMAGIC.h:46
IMAGIChead::type
char type[4]
Definition: rwIMAGIC.h:30
IMAGIChead::nhfr
int nhfr
Definition: rwIMAGIC.h:19
IMAGIChead::iylp
int iylp
Definition: rwIMAGIC.h:29
writeIMAGIC
int writeIMAGIC(Bimage *p)
Writing an IMAGIC image format. A file format for the IMAGIC package.
Definition: rwIMAGIC.cpp:246
IMAGIChead_old::name
char name[80]
Definition: rwIMAGIC.h:138
IMAGIChead::realtype
int realtype
Definition: rwIMAGIC.h:65
IMAGIChead::varian
float varian
Definition: rwIMAGIC.h:35
IMAGIChead::nmetric
float nmetric
Definition: rwIMAGIC.h:97
IMAGIChead::nminut
int nminut
Definition: rwIMAGIC.h:24
IMAGIChead::beta
float beta
Definition: rwIMAGIC.h:62
IMAGIChead::resolz
float resolz
Definition: rwIMAGIC.h:93
IMAGIChead::cmtotvar
float cmtotvar
Definition: rwIMAGIC.h:87
IMAGIChead::ovqual
float ovqual
Definition: rwIMAGIC.h:83
IMAGIChead_old::eman_phi
float eman_phi
Definition: rwIMAGIC.h:142
IMAGIChead::cylength
float cylength
Definition: rwIMAGIC.h:41
IMAGIChead_old::extra_2
float extra_2[69]
Definition: rwIMAGIC.h:143
IMAGIChead_old::euler_gamma
float euler_gamma
Definition: rwIMAGIC.h:146
IMAGIChead::beta2
float beta2
Definition: rwIMAGIC.h:95
IMAGIChead_old::ixlp
int ixlp
Definition: rwIMAGIC.h:123
IMAGIChead_old
Definition: rwIMAGIC.h:110
IMAGIChead_old::dummy
float dummy[4]
Definition: rwIMAGIC.h:136
Bimage
General image parameter class.
Definition: Bimage.h:163
IMAGIChead::nyintv
int nyintv
Definition: rwIMAGIC.h:55
IMAGIChead_old::nhour
int nhour
Definition: rwIMAGIC.h:118
IMAGIChead::name
char name[80]
Definition: rwIMAGIC.h:45
IMAGIChead::izlp
int izlp
Definition: rwIMAGIC.h:57
IMAGIChead::avdens
float avdens
Definition: rwIMAGIC.h:33
IMAGIChead::ixlp
int ixlp
Definition: rwIMAGIC.h:28
IMAGIChead_old::ierror
int ierror
Definition: rwIMAGIC.h:113
IMAGIChead::oldsigma
float oldsigma
Definition: rwIMAGIC.h:79
IMAGIChead_old::eman_alt
float eman_alt
Definition: rwIMAGIC.h:140
IMAGIChead_old::euler_beta
float euler_beta
Definition: rwIMAGIC.h:145
IMAGIChead::cxlength
float cxlength
Definition: rwIMAGIC.h:40
IMAGIChead::angle
float angle
Definition: rwIMAGIC.h:68
IMAGIChead::oldavd
float oldavd
Definition: rwIMAGIC.h:36
IMAGIChead_old::varian
float varian
Definition: rwIMAGIC.h:130
IMAGIChead_old::npix2
int npix2
Definition: rwIMAGIC.h:121
IMAGIChead_old::ixold
int ixold
Definition: rwIMAGIC.h:126
IMAGIChead::nsec
int nsec
Definition: rwIMAGIC.h:25
IMAGIChead::nmonth
int nmonth
Definition: rwIMAGIC.h:21
IMAGIChead::mapc
int mapc
Definition: rwIMAGIC.h:47
IMAGIChead::czlength
float czlength
Definition: rwIMAGIC.h:42
IMAGIChead::i4lp
int i4lp
Definition: rwIMAGIC.h:58
IMAGIChead::cbeta
float cbeta
Definition: rwIMAGIC.h:44
IMAGIChead_old::avdens
float avdens
Definition: rwIMAGIC.h:128
IMAGIChead::gamma2
float gamma2
Definition: rwIMAGIC.h:96
IMAGIChead::imavers
int imavers
Definition: rwIMAGIC.h:64
readIMAGIC
int readIMAGIC(Bimage *p, int readdata, int img_select)
Reading an IMAGIC image format. A 2D file format for the IMAGIC package. The header is stored in a se...
Definition: rwIMAGIC.cpp:65
IMAGIChead::nzintv
int nzintv
Definition: rwIMAGIC.h:56
IMAGIChead::i5lp
int i5lp
Definition: rwIMAGIC.h:59
IMAGIChead::nystart
int nystart
Definition: rwIMAGIC.h:52
IMAGIChead::nhour
int nhour
Definition: rwIMAGIC.h:23
IMAGIChead_old::iyold
int iyold
Definition: rwIMAGIC.h:127
IMAGIChead::coosmsa
float coosmsa[69]
Definition: rwIMAGIC.h:99
IMAGIChead_old::imn
int imn
Definition: rwIMAGIC.h:111
IMAGIChead::buffer
int buffer[29]
Definition: rwIMAGIC.h:66
IMAGIChead::ixpeak
int ixpeak
Definition: rwIMAGIC.h:70
IMAGIChead::rcp
float rcp
Definition: rwIMAGIC.h:69
IMAGIChead::errar
float errar
Definition: rwIMAGIC.h:73
IMAGIChead::densmin
float densmin
Definition: rwIMAGIC.h:38
IMAGIChead::resoly
float resoly
Definition: rwIMAGIC.h:92
IMAGIChead_old::npixel
int npixel
Definition: rwIMAGIC.h:122
IMAGIChead_old::nyear
int nyear
Definition: rwIMAGIC.h:117
IMAGIChead::npixel
int npixel
Definition: rwIMAGIC.h:27
IMAGIChead_old::proj_weight
float proj_weight
Definition: rwIMAGIC.h:147
IMAGIChead::oldavd2
float oldavd2
Definition: rwIMAGIC.h:78
IMAGIChead_old::densmin
float densmin
Definition: rwIMAGIC.h:133
IMAGIChead::maps
int maps
Definition: rwIMAGIC.h:49
IMAGIChead::ierror
int ierror
Definition: rwIMAGIC.h:18
IMAGIChead::niactive
int niactive
Definition: rwIMAGIC.h:90
IMAGIChead::ispg
int ispg
Definition: rwIMAGIC.h:50
IMAGIChead_old::history
char history[228]
Definition: rwIMAGIC.h:149
IMAGIChead::ccc
float ccc
Definition: rwIMAGIC.h:72
IMAGIChead::gamma
float gamma
Definition: rwIMAGIC.h:63
IMAGIChead::actmsa
float actmsa
Definition: rwIMAGIC.h:98
IMAGIChead::nzstart
int nzstart
Definition: rwIMAGIC.h:53
IMAGIChead::numcls
float numcls
Definition: rwIMAGIC.h:82
IMAGIChead_old::eman_az
float eman_az
Definition: rwIMAGIC.h:141
IMAGIChead::nxstart
int nxstart
Definition: rwIMAGIC.h:51
IMAGIChead_old::nminut
int nminut
Definition: rwIMAGIC.h:119
IMAGIChead_old::densmax
float densmax
Definition: rwIMAGIC.h:132
IMAGIChead_old::type
char type[4]
Definition: rwIMAGIC.h:125
IMAGIChead_old::oldavd
float oldavd
Definition: rwIMAGIC.h:131
IMAGIChead::nxintv
int nxintv
Definition: rwIMAGIC.h:54
IMAGIChead::calpha
float calpha
Definition: rwIMAGIC.h:43
IMAGIChead::history
char history[228]
Definition: rwIMAGIC.h:100
IMAGIChead::informat
float informat
Definition: rwIMAGIC.h:88
IMAGIChead::iypeak
int iypeak
Definition: rwIMAGIC.h:71
rwimg.h
Header file for 2D and 3D image I/O.
IMAGIChead_old::sigma
float sigma
Definition: rwIMAGIC.h:129
IMAGIChead::err3d
float err3d
Definition: rwIMAGIC.h:74
IMAGIChead::ifn
int ifn
Definition: rwIMAGIC.h:17
IMAGIChead::eangle
float eangle
Definition: rwIMAGIC.h:84
IMAGIChead_old::iylp
int iylp
Definition: rwIMAGIC.h:124
IMAGIChead::ronly
int ronly
Definition: rwIMAGIC.h:67
IMAGIChead::imn
int imn
Definition: rwIMAGIC.h:16
IMAGIChead::nyear
int nyear
Definition: rwIMAGIC.h:22
IMAGIChead::mapr
int mapr
Definition: rwIMAGIC.h:48
IMAGIChead::complex
int complex
Definition: rwIMAGIC.h:39
IMAGIChead::densmax
float densmax
Definition: rwIMAGIC.h:37
IMAGIChead
Definition: rwIMAGIC.h:15
IMAGIChead::classno
float classno
Definition: rwIMAGIC.h:76
IMAGIChead::ref
int ref
Definition: rwIMAGIC.h:75
IMAGIChead_old::lastpr
char lastpr[8]
Definition: rwIMAGIC.h:137
IMAGIChead_old::extra_1
float extra_1[8]
Definition: rwIMAGIC.h:139
IMAGIChead::yshift
float yshift
Definition: rwIMAGIC.h:81
IMAGIChead_old::extra_3
float extra_3[66]
Definition: rwIMAGIC.h:148
IMAGIChead::eyshift
float eyshift
Definition: rwIMAGIC.h:86
IMAGIChead::exshift
float exshift
Definition: rwIMAGIC.h:85