IMAQ ReadFile

NI 5431 Composite Video Generator

NI 5431 Composite Video Generator
IMAQ ReadFile

Reads an image file. The file format can be a standard format (BMP, TIFF, JPEG, PNG, and AIPD) or a nonstandard format known to the user. In all cases, the read pixels are converted automatically into the image type passed by Image.

File Path is the complete path name, including drive, directory, and filename, for the file to be loaded.
Image is the reference to the image structure to which the data from the image file is applied.
Load Color Palette? (No) determines whether to load the color table present in the file (if it exists). If loaded, this table is read and made available to the output Color Palette. The default is FALSE.
File Options is a cluster of user-optional values that you can use to read nonstandard file formats. The file structure must be known to the user. This cluster consists of the following elements:
Read Raw File indicates whether the file to be read has a nonstandard file format. If so, the remaining options in this cluster describe how to read the data.
File Data Type indicates how the image file is encoded.
Offset to Data specifies the size, in bytes, of the file header. This part of the file is not taken into account when read. The pixel values are read from the byte immediately after the offset size. The default is 0.
Use Min Max determines if the user is using a predetermined minimum and maximum. The technique to determine this minimum and maximum depends on the following input values:
0 Don't use min max Minimum and maximum are dependent on the type of image. For an 8-bit image, min = 0 and max = 255.
1 Use file values Pixel values from the file are scanned one time to determine the minimum and maximum, and a linear interpolation is performed before loading the image.
2 Use optional values Uses the two optional values described below.
Optional Min Value is the minimum value of the pixels if Use Min Max is selected in mode 2 (Use optional values). In this case, pixels with a smaller value are altered to match the chosen minimum. The default is 0.
Optional Max Value is the maximum value of the pixels if Use Min Max was selected in mode 2 (Use optional values). In this case, pixels with a greater value are truncated to match the chosen maximum. The default is 255.
Byte Order determines if the byte weight is to be swapped (Intel or Motorola). The default is FALSE, which specifies big endian (Motorola). TRUE specifies little endian (Intel). This input is useful only if the pixels are encoded with more than 8 bits.
error in (no error) is a cluster that describes the error status before this VI executes. Refer to IMAQ VI Error Clusters for more information about this indicator.
Color Palette out contains the RGB color table (if the file has one) read from the file when you pass the value TRUE for the input Load Color Palette? (No).
Image out is the reference to the image structure containing the data read from the image file.
File Type out indicates the file type that is read. This string returns an identifier of the file format, which can be BMP, TIFF, JPEG, PNG, or AIPD (internal file format). File Type returns xxx if the file format is unknown.
File Data Type out indicates the pixel size defined in the header for standard image file types. File Options are not necessary for reading standard image files. For other types of image files, the returned values are passed from File Options/File Data Type.
error out is a cluster that describes the error status after this VI executes. Refer to IMAQ VI Error Clusters for more information about this indicator.