get_virtual_image_buffer#

Client.get_virtual_image_buffer(virtual_image_id: int, timeout_msec: int = 5000, virtual_image_info: VirtualImageInfo = None)#

Retrieve a single virtual image frame from the DE-Server virtual image buffer.

The server queues a virtual image buffer when queue_virtual_buffers is set in start_acquisition(). Call this method after acquisition to pop and receive the accumulated virtual image for the requested virtual detector channel.

Parameters:
  • virtual_image_id (int) – Index of the virtual detector buffer to retrieve (0–4).

  • timeout_msec (int, optional) – How long to wait for a frame to become available, in milliseconds. Default is 5000.

  • virtual_image_info (VirtualImageInfo, optional) – Pre-fetched virtual image metadata (width, height, data type). If None (default), get_virtual_image_buffer_info() is called automatically to obtain the shape needed to reshape the raw buffer.

Returns:

  • status (MovieBufferStatus) – Result of the retrieval: - MovieBufferStatus.OK (5) — image data is valid. - Other values indicate timeout, failure, or finished state.

  • frame_index (int) – The acquisition frame index associated with this virtual image.

  • image (numpy.ndarray or None) – 2-D array of shape (height, width) on success, None otherwise.