|
Size: 541
Comment:
|
Size: 1169
Comment:
|
| Deletions are marked like this. | Additions are marked like this. |
| Line 7: | Line 7: |
| The .mgh file format is used to store high-resolution structural data and other data which are to be overlaid on the high-resolution structural volume. An .mgz file is a .mgh file that has been compressed with ZLib. | The .mgh file format is used to store high-resolution structural data and other data which are to be overlaid on the high-resolution structural volume. A .mgz file is a .mgh file that has been compressed with ZLib. |
| Line 9: | Line 9: |
| The MGH format is proprietary, defined by the NMR Center (at Massachusetts General Hospital). Short of having a formal specification of this format, the next best thing is a snapshot of the C code showing how a .mgh or .mgz file is read and written: | |
| Line 10: | Line 11: |
| attachment:mri.h - see MRI data structure | * attachment:mri.h - .mgh file merely stores contents of '''MRI''' data structure, defined in mri.h |
| Line 12: | Line 13: |
| attachment:matrix.h - MRI data structure contains MATRIX | * attachment:matrix.h - MRI data structure contains MATRIX |
| Line 14: | Line 15: |
| attachment:mri.c | * attachment:mriio.c - '''see 'mghRead' and 'mghWrite' routines''', the MGH file format is implicitly defined by these routines |
| Line 16: | Line 17: |
| attachment:mriio.c - see mri_read | * attachment:mri.c - contains helper routines used in mriio.c |
| Line 18: | Line 19: |
| attachment:mri_info.c | * attachment:mri_info.c - source for mri_info utility; see 'do_file' routine |
| Line 20: | Line 21: |
| * attachment:mri_convert.c - source for mri_convert utility; many examples of reading and writing .mgh and .mgz files |
[wiki:FreeSurferWiki top] | [wiki:FileFormats previous]
The MGH/MGZ Volume Format
WORK IN PROGRESS
The .mgh file format is used to store high-resolution structural data and other data which are to be overlaid on the high-resolution structural volume. A .mgz file is a .mgh file that has been compressed with ZLib.
The MGH format is proprietary, defined by the NMR Center (at Massachusetts General Hospital). Short of having a formal specification of this format, the next best thing is a snapshot of the C code showing how a .mgh or .mgz file is read and written:
attachment:mri.h - .mgh file merely stores contents of MRI data structure, defined in mri.h
- attachment:matrix.h - MRI data structure contains MATRIX
attachment:mriio.c - see 'mghRead' and 'mghWrite' routines, the MGH file format is implicitly defined by these routines
- attachment:mri.c - contains helper routines used in mriio.c
- attachment:mri_info.c - source for mri_info utility; see 'do_file' routine
- attachment:mri_convert.c - source for mri_convert utility; many examples of reading and writing .mgh and .mgz files
