Image Acquisitionand Proces
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
8 <strong>Image</strong> Acquisition <strong>Proces</strong>sing with LabVIEW<br />
resulting in a larger Þle size. The GIF compression process also uses repeating pixel<br />
colors to further compress the image. Consider the following row of a raster image:<br />
125 125 125 125 125 125 126 126 126 126 Þ 6(125)4(126)<br />
Instead of represented each pixel’s intensity discreetly, a formula is generated that<br />
takes up much less space.<br />
1.2.1.4 PNG<br />
The Portable Network Graphics Þle format is also a lossless storage format that<br />
analyzes patterns within the image to compress the Þle. PNG is an excellent replacement<br />
for GIF images, and unlike GIF, is patent-free. PNG images can be indexed<br />
color, true color or grayscale, with color depths from 1 to 16 bits, and can support<br />
progressive display, so they are particularly suited to Web pages. Most image formats<br />
contain a header, a small section at the start of the Þle where information regarding<br />
the image, the application that created it, and other nonimage data is stored. The<br />
header that exists in a PNG Þle is programmatically editable using code developed<br />
by a National Instruments’ Applications Engineer. You are able to store multiple<br />
strings (with a maximum length of 64 characters) at an unlimited number of indices.<br />
Using this technique, it is possible to “hide” any type of information in a PNG<br />
image, including text, movies and other images (this is the method used to store<br />
region of interest (ROI) information in a PNG Þle). The source code used to realize<br />
this technique is available at the National Instruments Developer Zone at<br />
http://www.zone.ni.com (enter “Read and Write Custom Strings in a PNG” in the<br />
Search box).<br />
1.2.1.5 BMP<br />
Bitmaps come in two varieties, OS/2 and Windows, although the latter is by far the<br />
most popular. BMP Þles are uncompressed, support both 8-bit grayscale and color,<br />
and can store calibration information about the physical size of the image along<br />
with the intensity data.<br />
1.2.1.6 AIPD<br />
AIPD is a National Instruments uncompressed format used internally by LabVIEW<br />
to store images of Floating Point, Complex and HSL, along with calibration information<br />
and other speciÞcs.<br />
1.2.1.7 Other Types<br />
Although the formats listed in this chapter are the default types that the Vision<br />
Toolkit can read, several third-party libraries exist that extend the range of Þle types<br />
supported. One such library, called “The <strong>Image</strong> Toolbox,” developed by George Zou,<br />
allows your vision code to open icon (.ico), Windows MetaÞle (.wmf), ZSoft Cor-