Error using image Error using image TrueColor - How to plot images created by joining arrays instead of using imread
Ältere Kommentare anzeigen
Hello there, i have a question.
Let's suppose i have a image of 3x3 pixels with only a blue dot on the center.
>> image=imread('dot.bmp')
image(:,:,1) =
255 255 255
255 0 255
255 255 255
image(:,:,2) =
255 255 255
255 162 255
255 255 255
image(:,:,3) =
255 255 255
255 232 255
255 255 255
If i get the arrays separately and join them into an array:
dot(:,:,1) = [255 255 255; 255 0 255; 255 255 255] dot(:,:,2) = [255 255 255; 255 162 255; 255 255 255] dot(:,:,3) = [ 255 255 255; 255 232 255; 255 255 255]
>> image(dot) Error using image Error using image TrueColor CData contains element out of range 0.0 <= value <= 1.0
The question is, what should i do to make it work?
Regards.
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Images finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!