필터 지우기
필터 지우기

Is this code creating a matrix for the image or is it doing something else?

조회 수: 1 (최근 30일)
What exactly are these 3 lines doing?
im2(:,:,1)=im1;
im2(:,:,2)=im1;
im2(:,:,3)=im1;

채택된 답변

Image Analyst
Image Analyst 2016년 3월 26일
They're creating a 3D matrix where every slice/channel/plane is the same - it's im1. So im2 can either be a color image that appears as grayscale because all 3 color channels are identical, or it can be a volumetric image (like a CT or MRI image) where all three slices/planes are the same, like you extruded the im1 image upwards.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Explore and Edit Images with Image Viewer App에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by