Using volshow with AlphaData for an RGB volume
Mostrar comentarios más antiguos
I'm using volshow to render two 3D volumes with one (V2) enclosing the other (V1).
V1 and V2 are 3D binary masks with the value of 1 inside the volumes and 0 everywhere else.
The RGB volume (V) is defined as follows.
V = zeros([size(V1) 3]);
V(:,:,:,2) = V1;
V(:,:,:,1) = V2;
Using volshow, I get the following picture, which is expected.

However, when I used the following AlphaData to render the outer volume (V2) to be transparent, the color is almost lost.
Adata = zeros(size(V1));
Adata(V2>0.5) = 0.5;
Adata(V1>0.5) = 0;

I tried a different setting for AlphaData as follows.
Adata = ones(size(V1));
Adata(V2>0.5) = 0.5;
Adata(V1>0.5) = 0;
However, the result is worse.

Has anyone had a similar problem?
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Display 3-D Volumetric Images en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

