This is a part of my Capstone Research.
3D images acquired from each modality is different in size and unit. To register between images from each modality, we need to resize each 3D image according to its three dimentional length.
In dicom information, 'PixelSpacing' is used to acquire x,y units, 'SliceThickness‘ is used to acquire z unit.
Resize in x-y plane is simple. In matlab, 'imresize' function is used to resize image according to give size, and it automatically fill in missing pixels or filter out extra pixel when resizing to larger or smaller image.
To resize in Z index, I first change x-y-z index to z-y-x using ’permute(MR_scale_xy,[3 2 1])‘, and then resize z-y plane, then permute back.
Full code is available in github resize_mrdsa.m