I have a 3D medical image (IM) containing grayvalues. (size: 352 229 277, data type double).
I want slice through the 3D image, parallel to a plane.
The plane is defined by a line.
The line is defined by selecting 2 points in 2D view of the 3D image. (This 2D view is obtained by IM(:,123,:) )
The plane is defined with a normal vector orthogonal to this line.
I want to slice the 3D image with a slice parallel to this plane.
Then I want to view these slices in 2D setting. Like the function sliceViewer. (sliceViewer doesn't support arbitrary angle slices).
Tbh I don't understand much:
Firstly I don't understand how to define a surface with this:
I seems that I can't give a value to the meshgrid indices from my image: slice(x,y,z,V,XI,YI,ZI)
I have 3 points to define the plane.
I have the normal vector.
But I don't know how to use it with the slice function: slice(x,y,z,V,XI,YI,ZI)
Thanks in advance!
normal = cross(A-B,A-C);
[row,col,z] = meshgrid(0:1:average,0:1:average,0:1:average);
v = imc(row,col,z);