IMAQdxGetImageDataCW
Format
rval = IMAQdxGetImageDataCW (id As IMAQdxSession, buffer As VARIANT, mode As IMAQdxBufferNumberMode, desiredBufferNumber As Long, actualBufferNumber As Long);
Purpose
Copies the raw data of the specified frame into buffer.
Note This function allows you to access raw image data. For many uncompressed formats like YUV or RGB, buffer is not compatible with NI Vision. To use the NI Vision functions, use IMAQdxGetImage instead of this function. |
Parameters
Parameter | Type | Description |
id | IMAQdxSession | A valid Session ID, which you can obtain using IMAQdxOpenCamera. |
buffer | VARIANT * | The data of the specified attributes when the function returns. |
mode | IMAQdxBufferNumberMode | The buffer number mode of the image to retrieve. Set this parameter to IMAQdxBufferNumberModeNext to get the next buffer, or set this parameter to IMAQdxBufferNumberLast to get the last acquired buffer, or set this parameter IMAQdxBufferNumberModeBufferNumber to acquire a specific cumulative buffer number. |
desiredBufferNumber | Long | The cumulative buffer number of the image to retrieve. This parameter is only needed if mode is set to IMAQdxBufferNumberModeBufferNumber. |
actualBufferNumber | Long (passed by reference) | On return, the actual cumulative buffer number of the image retrieved. |
Return Value
On success, this function returns IMAQdxErrorSuccess. On failure, this function returns an error code. You can obtain a more detailed error message with IMAQdxGetErrorString.