How display 3-D binary as an image?

3 次查看(过去 30 天)
zrowork
zrowork 2018-4-29
编辑: zrowork 2018-5-10
I have problem with the following data to display it as an 3d binary object or image:
m(:,:,2) = [ 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 1 1 0 0; 0 0 1 1 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0];
m(:,:,3) = [ 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 1 1 0 0; 0 0 1 1 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0];
m(:,:,4) = [ 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0];
m(:,:,5) = zeros;
m
Does anybody have a solution how to display this data? Thank you.
  3 个评论
Rik
Rik 2018-4-29
So what do you want? A patch maybe?
zrowork
zrowork 2018-4-29
Normally I have 3d matrix 431x473x72 inside which are different numbers. For now I try to display it on simple 3d-matrix, that the result would look like as below.
I would like to display positions with number 1 as a cube or just merge this positions together to obtain some shape.

请先登录,再进行评论。

回答(1 个)

zrowork
zrowork 2018-5-10
编辑:zrowork 2018-5-10
So, I have found a solution. I have used isosurface command.
m(:,:,2) = [ 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 1 1 0 0; 0 0 1 1 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0];
m(:,:,3) = [ 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 1 1 0 0; 0 0 1 1 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0];
m(:,:,4) = [ 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0; 0 0 0 0 0 0];
m(:,:,5) = zeros;
isosurface(m)
The result looks like:
Unfortunately, in big data (3D Matrix 431x473x72) it is not possible to notice this kind of object because matrix is too big.
Does anybody have solution how zoom exactly to the created surface which is unseen in this case? It's somewhere there.

类别

Help CenterFile Exchange 中查找有关 Creating, Deleting, and Querying Graphics Objects 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by