imgGetBufferElement

NI IMAQ Function

imgGetBufferElement

Usage

rval imgGetBufferElement(BUFLIST_ID bid, uInt32 element, uInt32 itemType, void* itemValue);

Purpose

Gets 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 void* output
rval Int32 output

Parameter Discussion

bid: valid BUFLIST_ID variable.

element: index of the buffer list item to examine.

itemType: describes the type of element to get as specified by the following constants:

IMG_BUFF_ACTUALHEIGHTReturns the actual height, in lines, of a buffer acquired in VHA mode.
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: passes a pointer to an area of memory reserved for the return type (32 bits).

Return Value

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

Note  Refer to Constants for valid element and command types.