Skip to content

snap_from_image_sourceSnapFromImageSourceSnapFromImageSourcesnap_from_image_sourceT_snap_from_image_source🔗

Short description🔗

snap_from_image_sourceSnapFromImageSourceSnapFromImageSourcesnap_from_image_sourceT_snap_from_image_source — Acquire an image with corresponding meta data from an image source.

Signature🔗

snap_from_image_source( out image Images, image_source ImageSourceHandle, out dict Data )void SnapFromImageSource( HObject* Images, const HTuple& ImageSourceHandle, HTuple* Data )static void HOperatorSet.SnapFromImageSource( out HObject images, HTuple imageSourceHandle, out HTuple data )def snap_from_image_source( image_source_handle: HHandle ) -> Tuple[HObject, HHandle]

Herror T_snap_from_image_source( Hobject* Images, const Htuple ImageSourceHandle, Htuple* Data )

HImage HImageSource::SnapFromImageSource( HDict* Data ) const

HImage HImageSource.SnapFromImageSource( out HDict data )

Description🔗

snap_from_image_sourceSnapFromImageSource actively causes the acquisition of Imagesimagesimages with the image source defined in the handle ImageSourceHandleimageSourceHandleimage_source_handle. For conventional devices, Imagesimagesimages is most likely to be a single image, but complex sensors, e.g. 3D sensors, might provide multiple images at once. Additionally, meta information is returned in Datadatadata.

Internally, calling snap_from_image_sourceSnapFromImageSource starts the image acquisition, retrieves an image, and stops the acquisition again, freeing all resources. It is therefore tailored towards the basic synchronous acquisition of one image. See fetch_from_image_sourceFetchFromImageSource for continuous image acquisition.

As far as supported by the respective plugin, meta information is returned in Datadatadata. If activated, meta information obtained from GenICam Chunk Data is also returned in Datadatadata. Refer to fetch_from_image_sourceFetchFromImageSource for a description of the content of the Datadatadata dictionary.

The device defined in ImageSourceHandleimageSourceHandleimage_source_handle needs to be connected when calling snap_from_image_sourceSnapFromImageSource. See connect_image_sourceConnectImageSource on how to connect your image source.

For further information about the states of an image source see Image Source.

Execution information🔗

Execution information
  • Multithreading type: reentrant (runs in parallel with non-exclusive operators).

  • Multithreading scope: global (may be called from any thread).

  • Processed without parallelization.

This operator returns a handle. Note that the state of an instance of this handle type may be changed by specific operators even though the handle is used as an input parameter by those operators.

Parameters🔗

Imagesimagesimages (output_object) image(-array) → object (byte / int1 / int2 / uint2 / int4 / int8 / real)HObject (byte / int1 / int2 / uint2 / int4 / int8 / real)HImage (byte / int1 / int2 / uint2 / int4 / int8 / real)HObject (byte / int1 / int2 / uint2 / int4 / int8 / real)Hobject * (byte / int1 / int2 / uint2 / int4 / int8 / real)

Acquired images.

ImageSourceHandleimageSourceHandleimage_source_handle (input_control) image_source → (handle)HTuple (HHandle)HImageSource, HTuple (IntPtr)HHandleHtuple (handle)

Handle of the image source that acquires the images.

Datadatadata (output_control) dict → (handle)HTuple (HHandle)HDict, HTuple (IntPtr)HHandleHtuple (handle)

Meta information about the images.

Result🔗

If the parameter values are correct, snap_from_image_sourceSnapFromImageSource returns the value 2 (H_MSG_TRUE). Otherwise an exception is raised.

Combinations with other operators🔗

Combinations

Possible predecessors

connect_image_sourceConnectImageSource, set_image_source_paramSetImageSourceParam

Possible successors

disconnect_image_sourceDisconnectImageSource

Module🔗

Foundation