Operators |
activate_compute_device — Activate a compute device.
activate_compute_device( : : DeviceHandle : )
activate_compute_device activates the compute device DeviceHandle for the current HALCON thread. All subsequent HALCON operators called in this thread are executed on DeviceHandle if they provide an implementation (see get_operator_info) for this device. Use deactivate_compute_device to deactivate DeviceHandle.
Currently, only one compute device can be active for a HALCON thread. If a different device is active before activate_compute_device is called, this device is deactivated automatically.
Compute device handle.
open_compute_device (DeviceIdentifier, DeviceHandle) read_image (Image, 'rings_and_nuts') * * Gaussian convolution on a compute device activate_compute_device (DeviceHandle) derivate_gauss (Image, DerivGauss, 5, 'none') * * Gaussian convolution on the CPU deactivate_compute_device (DeviceHandle) derivate_gauss (Image, DerivGauss, 5, 'none')
activate_compute_device returns the value 2 (H_MSG_TRUE) if DeviceHandle is valid. Otherwise an exception will be raised.
deactivate_compute_device, deactivate_all_compute_devices
Foundation
Operators |