Dear Chen Yongxi,
the quickest way to update NIFTI header information on disk without rewriting image contents itself is to use
spm_get_space(imagename, mat)
where imagename is the path to an image, and mat the 4x4 transformation matrix that has the corrected orientation and voxel size information. I am not aware of a situation where this method would not update the spatial information.
Best,
Volkmar
|