how to get x,y,z coordinates of 3d dicom image.I have 3d dicom image from which i can get x and y coordinates but z coordinate i cant get it provides me slice no.how to get that z coordinate
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
how to get x,y,z coordinates of a point on 3d dicom image.I have 3d dicom image from which i can get x and y coordinates but z coordinate i cant get. it provides me slice no.how to get that z coordinate
0 comentarios
Respuestas (2)
Image Analyst
el 13 de Jul. de 2017
Multiply the slice number, which you say you know, by the slice separation, which should be in the dicom header.
0 comentarios
drummer
el 28 de En. de 2020
info = dicominfo('yourImage.dcm');
slice_number = info.InstanceNumber; % Gives you the slice number
slice_thickness = info.SliceThickness; % Gives you the slice thickness
z = slice_number*slice_thickness; % number of steps you made times your voxel metric gives you the z coordinate.
It's pretty much what Image Analyst said. But you should take care on your reference.
Some cases, slice 1 is the last and slice n is the first. Check it before handling as aforementioned.
If n is the first:
z = last_slice_number*slice_thickness - slice_number*slice_thickness.
Sometimes it happens with multimodalities images.
Cheers
0 comentarios
Ver también
Categorías
Más información sobre DICOM Format en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!