3D cuboid elements display

조회 수: 3 (최근 30일)
ac_bm_mat
ac_bm_mat 2022년 4월 29일
댓글: ac_bm_mat 2022년 4월 29일
elem(8,8,8) = zeros;
for i=1:8
elem(i,i,i)=1
end
I want to plot 3D voxels or mesh or elements with different color for 1 and different color for 0. How to do that?

채택된 답변

Walter Roberson
Walter Roberson 2022년 4월 29일
I did not get around to gettting color working, but you can hardcode facecolor options into the patch() call.
  댓글 수: 6
Walter Roberson
Walter Roberson 2022년 4월 29일
Sorry, I am too busy the next few days to simplify that code for your case.
ac_bm_mat
ac_bm_mat 2022년 4월 29일
It's okay. Whenever you are free, please try to simplify it. Thank you so much.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기

제품


릴리스

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by