Why do I get an image in grey scale after imread the gif image?
2 ビュー (過去 30 日間)
古いコメントを表示
My original image is with colour. I read the image file and display it, then I got a grey scale image. Does anyone know how I can load the image without change the colour scale? My code is like this: clear; close all;
I = imread('abc.gif')
figure, imshow(I);
0 件のコメント
回答 (1 件)
Image Analyst
2014 年 7 月 10 日
Don't name it I - that's a bad name - hard to tell the difference between I (upper case i), and l (lower case L), and 1. Plus it's not very descriptive.
Try this
[indexedImage, colorMap] = imread('abc.gif');
imshow(indexedImage);
colormap(colorMap);
colorbar;
8 件のコメント
Image Analyst
2014 年 7 月 11 日
You have it displayed 3 times. Each figure is using a different colormap.
参考
カテゴリ
Help Center および File Exchange で Blue についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!