plot dots on a 3D images
6 views (last 30 days)
I need to visualize many dots on a 3D image 355*355*55 (uint16).
There are a RCS file with 9000 coordinates (X,Y,Z) and another TT logical file 0/1. When TT = 1, I need to put a red spot in the corresponding coordinates of RCS.
The following code, works only on a zeros image of the same size of img, where I can see white pixels on a black background
zeros_img = zeros(size(img));
for j = 1 : length(RCS(:,3))
zeros_img(RCS(j, 1), RCS(j, 2), RCS(j, 3)) = TT(j);
However, I need to plot red spots on my original image.
plot(x, y, 'r.', 'MarkerSize', 2);
It works but I cannot call imshow 9000 times. Moreover, RCS is 9000 in size and not in order of slice.
Thanks for your help