© 2016 Thorlabs Scientific Imaging
4 Programming (SDK)
391
4.3.106 is_WaitForNextImage
Syntax
INT is_WaitForNextImage(HIDS hCam, UINT timeout, char** ppcMem, INT* imageID)
Description
is_WaitForNextImage() returns the pointer and sequence ID of the first (i.e. oldest) image in a
memory sequence. The queue mode has to be enabled for the memory sequence (see
is_InitImageQueue()). If the sequence does not contain images, is_WaitForNextImage() waits
until a new image arrives or until the specified time has elapsed.
Note
Note that also image capture errors are added to the ImageQueue like images. If a call of
is_WaitForNextImage() returns the IS_CAPTURE_STATUS return value then you can check by a new
call of the function, if any further images were enqueued into the ImageQueue after the error.
Attention
Image memories in a sequence with queue mode are automatically locked. The image memories
will have to be unlocked with is_UnlockSeqBuf() in order to be re-used in the sequence.
Input parameters
Timeout in ms. Range 0…2
32
-1
If no images are in the sequence and no image arrives during the
timeout, the function returns IS_TIMED_OUT.
Pointer to a variable which will receive the address of the last image
in the sequence.
Pointer to a variable which will receive the sequence ID of the oldest
image in the sequence.
Return values
IS_CANT_COMMUNICATE_WITH_DRIVER
Communication with the driver failed because
no driver has been loaded.
An attempt to initialize or select the camera
failed (no camera connected or initialization
error).
IS_INVALID_MEMORY_POINTER
Invalid pointer or invalid memory ID
One of the submitted parameters is outside the
valid range or is not supported for this sensor or
is not available in this mode.
An IO request from the uc480 driver failed.
Possibly the versions of the uc480.dll (API) and
the driver file (uc480_usb.sys) do not match.