Torch Switch Control

Defined under the namespace Scandit.Datacapture.Core.Ui

TorchSwitchControl
class TorchSwitchControl : Control

Added in version 6.13.0

Control that allows to toggle the torch on and off. The torch switch control hides itself automatically in case the active frame source doesn’t have a torch.

You can add this control to a view by calling DataCaptureView.addControl().

The availability of torch can be checked programmatically with Camera.isTorchAvailable().

torchOffImage
torchOffImage: string | null

Added in version 6.13.0

Sets the image encoded as a base64 string to use for the control button when the torch is off.

torchOffPressedImage
torchOffPressedImage: string | null

Added in version 6.13.0

Sets the image encoded as a base64 string to use for the control button when the torch is off and the button is pressed.

torchOnImage
torchOnImage: string | null

Added in version 6.13.0

Sets the image encoded as a base64 string to use for the control button when the torch is on.

torchOnPressedImage
torchOnPressedImage: string | null

Added in version 6.13.0

Sets the image encoded as a base64 string to use for the control button when the torch is on and the button is pressed.