Discussion:
save 16 bit array as image
(too old to reply)
sanhita
2006-07-06 21:10:07 UTC
Permalink
Hello,

I am a new labview user. I am trying to save an image which is being
correctly displayed on the front panel of my program as an intensity
graph. I  am able to get a 2D array of the pixel values (using the
variant to data function, the camera I use has an Active X interface
with labview). The camera allows 16 bit or 12 bit digitization options.
I would like to save the image pizel values as a 16 bit BMP or TIFF
file. However, from what I understand, the flatten pixmap option in
labview does not support 16 bit images. How do I go about saving my
images? Any feedback would be extremely useful.

Thanks,
Sanhita
chrisger
2006-07-07 11:10:07 UTC
Permalink
hi there
as far as i know a BMP only supports 1, 4, 8 and 24 Bits, so if you don't want to loose some data you have to convert the U16 to U32. see attachment (maybe you have to fondle a little with the color map)
 


U14-24BitBMP_7.1.vi:
http://forums.ni.com/attachments/ni/170/194001/1/U14-24BitBMP_7.1.vi
zou
2006-07-07 15:10:10 UTC
Permalink
I guess your web camera return a 16 bit gray scale image.  Which is equivlent to 48 bit RGB image.  You can use IMAQ to save it to an TIFF file.  IMAQ is an addon to LabVIEW.
If you don't have IMAQ, you can try Image Toolbox at:
&nbsp;&nbsp; <a href="http://www.geocities.com/gzou999/imgtool.htm" target="_blank">http://www.geocities.com/gzou999/imgtool.htm</a>
&nbsp;
sanhita
2006-07-07 23:10:08 UTC
Permalink
Thank you all for your replies. Unfortunately, I do not have some of
the subvi's needed for your routines, i.e. IMAQ vision vi's. Hence I am
pretty much stuck. I am currently toying with the idea of using the U16
to U32 conversion and playing with the color table if it works as
suggested by one of you.&nbsp;

I am also wondering if I should down convert to 8 bit. I will lose
resolution. The only other option is to buy IMAQ Vision (I have IMAQ
Vision utilities for LV 6.1 but there is no option to convert Array to
Image, I suspect it is part of newer IMAQ vision versions). If I can
convert an array to image then I can convert the image to TIFF.



Regards,
Sanhita
chrisger
2006-07-10 08:10:08 UTC
Permalink
hi there
i'm not sure that you really need the whole IMAQ Vision package.&nbsp;a subset of IMAQ is&nbsp;part of the LV - driver CDs (maybe they won't be installed by default). please check your CDs first.
Loading...