imgSetBufferElement

NI IMAQ Function

imgSetBufferElement

Usage

rval imgSetBufferElement(BUFLIST_ID bid, uInt32 element, uInt32 itemType, uInt32 itemValue);

Purpose

Sets the value for a specified itemType for a buffer in a buffer list.

Parameters

Name Type Direction
bid BUFLIST_ID input
element uInt32 input
itemType uInt32 input
itemValue uInt32 input
rval Int32 output

Parameter Discussion

bid: valid BUFLIST_ID variable.

element: element number of the buffer list item to modify.

itemType: describes the parameter of the element to set, as specified by the following constants:

IMG_BUFF_ADDRESSSpecifies the buffer address portion of a buffer list element.
IMG_BUFF_CHANNELSpecifies the channel from which to acquire an image.
IMG_BUFF_COMMANDSpecifies the command portion of a buffer list element.
IMG_BUFF_SIZESpecifies the size portion of a buffer list element (the buffer size). Required for user-allocated buffers.
IMG_BUFF_SKIPCOUNTSpecifies the skip count portion of a buffer list element.

itemValue: indicates the value of the element type to set. Use the following constants to specify the IMG_BUFF_COMMAND:

IMG_CMD_LOOPSpecifies a buffer list command of LOOP. Used as the command for the last buffer element, this constant causes an acquisition to perform a continuous type of acquisition, such as a ring.
IMG_CMD_NEXTSpecifies a buffer list command of NEXT. This constant causes an acquisition to take place on the buffer and to proceed to the next buffer list element.
IMG_CMD_STOPSpecifies a buffer list command of STOP. Used as the command for the last buffer element, this constant causes an acquisition to perform a one-shot acquisition such as a sequence.

Return Value

This function returns 0 on success. On failure, this function returns an error code. For information about the error code, call imgShowError.

Note  Refer to Constants for valid element and command types.