For Programmers: Free Programming Magazines  


Home > Archive > Matlab > January 2008 > bmp and image









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author bmp and image
Buffy Summers

2008-01-13, 4:39 am

Hello,
I import bmp file and I get two variables:
1. cdata (uint8)
2. colormap (double)
I don't manage to create a graph using these two variables.
What is the correct command?
Thank you,
Anh Huy Phan

2008-01-13, 8:26 am

"Buffy Summers" <offdar@gmail.com> wrote in message
<fmcmf7$p9r$1@fred.mathworks.com>...
> Hello,
> I import bmp file and I get two variables:
> 1. cdata (uint8)
> 2. colormap (double)
> I don't manage to create a graph using these two variables.
> What is the correct command?
> Thank you,


Use function ind2rgb to convert indexed image to RGB image
imrgb = ind2rgb(cdata,colormap);
imshow(imrgb)


Anh Huy Phan
RIKEN - BSI
Buffy Summers

2008-01-13, 8:26 am

Thank you very much.

"Anh Huy Phan" <phananhhuy@mathworks.com> wrote in message
<fmcqvl$e59$1@fred.mathworks.com>...
> "Buffy Summers" <offdar@gmail.com> wrote in message
> <fmcmf7$p9r$1@fred.mathworks.com>...
>
> Use function ind2rgb to convert indexed image to RGB image
> imrgb = ind2rgb(cdata,colormap);
> imshow(imrgb)
>
>
> Anh Huy Phan
> RIKEN - BSI


Yumnam Kirani Singh

2008-01-13, 8:26 am

you can directly display the image using the command[color=darkred]
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com