Displaying 3D data with adjusted transparency values in Matlab

3 views (last 30 days)
I have a 3D matrix of size 300x178x124 that I plot using the slice command:
diff = double(squeeze(glacier));
h = slice(realx,realy,realz,diff, [], [], 1:size(diff,1));
set(h, 'EdgeColor','none', 'FaceColor','interp', 'FaceLighting','gouraud')
caxis([0 5])
shading interp
daspect([0.5 1 .2])
I was wondering if it is possible to
(a) add transparency based upon the value of the 3D matrix, e.g. value of 0 in "diff" is 100% transparency while the maximum value of "diff" is displayed using 0% transparency.
(b) is there a way to visually improve the 3D presentation? It seems to me that the data display is rather patchy and does not really look that nice.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by