User`s guide

Specifying the Format of the Image Data
5-5
Specifying the Format of the Image Data
Before you can acquire data from your device, you must tell the engine the format of the
data it can expect to receive from your device. Without this information, the engine does
not know how to interpret the data. For example, the engine needs to know the size of
the bytes used to store image data, the length of each line and the total number of lines
in each image frame, and the number of planes, or bands, in each image frame. (e.g. RGB
data has three bands). The following figure illustrates this information.
In some cases, this format information is determined by external standards, such as the
RS-170/NTSC standard. In other cases, device vendors define many different formats,
described in the documentation that comes with the device. Adaptor writers decide which
of these supported formats they want to make available to users of their adaptor in their
getAvailHW() function, described in “Storing Format Information” on page 3-12.
This section describes how you specify format information in your adaptor after using the
adaptor class virtual functions.
“Specifying Image Dimensions” on page 5-5
“Specifying Frame Type” on page 5-7
Specifying Image Dimensions
You specify the dimensions of the image data a device outputs using the following virtual
functions.
getMaxHeight() — Returns an integer that specifies the maximum height of the
image data.
getMaxWidth() — Returns an integer that specifies the maximum width of the
image data.
getNumberOfBands() — Returns an integer that specifies the number of dimensions
in the data. For example, RGB formats use three bands.