Convert a <1023x1023 double> to a rgb image

2 次查看(过去 30 天)
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