replace direct read of field in nifti struct with call to niftiGet