ImageFrameSource

Defined in namespace Scandit.DataCapture.Core.Source

ImageFrameSource
class ImageFrameSource : IFrameSource

Added in version 6.5.0

To emit the frame set this object as the frame source for the DataCaptureContext and turn it on by changing the desired state to FrameSourceState.On. This frame source will turn off automatically after the frame is emitted.

Create()
static ImageFrameSource Create(UIImage image)

Added in version 6.5.0

Constructs a new ImageFrameSource from the provided UIImage.

The provided UIImage should have one of the following configuration:

Gray color space:

8 bits per pixel

8 bits per component

kCGImageAlphaNone

RGB color space:

32 bits per pixel

8 bits per component

kCGImageAlphaNoneSkipFirst

32 bits per pixel

8 bits per component

kCGImageAlphaNoneSkipLast

32 bits per pixel

8 bits per component

kCGImageAlphaPremultipliedFirst

32 bits per pixel

8 bits per component

kCGImageAlphaPremultipliedLast

DesiredState
FrameSourceState DesiredState { get; }

Added in version 6.5.0

Implemented from IFrameSource. See IFrameSource.DesiredState.

CurrentState
FrameSourceState CurrentState { get; }

Added in version 6.5.0

Implemented from IFrameSource. See IFrameSource.CurrentState.

AddListener()
void AddListener(IFrameSourceListener listener)

Added in version 6.5.0

Implemented from IFrameSource. See IFrameSource.AddListener().

RemoveListener()
void RemoveListener(IFrameSourceListener listener)

Added in version 6.5.0

Implemented from IFrameSource. See IFrameSource.RemoveListener().

SwitchToDesiredState()
void SwitchToDesiredState(FrameSourceState state, Action<bool> completionHandler)

Added in version 6.5.0

Implemented from IFrameSource. See IFrameSource.SwitchToDesiredState().

SwitchToDesiredStateAsync()
Task<bool> SwitchToDesiredStateAsync(FrameSourceState state)

Added in version 6.5.0

Convenience method for IFrameSource.SwitchToDesiredState(): it is same as calling IFrameSource.SwitchToDesiredState() with the second argument set to null.