필터 지우기
필터 지우기

Convert a <1023x1023 double> to a rgb image

조회 수: 1 (최근 30일)
Rafael Freire
Rafael Freire 2011년 4월 1일
I have a data < 1023x1023 double> the values is 0 and 1. How i convert this type of data in a rgb image data, and a binary image type of data?

채택된 답변

Walter Roberson
Walter Roberson 2011년 4월 1일
Let A be the array, then
Argb = cat(3,A,A,A);
Or
Argb = repmat(A,1,1,3);
And
Abinary = logical(A);
  댓글 수: 2
Rafael Freire
Rafael Freire 2011년 4월 1일
the rapmat function doesn't work but the rest works very well thanks
Jan
Jan 2011년 4월 1일
Working: Argb = repmat(A, [1,1,3]);
@Rafael: If the solution works, please accept the answer such that the readers can see, that the problem is solved already.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Convert Image Type에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by