what are you trying to do? If you're trying to bring the surface coords into talairach (mni305) space, then you can use mri_surf2surf with the --sval-xyz-tal orig --taval-xyz options.
Lloyd Elliott wrote:
I am trying to overlay surface information acquired with freesurfer on to the original MRI volume. I tried reading lh.orig with [vertices,faces] = freesurfer_read_surf('surf/lh.orig') and then transforming the vertices with the matrix:
vertices_affine = [vertices' ; ones(1,size(vertices,1))] # append the affine coordinates overlay = (rsb2vox*inv(M)) * vertices_affine
where
M = xfm_read('mri/transforms/talairach.xfm')
and
rsb2vox = inv([ [-1 0 0 128 ; 0 0 1 -128; 0 -1 0 128; 0 0 0 1] ])
I was lead to believe that this is the correct procedure by reading the 'official' description of the coordinate systems on the freesurfer wiki ( http://surfer.nmr.mgh.harvard.edu/fswiki/CoordinateSystems ). Unfortunately the scaling and translation is incorrect. I've also tried other permutations of the above matrix multiplication without any luck. Am I doing something incorrectly?
Thanks, Lloyd Elliott _______________________________________________ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer