0001 function [ ge ] = ge_hdr_read(imageFileName)
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031
0032
0033
0034
0035
0036
0037
0038
0039
0040
0041
0042
0043
0044
0045 fprintf('\nGE_HDR_READ\n'); tic
0046
0047 fprintf('...reading %s\n',imageFileName);
0048
0049
0050 [fid,message] = fopen(imageFileName,'r','b');
0051 if fid == -1, error(message); end
0052
0053
0054 magic = fread(fid,1,'int32');
0055 if magic == 1229801286,
0056
0057 fprintf('...identified Signa 5.X format\n');
0058 byte_align = 0;
0059 ge.hdr.pixel.offset = 0;
0060 ge.hdr.suite.size = 114;
0061 ge.hdr.exam.size = 1024;
0062 ge.hdr.series.size = 1020;
0063 ge.hdr.image.size = 1022;
0064 else
0065
0066 fseek(fid,3228,-1);
0067 magic = fread(fid,1,'int32');
0068 if magic == 1229801286,
0069
0070 fprintf('...identified LX2 format\n');
0071 byte_align = 1;
0072 ge.hdr.pixel.offset = 3228;
0073 ge.hdr.suite.size = 116;
0074 ge.hdr.exam.size = 1040;
0075 ge.hdr.series.size = 1028;
0076 ge.hdr.image.size = 1044;
0077 else
0078 msg = 'This is not a 5.X or LX2 format image. No Magic Number.';
0079 error(msg);
0080 end
0081 end
0082
0083
0084 fseek(fid,ge.hdr.pixel.offset,-1);
0085 ge = ge_readHeaderPixel(fid, byte_align, ge);
0086
0087
0088
0089 if (ge.hdr.pixel.img_l_dbHdr == 0 & byte_align == 0),
0090 error('This is an epirecon image. No header!');
0091 end
0092
0093
0094 ge.hdr.suite.offset = ge.hdr.pixel.img_p_dbHdr;
0095 ge.hdr.exam.offset = ge.hdr.suite.offset + ge.hdr.suite.size;
0096 ge.hdr.series.offset = ge.hdr.exam.offset + ge.hdr.exam.size;
0097 ge.hdr.image.offset = ge.hdr.series.offset + ge.hdr.series.size;
0098 ge.img.offset = ge.hdr.pixel.offset + ge.hdr.pixel.img_hdr_length;
0099
0100
0101
0102
0103 fseek(fid,ge.hdr.suite.offset,-1);
0104 ge.hdr.suite = ge_readHeaderSuite(fid, byte_align);
0105
0106
0107 fseek(fid,ge.hdr.exam.offset,-1);
0108 ge.hdr.exam = ge_readHeaderExam(fid, byte_align);
0109
0110
0111 fseek(fid,ge.hdr.series.offset,-1);
0112 ge.hdr.series = ge_readHeaderSeries(fid, byte_align);
0113
0114
0115 fseek(fid,ge.hdr.image.offset,-1);
0116 ge.hdr.image = ge_readHeaderImage(fid, byte_align);
0117
0118
0119 fclose(fid);
0120
0121 t=toc; fprintf('...done (%5.2f sec).\n',t);
0122
0123 return
0124
0125
0126
0127
0128
0129
0130 function su_hdr = ge_readHeaderSuite(fid, byte_align)
0131
0132
0133
0134
0135
0136
0137
0138
0139 su_hdr = struct('su_id', fread(fid,4,'char'));
0140 su_hdr = setfield(su_hdr, 'su_uniq', fread(fid,1,'int16'));
0141 su_hdr = setfield(su_hdr, 'su_diskid', fread(fid,1,'char'));
0142 su_hdr = setfield(su_hdr, 'prodid', fread(fid,13,'char'));
0143 su_hdr = setfield(su_hdr, 'su_verscre', fread(fid,2,'char'));
0144 su_hdr = setfield(su_hdr, 'su_verscur', fread(fid,2,'char'));
0145 su_hdr = setfield(su_hdr, 'su_checksum', fread(fid,1,'uint32'));
0146 su_hdr = setfield(su_hdr, 'su_padding', fread(fid,85,'char'));
0147 fseek(fid,1,0);
0148 if byte_align, fseek(fid,2,0); end
0149
0150 return
0151
0152
0153
0154
0155
0156
0157
0158 function ex_hdr = ge_readHeaderExam(fid, byte_align)
0159
0160
0161
0162
0163
0164
0165
0166
0167
0168
0169 ex_hdr = struct('ex_suid', fread(fid,4,'uchar'));
0170 ex_hdr = setfield(ex_hdr, 'ex_uniq', fread(fid,1,'int16'));
0171 ex_hdr = setfield(ex_hdr, 'ex_diskid', fread(fid,1,'uchar'));
0172 fseek(fid,1,0);
0173 ex_hdr = setfield(ex_hdr, 'ex_no', fread(fid,1,'uint16'));
0174 ex_hdr = setfield(ex_hdr, 'hospname', fread(fid,33,'uchar'));
0175 fseek(fid,1,0);
0176 ex_hdr = setfield(ex_hdr, 'detect', fread(fid,1,'int16'));
0177 if byte_align; fseek(fid,2,0); end
0178 ex_hdr = setfield(ex_hdr, 'numcells', fread(fid,1,'int32'));
0179 ex_hdr = setfield(ex_hdr, 'zerocell', fread(fid,1,'float32'));
0180 ex_hdr = setfield(ex_hdr, 'cellspace', fread(fid,1,'float32'));
0181 ex_hdr = setfield(ex_hdr, 'srctodet', fread(fid,1,'float32'));
0182 ex_hdr = setfield(ex_hdr, 'srctoiso', fread(fid,1,'float32'));
0183 ex_hdr = setfield(ex_hdr, 'tubetyp', fread(fid,1,'int16'));
0184 ex_hdr = setfield(ex_hdr, 'dastyp', fread(fid,1,'int16'));
0185 ex_hdr = setfield(ex_hdr, 'num_dcnk', fread(fid,1,'int16'));
0186 ex_hdr = setfield(ex_hdr, 'dcn_len', fread(fid,1,'int16'));
0187 ex_hdr = setfield(ex_hdr, 'dcn_density', fread(fid,1,'int16'));
0188 ex_hdr = setfield(ex_hdr, 'dcn_stepsize', fread(fid,1,'int16'));
0189 ex_hdr = setfield(ex_hdr, 'dcn_shiftcnt', fread(fid,1,'int16'));
0190 if byte_align; fseek(fid,2,0); end
0191 ex_hdr = setfield(ex_hdr, 'magstrength', fread(fid,1,'int32'));
0192 ex_hdr = setfield(ex_hdr, 'patid', fread(fid,13,'uchar'));
0193 ex_hdr = setfield(ex_hdr, 'patname', fread(fid,25,'uchar'));
0194 ex_hdr = setfield(ex_hdr, 'patage', fread(fid,1,'int16'));
0195 ex_hdr = setfield(ex_hdr, 'patian', fread(fid,1,'int16'));
0196 ex_hdr = setfield(ex_hdr, 'patsex', fread(fid,1,'int16'));
0197 ex_hdr = setfield(ex_hdr, 'patweight', fread(fid,1,'int32'));
0198 ex_hdr = setfield(ex_hdr, 'trauma', fread(fid,1,'int16'));
0199 ex_hdr = setfield(ex_hdr, 'hist', fread(fid,61,'uchar'));
0200 ex_hdr = setfield(ex_hdr, 'reqnum', fread(fid,13,'uchar'));
0201 ex_hdr = setfield(ex_hdr, 'ex_datetime', fread(fid,1,'int32'));
0202 ex_hdr = setfield(ex_hdr, 'refphy', fread(fid,33,'uchar'));
0203 ex_hdr = setfield(ex_hdr, 'diagrad', fread(fid,33,'uchar'));
0204 ex_hdr = setfield(ex_hdr, 'op', fread(fid,4,'uchar'));
0205 ex_hdr = setfield(ex_hdr, 'ex_desc', fread(fid,23,'uchar'));
0206 ex_hdr = setfield(ex_hdr, 'ex_typ', fread(fid,3,'uchar'));
0207 ex_hdr = setfield(ex_hdr, 'ex_format', fread(fid,1,'int16'));
0208 if byte_align; fseek(fid,6,0); end
0209 ex_hdr = setfield(ex_hdr, 'firstaxtime', fread(fid,1,'float64'));
0210 ex_hdr = setfield(ex_hdr, 'ex_sysid', fread(fid,9,'uchar'));
0211 fseek(fid,1,0);
0212 if byte_align; fseek(fid,2,0); end
0213 ex_hdr = setfield(ex_hdr, 'ex_lastmod', fread(fid,1,'int32'));
0214 ex_hdr = setfield(ex_hdr, 'protocolflag', fread(fid,1,'int16'));
0215 ex_hdr = setfield(ex_hdr, 'ex_alloc_key', fread(fid,13,'uchar'));
0216 fseek(fid,1,0);
0217 ex_hdr = setfield(ex_hdr, 'ex_delta_cnt', fread(fid,1,'int32'));
0218 ex_hdr = setfield(ex_hdr, 'ex_verscre', fread(fid,2,'uchar'));
0219 ex_hdr = setfield(ex_hdr, 'ex_verscur', fread(fid,2,'uchar'));
0220 ex_hdr = setfield(ex_hdr, 'ex_checksum', fread(fid,1,'uint32'));
0221 ex_hdr = setfield(ex_hdr, 'ex_complete', fread(fid,1,'int32'));
0222 ex_hdr = setfield(ex_hdr, 'ex_seriesct', fread(fid,1,'int32'));
0223 ex_hdr = setfield(ex_hdr, 'ex_numarch', fread(fid,1,'int32'));
0224 ex_hdr = setfield(ex_hdr, 'ex_numseries', fread(fid,1,'int32'));
0225 ex_hdr = setfield(ex_hdr, 'ex_series', struct('length', fread(fid,1,'uint32'), ...
0226 'data', fread(fid,1,'uint32')));
0227 ex_hdr = setfield(ex_hdr, 'ex_numunser', fread(fid,1,'int32'));
0228 ex_hdr = setfield(ex_hdr, 'ex_unseries', struct('length', fread(fid,1,'uint32'), ...
0229 'data', fread(fid,1,'uint32')));
0230 ex_hdr = setfield(ex_hdr, 'ex_toarchcnt', fread(fid,1,'int32'));
0231 ex_hdr = setfield(ex_hdr, 'ex_toarchive', struct('length', fread(fid,1,'uint32'), ...
0232 'data', fread(fid,1,'uint32')));
0233 ex_hdr = setfield(ex_hdr, 'ex_prospcnt', fread(fid,1,'int32'));
0234 ex_hdr = setfield(ex_hdr, 'ex_prosp', struct('length', fread(fid,1,'uint32'), ...
0235 'data', fread(fid,1,'uint32')));
0236 ex_hdr = setfield(ex_hdr, 'ex_modelnum', fread(fid,1,'int32'));
0237 ex_hdr = setfield(ex_hdr, 'ex_modelcnt', fread(fid,1,'int32'));
0238 ex_hdr = setfield(ex_hdr, 'ex_models', struct('length', fread(fid,1,'uint32'), ...
0239 'data', fread(fid,1,'uint32')));
0240 ex_hdr = setfield(ex_hdr, 'ex_stat', fread(fid,1,'int16'));
0241 ex_hdr = setfield(ex_hdr, 'uniq_sys_id', fread(fid,16,'uchar'));
0242 ex_hdr = setfield(ex_hdr, 'service_id', fread(fid,16,'uchar'));
0243 ex_hdr = setfield(ex_hdr, 'mobile_loc', fread(fid,4,'uchar'));
0244 ex_hdr = setfield(ex_hdr, 'study_uid', fread(fid,32,'uchar'));
0245 ex_hdr = setfield(ex_hdr, 'study_status', fread(fid,1,'int16'));
0246 ex_hdr = setfield(ex_hdr, 'ex_padding', fread(fid,516,'uchar'));
0247 if byte_align; fseek(fid,4,0); end
0248
0249 return
0250
0251
0252
0253
0254
0255
0256
0257 function se_hdr = ge_readHeaderSeries(fid, byte_align)
0258
0259
0260
0261
0262
0263
0264
0265
0266 se_hdr = struct('se_suid', fread(fid,4,'uchar'));
0267 se_hdr = setfield(se_hdr, 'se_uniq', fread(fid,1,'int16'));
0268 se_hdr = setfield(se_hdr, 'se_diskid', fread(fid,1,'uchar'));
0269 fseek(fid,1,0);
0270 se_hdr = setfield(se_hdr, 'se_exno', fread(fid,1,'uint16'));
0271 se_hdr = setfield(se_hdr, 'se_no ', fread(fid,1,'int16'));
0272 se_hdr = setfield(se_hdr, 'se_datetime', fread(fid,1,'int32'));
0273 se_hdr = setfield(se_hdr, 'se_actual_dt', fread(fid,1,'int32'));
0274 se_hdr = setfield(se_hdr, 'se_desc', fread(fid,30,'uchar'));
0275 se_hdr = setfield(se_hdr, 'pr_sysid', fread(fid,9,'uchar'));
0276 se_hdr = setfield(se_hdr, 'pansysid', fread(fid,9,'uchar'));
0277 se_hdr = setfield(se_hdr, 'se_typ ', fread(fid,1,'int16'));
0278 se_hdr = setfield(se_hdr, 'se_source ', fread(fid,1,'int16'));
0279 se_hdr = setfield(se_hdr, 'se_plane ', fread(fid,1,'int16'));
0280 se_hdr = setfield(se_hdr, 'scan_type ', fread(fid,1,'int16'));
0281 se_hdr = setfield(se_hdr, 'position', fread(fid,1,'int32'));
0282 se_hdr = setfield(se_hdr, 'entry', fread(fid,1,'int32'));
0283 se_hdr = setfield(se_hdr, 'anref', fread(fid,3,'uchar'));
0284 fseek(fid,1,0);
0285 se_hdr = setfield(se_hdr, 'lmhor', fread(fid,1,'float32'));
0286 se_hdr = setfield(se_hdr, 'prtcl', fread(fid,25,'uchar'));
0287 fseek(fid,1,0);
0288 se_hdr = setfield(se_hdr, 'se_contrast ', fread(fid,1,'int16'));
0289 se_hdr = setfield(se_hdr, 'start_ras', fread(fid,1,'uchar'));
0290 fseek(fid,1,0);
0291 if byte_align; fseek(fid,2,0); end
0292 se_hdr = setfield(se_hdr, 'start_loc', fread(fid,1,'float32'));
0293 se_hdr = setfield(se_hdr, 'end_ras', fread(fid,1,'uchar'));
0294 fseek(fid,1,0);
0295 if byte_align; fseek(fid,2,0); end
0296 se_hdr = setfield(se_hdr, 'end_loc', fread(fid,1,'float32'));
0297 se_hdr = setfield(se_hdr, 'se_pseq ', fread(fid,1,'int16'));
0298 se_hdr = setfield(se_hdr, 'se_sortorder ', fread(fid,1,'int16'));
0299 se_hdr = setfield(se_hdr, 'se_lndmrkcnt', fread(fid,1,'int32'));
0300 se_hdr = setfield(se_hdr, 'se_nacq ', fread(fid,1,'int16'));
0301 se_hdr = setfield(se_hdr, 'xbasest ', fread(fid,1,'int16'));
0302 se_hdr = setfield(se_hdr, 'xbaseend', fread(fid,1,'int16'));
0303 se_hdr = setfield(se_hdr, 'xenhst', fread(fid,1,'int16'));
0304 se_hdr = setfield(se_hdr, 'xenhend', fread(fid,1,'int16'));
0305 if byte_align; fseek(fid,2,0); end
0306 se_hdr = setfield(se_hdr, 'se_lastmod', fread(fid,1,'int32'));
0307 se_hdr = setfield(se_hdr, 'se_alloc_key', fread(fid,13,'uchar'));
0308 fseek(fid,1,0);
0309 if byte_align; fseek(fid,2,0); end
0310 se_hdr = setfield(se_hdr, 'se_delta_cnt', fread(fid,1,'int32'));
0311 se_hdr = setfield(se_hdr, 'se_verscre', fread(fid,2,'uchar'));
0312 se_hdr = setfield(se_hdr, 'se_verscur', fread(fid,2,'uchar'));
0313 se_hdr = setfield(se_hdr, 'se_pds_a', fread(fid,1,'float32'));
0314 se_hdr = setfield(se_hdr, 'se_pds_c', fread(fid,1,'float32'));
0315 se_hdr = setfield(se_hdr, 'se_pds_u', fread(fid,1,'float32'));
0316 se_hdr = setfield(se_hdr, 'se_checksum', fread(fid,1,'uint32'));
0317 se_hdr = setfield(se_hdr, 'se_complete', fread(fid,1,'int32'));
0318 se_hdr = setfield(se_hdr, 'se_numarch', fread(fid,1,'int32'));
0319 se_hdr = setfield(se_hdr, 'se_imagect', fread(fid,1,'int32'));
0320 se_hdr = setfield(se_hdr, 'se_numimages', fread(fid,1,'int32'));
0321 se_hdr = setfield(se_hdr, 'se_images', struct('length', fread(fid,1,'uint32'), ...
0322 'data', fread(fid,1,'uint32')));
0323 se_hdr = setfield(se_hdr, 'se_numunimg', fread(fid,1,'int32'));
0324 se_hdr = setfield(se_hdr, 'se_unimages', struct('length', fread(fid,1,'uint32'), ...
0325 'data', fread(fid,1,'uint32')));
0326 se_hdr = setfield(se_hdr, 'se_toarchcnt', fread(fid,1,'int32'));
0327 se_hdr = setfield(se_hdr, 'se_toarchive', struct('length', fread(fid,1,'uint32'), ...
0328 'data', fread(fid,1,'uint32')));
0329 se_hdr = setfield(se_hdr, 'echo1_alpha', fread(fid,1,'float32'));
0330 se_hdr = setfield(se_hdr, 'echo1_beta', fread(fid,1,'float32'));
0331 se_hdr = setfield(se_hdr, 'echo1_window', fread(fid,1,'uint16'));
0332 se_hdr = setfield(se_hdr, 'echo1_level', fread(fid,1,'int16'));
0333 se_hdr = setfield(se_hdr, 'echo2_alpha', fread(fid,1,'float32'));
0334 se_hdr = setfield(se_hdr, 'echo2_beta', fread(fid,1,'float32'));
0335 se_hdr = setfield(se_hdr, 'echo2_window', fread(fid,1,'uint16'));
0336 se_hdr = setfield(se_hdr, 'echo2_level', fread(fid,1,'int16'));
0337 se_hdr = setfield(se_hdr, 'echo3_alpha', fread(fid,1,'float32'));
0338 se_hdr = setfield(se_hdr, 'echo3_beta', fread(fid,1,'float32'));
0339 se_hdr = setfield(se_hdr, 'echo3_window', fread(fid,1,'uint16'));
0340 se_hdr = setfield(se_hdr, 'echo3_level', fread(fid,1,'int16'));
0341 se_hdr = setfield(se_hdr, 'echo4_alpha', fread(fid,1,'float32'));
0342 se_hdr = setfield(se_hdr, 'echo4_beta', fread(fid,1,'float32'));
0343 se_hdr = setfield(se_hdr, 'echo4_window', fread(fid,1,'uint16'));
0344 se_hdr = setfield(se_hdr, 'echo4_level', fread(fid,1,'int16'));
0345 se_hdr = setfield(se_hdr, 'echo5_alpha', fread(fid,1,'float32'));
0346 se_hdr = setfield(se_hdr, 'echo5_beta', fread(fid,1,'float32'));
0347 se_hdr = setfield(se_hdr, 'echo5_window', fread(fid,1,'uint16'));
0348 se_hdr = setfield(se_hdr, 'echo5_level', fread(fid,1,'int16'));
0349 se_hdr = setfield(se_hdr, 'echo6_alpha', fread(fid,1,'float32'));
0350 se_hdr = setfield(se_hdr, 'echo6_beta', fread(fid,1,'float32'));
0351 se_hdr = setfield(se_hdr, 'echo6_window', fread(fid,1,'uint16'));
0352 se_hdr = setfield(se_hdr, 'echo6_level', fread(fid,1,'int16'));
0353 se_hdr = setfield(se_hdr, 'echo7_alpha', fread(fid,1,'float32'));
0354 se_hdr = setfield(se_hdr, 'echo7_beta', fread(fid,1,'float32'));
0355 se_hdr = setfield(se_hdr, 'echo7_window', fread(fid,1,'uint16'));
0356 se_hdr = setfield(se_hdr, 'echo7_level', fread(fid,1,'int16'));
0357 se_hdr = setfield(se_hdr, 'echo8_alpha', fread(fid,1,'float32'));
0358 se_hdr = setfield(se_hdr, 'echo8_beta', fread(fid,1,'float32'));
0359 se_hdr = setfield(se_hdr, 'echo8_window', fread(fid,1,'uint16'));
0360 se_hdr = setfield(se_hdr, 'echo8_level', fread(fid,1,'int16'));
0361 se_hdr = setfield(se_hdr, 'series_uid', fread(fid,32,'uchar'));
0362 se_hdr = setfield(se_hdr, 'landmark_uid', fread(fid,32,'uchar'));
0363 se_hdr = setfield(se_hdr, 'equipmnt_uid', fread(fid,32,'uchar'));
0364 se_hdr = setfield(se_hdr, 'se_padding', fread(fid,588,'uchar'));
0365
0366 return
0367
0368
0369
0370
0371
0372
0373 function im_hdr = ge_readHeaderImage(fid, byte_align)
0374
0375
0376
0377
0378
0379
0380
0381
0382
0383 im_hdr = struct('im_suid', fread(fid,4,'uchar'));
0384 im_hdr = setfield(im_hdr, 'im_uniq', fread(fid,1,'int16'));
0385 im_hdr = setfield(im_hdr, 'im_diskid', fread(fid,1,'uchar'));
0386 fseek(fid, 1, 0);
0387 im_hdr = setfield(im_hdr, 'im_exno', fread(fid,1,'uint16'));
0388 im_hdr = setfield(im_hdr, 'im_seno', fread(fid,1,'int16'));
0389 im_hdr = setfield(im_hdr, 'im_no', fread(fid,1,'int16'));
0390 if byte_align; fseek(fid, 2, 0); end
0391 im_hdr = setfield(im_hdr, 'im_datetime', fread(fid,1,'int32'));
0392 im_hdr = setfield(im_hdr, 'im_actual_dt', fread(fid,1,'int32'));
0393 im_hdr = setfield(im_hdr, 'sctime', fread(fid,1,'float32'));
0394 im_hdr = setfield(im_hdr, 'slthick', fread(fid,1,'float32'));
0395 im_hdr = setfield(im_hdr, 'imatrix_X', fread(fid,1,'int16'));
0396 im_hdr = setfield(im_hdr, 'imatrix_Y', fread(fid,1,'int16'));
0397 im_hdr = setfield(im_hdr, 'dfov', fread(fid,1,'float32'));
0398 im_hdr = setfield(im_hdr, 'dfov_rect', fread(fid,1,'float32'));
0399 im_hdr = setfield(im_hdr, 'dim_X', fread(fid,1,'float32'));
0400 im_hdr = setfield(im_hdr, 'dim_Y', fread(fid,1,'float32'));
0401 im_hdr = setfield(im_hdr, 'pixsize_X', fread(fid,1,'float32'));
0402 im_hdr = setfield(im_hdr, 'pixsize_Y', fread(fid,1,'float32'));
0403 im_hdr = setfield(im_hdr, 'pdid', fread(fid,14,'uchar'));
0404 im_hdr = setfield(im_hdr, 'contrastIV', fread(fid,17,'uchar'));
0405 im_hdr = setfield(im_hdr, 'contrastOral', fread(fid,17,'uchar'));
0406 im_hdr = setfield(im_hdr, 'contmode', fread(fid,1,'int16'));
0407 im_hdr = setfield(im_hdr, 'serrx', fread(fid,1,'int16'));
0408 im_hdr = setfield(im_hdr, 'imgrx', fread(fid,1,'int16'));
0409 im_hdr = setfield(im_hdr, 'screenformat', fread(fid,1,'int16'));
0410 im_hdr = setfield(im_hdr, 'plane', fread(fid,1,'int16'));
0411 if byte_align; fseek(fid, 2, 0); end
0412 im_hdr = setfield(im_hdr, 'scanspacing', fread(fid,1,'float32'));
0413 im_hdr = setfield(im_hdr, 'im_compress', fread(fid,1,'int16'));
0414 im_hdr = setfield(im_hdr, 'im_scouttype', fread(fid,1,'int16'));
0415 im_hdr = setfield(im_hdr, 'loc_ras', fread(fid,1,'uchar'));
0416 fseek(fid, 1, 0);
0417 if byte_align; fseek(fid, 2, 0); end
0418 im_hdr = setfield(im_hdr, 'loc', fread(fid,1,'float32'));
0419 im_hdr = setfield(im_hdr, 'ctr_R', fread(fid,1,'float32'));
0420 im_hdr = setfield(im_hdr, 'ctr_A', fread(fid,1,'float32'));
0421 im_hdr = setfield(im_hdr, 'ctr_S', fread(fid,1,'float32'));
0422 im_hdr = setfield(im_hdr, 'norm_R', fread(fid,1,'float32'));
0423 im_hdr = setfield(im_hdr, 'norm_A', fread(fid,1,'float32'));
0424 im_hdr = setfield(im_hdr, 'norm_S', fread(fid,1,'float32'));
0425 im_hdr = setfield(im_hdr, 'tlhc_R', fread(fid,1,'float32'));
0426 im_hdr = setfield(im_hdr, 'tlhc_A', fread(fid,1,'float32'));
0427 im_hdr = setfield(im_hdr, 'tlhc_S', fread(fid,1,'float32'));
0428 im_hdr = setfield(im_hdr, 'trhc_R', fread(fid,1,'float32'));
0429 im_hdr = setfield(im_hdr, 'trhc_A', fread(fid,1,'float32'));
0430 im_hdr = setfield(im_hdr, 'trhc_S', fread(fid,1,'float32'));
0431 im_hdr = setfield(im_hdr, 'brhc_R', fread(fid,1,'float32'));
0432 im_hdr = setfield(im_hdr, 'brhc_A', fread(fid,1,'float32'));
0433 im_hdr = setfield(im_hdr, 'brhc_S', fread(fid,1,'float32'));
0434 im_hdr = setfield(im_hdr, 'forimgrev', fread(fid,4,'uchar'));
0435 im_hdr = setfield(im_hdr, 'tr', fread(fid,1,'int32'));
0436 im_hdr = setfield(im_hdr, 'ti', fread(fid,1,'int32'));
0437 im_hdr = setfield(im_hdr, 'te', fread(fid,1,'int32'));
0438 im_hdr = setfield(im_hdr, 'te2', fread(fid,1,'int32'));
0439 im_hdr = setfield(im_hdr, 'numecho', fread(fid,1,'int16'));
0440 im_hdr = setfield(im_hdr, 'echonum', fread(fid,1,'int16'));
0441 im_hdr = setfield(im_hdr, 'tbldlta', fread(fid,1,'float32'));
0442 im_hdr = setfield(im_hdr, 'nex', fread(fid,1,'float32'));
0443 im_hdr = setfield(im_hdr, 'contig', fread(fid,1,'int16'));
0444 im_hdr = setfield(im_hdr, 'hrtrate', fread(fid,1,'int16'));
0445 im_hdr = setfield(im_hdr, 'tdel', fread(fid,1,'int32'));
0446 im_hdr = setfield(im_hdr, 'saravg', fread(fid,1,'float32'));
0447 im_hdr = setfield(im_hdr, 'sarpeak', fread(fid,1,'float32'));
0448 im_hdr = setfield(im_hdr, 'monsar', fread(fid,1,'int16'));
0449 im_hdr = setfield(im_hdr, 'trgwindow', fread(fid,1,'int16'));
0450 im_hdr = setfield(im_hdr, 'reptime', fread(fid,1,'float32'));
0451 im_hdr = setfield(im_hdr, 'imgpcyc', fread(fid,1,'int16'));
0452 im_hdr = setfield(im_hdr, 'xmtgain', fread(fid,1,'int16'));
0453 im_hdr = setfield(im_hdr, 'rcvgain1', fread(fid,1,'int16'));
0454 im_hdr = setfield(im_hdr, 'rcvgain2', fread(fid,1,'int16'));
0455 im_hdr = setfield(im_hdr, 'mr_flip', fread(fid,1,'int16'));
0456 if byte_align; fseek(fid, 2, 0); end
0457 im_hdr = setfield(im_hdr, 'mindat', fread(fid,1,'int32'));
0458 im_hdr = setfield(im_hdr, 'cphase', fread(fid,1,'int16'));
0459 im_hdr = setfield(im_hdr, 'swappf', fread(fid,1,'int16'));
0460 im_hdr = setfield(im_hdr, 'pauseint', fread(fid,1,'int16'));
0461 if byte_align; fseek(fid, 2, 0); end
0462 im_hdr = setfield(im_hdr, 'pausetime', fread(fid,1,'float32'));
0463 im_hdr = setfield(im_hdr, 'obplane', fread(fid,1,'int32'));
0464 im_hdr = setfield(im_hdr, 'slocfov', fread(fid,1,'int32'));
0465 im_hdr = setfield(im_hdr, 'xmtfreq', fread(fid,1,'int32'));
0466 im_hdr = setfield(im_hdr, 'autoxmtfreq', fread(fid,1,'int32'));
0467 im_hdr = setfield(im_hdr, 'autoxmtgain', fread(fid,1,'int16'));
0468 im_hdr = setfield(im_hdr, 'prescan_r1', fread(fid,1,'int16'));
0469 im_hdr = setfield(im_hdr, 'prescan_r2', fread(fid,1,'int16'));
0470 if byte_align; fseek(fid, 2, 0); end
0471 im_hdr = setfield(im_hdr, 'user_bitmap', fread(fid,1,'int32'));
0472 im_hdr = setfield(im_hdr, 'cenfreq', fread(fid,1,'int16'));
0473 im_hdr = setfield(im_hdr, 'imode', fread(fid,1,'int16'));
0474 im_hdr = setfield(im_hdr, 'iopt', fread(fid,1,'int32'));
0475 im_hdr = setfield(im_hdr, 'pseq', fread(fid,1,'int16'));
0476 im_hdr = setfield(im_hdr, 'pseqmode', fread(fid,1,'int16'));
0477 im_hdr = setfield(im_hdr, 'psdname', fread(fid,33,'uchar'));
0478 fseek(fid,1,0);
0479 if byte_align; fseek(fid, 2, 0); end
0480 im_hdr = setfield(im_hdr, 'psd_datetime', fread(fid,1,'int32'));
0481 im_hdr = setfield(im_hdr, 'psd_iname', fread(fid,13,'uchar'));
0482 fseek(fid, 1, 0);
0483 im_hdr = setfield(im_hdr, 'ctyp', fread(fid,1,'int16'));
0484 im_hdr = setfield(im_hdr, 'cname', fread(fid,17,'uchar'));
0485 fseek(fid, 1, 0);
0486 im_hdr = setfield(im_hdr, 'surfctyp', fread(fid,1,'int16'));
0487 im_hdr = setfield(im_hdr, 'surfcext', fread(fid,1,'int16'));
0488 if byte_align; fseek(fid, 2, 0); end
0489 im_hdr = setfield(im_hdr, 'rawrunnum', fread(fid,1,'int32'));
0490 im_hdr = setfield(im_hdr, 'cal_fldstr', fread(fid,1,'uint32'));
0491 im_hdr = setfield(im_hdr, 'supp_tech', fread(fid,1,'int16'));
0492 if byte_align; fseek(fid, 2, 0); end
0493 im_hdr = setfield(im_hdr, 'vbw', fread(fid,1,'float32'));
0494 im_hdr = setfield(im_hdr, 'slquant', fread(fid,1,'int16'));
0495 im_hdr = setfield(im_hdr, 'gpre', fread(fid,1,'int16'));
0496 im_hdr = setfield(im_hdr, 'intr_del', fread(fid,1,'int32'));
0497 im_hdr = setfield(im_hdr, 'user0', fread(fid,1,'float32'));
0498 im_hdr = setfield(im_hdr, 'user1', fread(fid,1,'float32'));
0499 im_hdr = setfield(im_hdr, 'user2', fread(fid,1,'float32'));
0500 im_hdr = setfield(im_hdr, 'user3', fread(fid,1,'float32'));
0501 im_hdr = setfield(im_hdr, 'user4', fread(fid,1,'float32'));
0502 im_hdr = setfield(im_hdr, 'user5', fread(fid,1,'float32'));
0503 im_hdr = setfield(im_hdr, 'user6', fread(fid,1,'float32'));
0504 im_hdr = setfield(im_hdr, 'user7', fread(fid,1,'float32'));
0505 im_hdr = setfield(im_hdr, 'user8', fread(fid,1,'float32'));
0506 im_hdr = setfield(im_hdr, 'user9', fread(fid,1,'float32'));
0507 im_hdr = setfield(im_hdr, 'user10', fread(fid,1,'float32'));
0508 im_hdr = setfield(im_hdr, 'user11', fread(fid,1,'float32'));
0509 im_hdr = setfield(im_hdr, 'user12', fread(fid,1,'float32'));
0510 im_hdr = setfield(im_hdr, 'user13', fread(fid,1,'float32'));
0511 im_hdr = setfield(im_hdr, 'user14', fread(fid,1,'float32'));
0512 im_hdr = setfield(im_hdr, 'user15', fread(fid,1,'float32'));
0513 im_hdr = setfield(im_hdr, 'user16', fread(fid,1,'float32'));
0514 im_hdr = setfield(im_hdr, 'user17', fread(fid,1,'float32'));
0515 im_hdr = setfield(im_hdr, 'user18', fread(fid,1,'float32'));
0516 im_hdr = setfield(im_hdr, 'user19', fread(fid,1,'float32'));
0517 im_hdr = setfield(im_hdr, 'user20', fread(fid,1,'float32'));
0518 im_hdr = setfield(im_hdr, 'user21', fread(fid,1,'float32'));
0519 im_hdr = setfield(im_hdr, 'user22', fread(fid,1,'float32'));
0520 im_hdr = setfield(im_hdr, 'user23', fread(fid,1,'float32'));
0521 im_hdr = setfield(im_hdr, 'user24', fread(fid,1,'float32'));
0522 im_hdr = setfield(im_hdr, 'im_alloc_key', fread(fid,13,'uchar'));
0523 fseek(fid, 1, 0);
0524 if byte_align; fseek(fid, 2, 0); end
0525 im_hdr = setfield(im_hdr, 'im_lastmod', fread(fid,1,'int32'));
0526 im_hdr = setfield(im_hdr, 'im_verscre', fread(fid,2,'uchar'));
0527 im_hdr = setfield(im_hdr, 'im_verscur', fread(fid,2,'uchar'));
0528 im_hdr = setfield(im_hdr, 'im_pds_a', fread(fid,1,'int32'));
0529 im_hdr = setfield(im_hdr, 'im_pds_c', fread(fid,1,'int32'));
0530 im_hdr = setfield(im_hdr, 'im_pds_u', fread(fid,1,'int32'));
0531 im_hdr = setfield(im_hdr, 'im_checksum', fread(fid,1,'int32'));
0532 im_hdr = setfield(im_hdr, 'im_archived', fread(fid,1,'int32'));
0533 im_hdr = setfield(im_hdr, 'im_complete', fread(fid,1,'int32'));
0534 im_hdr = setfield(im_hdr, 'satbits', fread(fid,1,'int16'));
0535 im_hdr = setfield(im_hdr, 'scic', fread(fid,1,'int16'));
0536 im_hdr = setfield(im_hdr, 'satxloc1', fread(fid,1,'int16'));
0537 im_hdr = setfield(im_hdr, 'satxloc2', fread(fid,1,'int16'));
0538 im_hdr = setfield(im_hdr, 'satyloc1', fread(fid,1,'int16'));
0539 im_hdr = setfield(im_hdr, 'satyloc2', fread(fid,1,'int16'));
0540 im_hdr = setfield(im_hdr, 'satzloc1', fread(fid,1,'int16'));
0541 im_hdr = setfield(im_hdr, 'satzloc2', fread(fid,1,'int16'));
0542 im_hdr = setfield(im_hdr, 'satxthick', fread(fid,1,'int16'));
0543 im_hdr = setfield(im_hdr, 'satythick', fread(fid,1,'int16'));
0544 im_hdr = setfield(im_hdr, 'satzthick', fread(fid,1,'int16'));
0545 im_hdr = setfield(im_hdr, 'flax', fread(fid,1,'int16'));
0546 im_hdr = setfield(im_hdr, 'venc', fread(fid,1,'int16'));
0547 im_hdr = setfield(im_hdr, 'thk_disclmr', fread(fid,1,'int16'));
0548 im_hdr = setfield(im_hdr, 'ps_flag', fread(fid,1,'int16'));
0549 im_hdr = setfield(im_hdr, 'ps_status', fread(fid,1,'int16'));
0550 im_hdr = setfield(im_hdr, 'image_type', fread(fid,1,'int16'));
0551 im_hdr = setfield(im_hdr, 'vas_collapse', fread(fid,1,'int16'));
0552 im_hdr = setfield(im_hdr, 'user23n', fread(fid,1,'float32'));
0553 im_hdr = setfield(im_hdr, 'user24n', fread(fid,1,'float32'));
0554 im_hdr = setfield(im_hdr, 'proj_alg', fread(fid,1,'int16'));
0555 im_hdr = setfield(im_hdr, 'proj_name', fread(fid,13,'uchar'));
0556 fseek(fid, 1, 0);
0557 im_hdr = setfield(im_hdr, 'x_axis_rot', fread(fid,1,'float32'));
0558 im_hdr = setfield(im_hdr, 'y_axis_rot', fread(fid,1,'float32'));
0559 im_hdr = setfield(im_hdr, 'z_axis_rot', fread(fid,1,'float32'));
0560 im_hdr = setfield(im_hdr, 'thresh_min1', fread(fid,1,'int32'));
0561 im_hdr = setfield(im_hdr, 'thresh_max1', fread(fid,1,'int32'));
0562 im_hdr = setfield(im_hdr, 'thresh_min2', fread(fid,1,'int32'));
0563 im_hdr = setfield(im_hdr, 'thresh_max2', fread(fid,1,'int32'));
0564 im_hdr = setfield(im_hdr, 'echo_trn_len', fread(fid,1,'int16'));
0565 im_hdr = setfield(im_hdr, 'frac_echo', fread(fid,1,'int16'));
0566 im_hdr = setfield(im_hdr, 'prep_pulse', fread(fid,1,'int16'));
0567 im_hdr = setfield(im_hdr, 'cphasenum', fread(fid,1,'int16'));
0568 im_hdr = setfield(im_hdr, 'var_echo', fread(fid,1,'int16'));
0569 im_hdr = setfield(im_hdr, 'ref_img', fread(fid,1,'uchar'));
0570 im_hdr = setfield(im_hdr, 'sum_img', fread(fid,1,'uchar'));
0571 im_hdr = setfield(im_hdr, 'img_window', fread(fid,1,'uint16'));
0572 im_hdr = setfield(im_hdr, 'img_level', fread(fid,1,'int16'));
0573 im_hdr = setfield(im_hdr, 'slop_int_1', fread(fid,1,'int32'));
0574 im_hdr = setfield(im_hdr, 'slop_int_2', fread(fid,1,'int32'));
0575 im_hdr = setfield(im_hdr, 'slop_int_3', fread(fid,1,'int32'));
0576 im_hdr = setfield(im_hdr, 'slop_int_4', fread(fid,1,'int32'));
0577 im_hdr = setfield(im_hdr, 'slop_int_5', fread(fid,1,'int32'));
0578 im_hdr = setfield(im_hdr, 'slop_float_1', fread(fid,1,'float32'));
0579 im_hdr = setfield(im_hdr, 'slop_float_2', fread(fid,1,'float32'));
0580 im_hdr = setfield(im_hdr, 'slop_float_3', fread(fid,1,'float32'));
0581 im_hdr = setfield(im_hdr, 'slop_float_4', fread(fid,1,'float32'));
0582 im_hdr = setfield(im_hdr, 'slop_float_5', fread(fid,1,'float32'));
0583 im_hdr = setfield(im_hdr, 'slop_str_1', fread(fid,16,'uchar'));
0584 im_hdr = setfield(im_hdr, 'slop_str_2', fread(fid,16,'uchar'));
0585 im_hdr = setfield(im_hdr, 'scanactno', fread(fid,1,'int16'));
0586 im_hdr = setfield(im_hdr, 'vasflags', fread(fid,1,'int16'));
0587 im_hdr = setfield(im_hdr, 'vencscale', fread(fid,1,'float32'));
0588 im_hdr = setfield(im_hdr, 'integrity', fread(fid,1,'int16'));
0589 if byte_align; fseek(fid, 2, 0); end
0590 im_hdr = setfield(im_hdr, 'fphase', fread(fid,1,'int32'));
0591 im_hdr = setfield(im_hdr, 'freq_dir', fread(fid,1,'int16'));
0592 im_hdr = setfield(im_hdr, 'vas_mode', fread(fid,1,'int16'));
0593 im_hdr = setfield(im_hdr, 'image_uid', fread(fid,32,'uchar'));
0594 im_hdr = setfield(im_hdr, 'sop_uid', fread(fid,32,'uchar'));
0595 im_hdr = setfield(im_hdr, 'dont_use_1', fread(fid,1,'int16'));
0596 im_hdr = setfield(im_hdr, 'dont_use_2', fread(fid,1,'int16'));
0597 im_hdr = setfield(im_hdr, 'dont_use_3', fread(fid,1,'int16'));
0598 im_hdr = setfield(im_hdr, 'pscopts', fread(fid,1,'int16'));
0599 im_hdr = setfield(im_hdr, 'asoffsetx', fread(fid,1,'int16'));
0600 im_hdr = setfield(im_hdr, 'asoffsety', fread(fid,1,'int16'));
0601 im_hdr = setfield(im_hdr, 'asoffsetz', fread(fid,1,'int16'));
0602 im_hdr = setfield(im_hdr, 'unoriginal', fread(fid,1,'int16'));
0603 im_hdr = setfield(im_hdr, 'interleaves', fread(fid,1,'int16'));
0604 im_hdr = setfield(im_hdr, 'effechospace', fread(fid,1,'int16'));
0605 im_hdr = setfield(im_hdr, 'viewsperseg', fread(fid,1,'int16'));
0606 im_hdr = setfield(im_hdr, 'rbpm', fread(fid,1,'int16'));
0607 im_hdr = setfield(im_hdr, 'rtpoint', fread(fid,1,'int16'));
0608 im_hdr = setfield(im_hdr, 'rcvrtype', fread(fid,1,'int16'));
0609 im_hdr = setfield(im_hdr, 'dbdt', fread(fid,1,'float32'));
0610 im_hdr = setfield(im_hdr, 'dbdtper', fread(fid,1,'float32'));
0611 im_hdr = setfield(im_hdr, 'estdbdtper', fread(fid,1,'float32'));
0612 im_hdr = setfield(im_hdr, 'estdbdtts', fread(fid,1,'float32'));
0613 im_hdr = setfield(im_hdr, 'saravghead', fread(fid,1,'float32'));
0614 im_hdr = setfield(im_hdr, 'neg_scanspacing', fread(fid,1,'float32'));
0615 im_hdr = setfield(im_hdr, 'offsetfreq', fread(fid,1,'int32'));
0616 im_hdr = setfield(im_hdr, 'user_usage_tag', fread(fid,1,'uint32'));
0617
0618
0619
0620 im_hdr = setfield(im_hdr, 'user_fill_mapMSW', fread(fid,1,'uint32'));
0621 im_hdr = setfield(im_hdr, 'user_fill_mapLSW', fread(fid,1,'uint32'));
0622 im_hdr = setfield(im_hdr, 'user25', fread(fid,1,'float32'));
0623 im_hdr = setfield(im_hdr, 'user26', fread(fid,1,'float32'));
0624 im_hdr = setfield(im_hdr, 'user27', fread(fid,1,'float32'));
0625 im_hdr = setfield(im_hdr, 'user28', fread(fid,1,'float32'));
0626 im_hdr = setfield(im_hdr, 'user29', fread(fid,1,'float32'));
0627 im_hdr = setfield(im_hdr, 'user30', fread(fid,1,'float32'));
0628 im_hdr = setfield(im_hdr, 'user31', fread(fid,1,'float32'));
0629 im_hdr = setfield(im_hdr, 'user32', fread(fid,1,'float32'));
0630 im_hdr = setfield(im_hdr, 'user33', fread(fid,1,'float32'));
0631 im_hdr = setfield(im_hdr, 'user34', fread(fid,1,'float32'));
0632 im_hdr = setfield(im_hdr, 'user35', fread(fid,1,'float32'));
0633 im_hdr = setfield(im_hdr, 'user36', fread(fid,1,'float32'));
0634 im_hdr = setfield(im_hdr, 'user37', fread(fid,1,'float32'));
0635 im_hdr = setfield(im_hdr, 'user38', fread(fid,1,'float32'));
0636 im_hdr = setfield(im_hdr, 'user39', fread(fid,1,'float32'));
0637 im_hdr = setfield(im_hdr, 'user40', fread(fid,1,'float32'));
0638 im_hdr = setfield(im_hdr, 'user41', fread(fid,1,'float32'));
0639 im_hdr = setfield(im_hdr, 'user42', fread(fid,1,'float32'));
0640 im_hdr = setfield(im_hdr, 'user43', fread(fid,1,'float32'));
0641 im_hdr = setfield(im_hdr, 'user44', fread(fid,1,'float32'));
0642 im_hdr = setfield(im_hdr, 'user45', fread(fid,1,'float32'));
0643 im_hdr = setfield(im_hdr, 'user46', fread(fid,1,'float32'));
0644 im_hdr = setfield(im_hdr, 'user47', fread(fid,1,'float32'));
0645 im_hdr = setfield(im_hdr, 'user48', fread(fid,1,'float32'));
0646 im_hdr = setfield(im_hdr, 'slop_int_6', fread(fid,1,'int32'));
0647 im_hdr = setfield(im_hdr, 'slop_int_7', fread(fid,1,'int32'));
0648 im_hdr = setfield(im_hdr, 'slop_int_8', fread(fid,1,'int32'));
0649 im_hdr = setfield(im_hdr, 'slop_int_9', fread(fid,1,'int32'));
0650 im_hdr = setfield(im_hdr, 'mr_padding', fread(fid,32,'uchar'));
0651
0652 return
0653
0654
0655
0656
0657
0658
0659
0660 function ge = ge_readHeaderPixel(fid, byte_align, ge)
0661
0662
0663
0664
0665
0666
0667 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_magic', fread(fid,1,'int32'));
0668 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_hdr_length', fread(fid,1,'int32'));
0669
0670 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_width', fread(fid,1,'int32'));
0671 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_height', fread(fid,1,'int32'));
0672 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_depth', fread(fid,1,'int32'));
0673 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_compress', fread(fid,1,'int32'));
0674 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_dwindow', fread(fid,1,'int32'));
0675 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_dlevel', fread(fid,1,'int32'));
0676 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_bgshade', fread(fid,1,'int32'));
0677 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_ovrflow', fread(fid,1,'int32'));
0678 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_undflow', fread(fid,1,'int32'));
0679 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_top_offset', fread(fid,1,'int32'));
0680 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_bot_offset', fread(fid,1,'int32'));
0681 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_version', fread(fid,1,'int16'));
0682 if byte_align, fseek(fid,2,0); end
0683 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_checksum', fread(fid,1,'uint16'));
0684 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_p_id', fread(fid,1,'int32'));
0685 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_l_id', fread(fid,1,'int32'));
0686 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_p_unpack', fread(fid,1,'int32'));
0687 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_l_unpack', fread(fid,1,'int32'));
0688 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_p_compress', fread(fid,1,'int32'));
0689 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_l_compress', fread(fid,1,'int32'));
0690 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_p_histo', fread(fid,1,'int32'));
0691 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_l_histo', fread(fid,1,'int32'));
0692 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_p_text', fread(fid,1,'int32'));
0693 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_l_text', fread(fid,1,'int32'));
0694 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_p_graphics', fread(fid,1,'int32'));
0695 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_l_graphics', fread(fid,1,'int32'));
0696 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_p_dbHdr', fread(fid,1,'int32'));
0697 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_l_dbHdr', fread(fid,1,'int32'));
0698 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_levelOffset', fread(fid,1,'int32'));
0699
0700 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_p_user', fread(fid,1,'int32'));
0701 ge.hdr.pixel = setfield(ge.hdr.pixel, 'img_l_user', fread(fid,1,'int32'));
0702
0703 return