Package com.microblink.blinkid.entities.recognizers.framegrabber

# Class FrameGrabberRecognizer

java.lang.Object
com.microblink.blinkid.entities.Entity<T>
com.microblink.blinkid.entities.recognizers.Recognizer<FrameGrabberRecognizer.Result>
com.microblink.blinkid.entities.recognizers.framegrabber.FrameGrabberRecognizer

All Implemented Interfaces:
  `android.os.Parcelable`, `JsonizableEntity`

public final class FrameGrabberRecognizer extends Recognizer<FrameGrabberRecognizer.Result>
A recognizer that never produces a result, but sends every frame that it receives to given `FrameCallback`.

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static final class`
  `FrameGrabberRecognizer.Result`

  ## Nested classes/interfaces inherited from interface android.os.Parcelable

  `android.os.Parcelable.ClassLoaderCreator<T extends Object>, android.os.Parcelable.Creator<T extends Object>`

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final android.os.Parcelable.Creator<FrameGrabberRecognizer>`
  `CREATOR`

  ### Fields inherited from interface android.os.Parcelable

  `CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `FrameGrabberRecognizer(FrameCallback frameCallback)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `FrameGrabberRecognizer`
  `clone()`
  Create a copy of the entity.
  `void`
  `consumeResultFrom(Entity other)`
  Consume result from other entity.
  `protected void`
  `deserializeNativeSettings(byte[] serializedSettings)`
  `FrameCallback`
  `getFrameCallback()`
  The `FrameCallback` that will receive frames.
  `protected byte[]`
  `serializeNativeSettings()`
  `void`
  `setFrameCallback(FrameCallback frameCallback)`
  The `FrameCallback` that will receive frames.
  `void`
  `setGrabFocusedFrames(boolean grabFocusedFrames)`
  Allow sending focused camera frames to `FrameCallback`.
  `void`
  `setGrabUnfocusedFrames(boolean grabUnfocusedFrames)`
  Allow sending unfocused camera frames to `FrameCallback`.
  `boolean`
  `shouldGrabFocusedFrames()`
  Allow sending focused camera frames to `FrameCallback`.
  `boolean`
  `shouldGrabUnfocusedFrames()`
  Allow sending unfocused camera frames to `FrameCallback`.
  `protected void`
  `terminateNative(long nativeContext)`
  `void`
  `writeToParcel(android.os.Parcel dest, int i)`

  ### Methods inherited from class com.microblink.blinkid.entities.recognizers.Recognizer

  `getName, isExcludedFromPing, requiresAutofocus, requiresLandscapeMode, signedJsonNativeGet, toSignedJson`

  ### Methods inherited from class com.microblink.blinkid.entities.Entity

  `describeContents, finalize, getNativeContext, getResult, nativeGetNativeResultContext, readFromParcel`

  ### Methods inherited from class java.lang.Object

  `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### CREATOR

    @NonNull public static final android.os.Parcelable.Creator<FrameGrabberRecognizer> CREATOR

- ## Constructor Details

  - ### FrameGrabberRecognizer

    public FrameGrabberRecognizer(@NonNull FrameCallback frameCallback)
    Parameters:
      `frameCallback` - The `FrameCallback` that will receive frames.

- ## Method Details

  - ### setFrameCallback

    public void setFrameCallback(@NonNull FrameCallback frameCallback)
    The `FrameCallback` that will receive frames.

  - ### getFrameCallback

    @NonNull public FrameCallback getFrameCallback()
    The `FrameCallback` that will receive frames.

  - ### setGrabFocusedFrames

    public void setGrabFocusedFrames(boolean grabFocusedFrames)
    Allow sending focused camera frames to `FrameCallback`.

  - ### shouldGrabFocusedFrames

    public boolean shouldGrabFocusedFrames()
    Allow sending focused camera frames to `FrameCallback`.

  - ### setGrabUnfocusedFrames

    public void setGrabUnfocusedFrames(boolean grabUnfocusedFrames)
    Allow sending unfocused camera frames to `FrameCallback`.

  - ### shouldGrabUnfocusedFrames

    public boolean shouldGrabUnfocusedFrames()
    Allow sending unfocused camera frames to `FrameCallback`.

  - ### terminateNative

    protected void terminateNative(long nativeContext)
    Specified by:
      `terminateNative` in class `Entity<FrameGrabberRecognizer.Result>`

  - ### writeToParcel

    public void writeToParcel(@NonNull android.os.Parcel dest, int i)
    Specified by:
      `writeToParcel` in interface `android.os.Parcelable`
    Overrides:
      `writeToParcel` in class `Entity<FrameGrabberRecognizer.Result>`

  - ### serializeNativeSettings

    @Nullable protected byte[] serializeNativeSettings()
    Specified by:
      `serializeNativeSettings` in class `Entity<FrameGrabberRecognizer.Result>`

  - ### deserializeNativeSettings

    protected void deserializeNativeSettings(@NonNull byte[] serializedSettings)
    Specified by:
      `deserializeNativeSettings` in class `Entity<FrameGrabberRecognizer.Result>`

  - ### clone

    @NonNull public FrameGrabberRecognizer clone()
    Description copied from class: `Entity`
    Create a copy of the entity. This is required if properties of the entity must be modified while background thread performs processing. In order to avoid race conditions, changing properties is not allowed while entity is used in background processing. However, you are able to make a copy of the entity, change properties of it and then update the `RecognizerRunnerView` or `RecognizerRunner` with the updated entity hierarchy.
    Specified by:
      `clone` in class `Recognizer<FrameGrabberRecognizer.Result>`
    Returns:
      a copy of the entity

  - ### consumeResultFrom

    public void consumeResultFrom(@NonNull Entity other)
    Description copied from class: `Entity`
    Consume result from other entity. The result from other will be put instead current result of this entity. This method is used inside `BaseIntentTransferable.loadFromIntent(Intent)` and similar methods to replace the result content of the saved entities with results that have arrived over `Intent`
    Specified by:
      `consumeResultFrom` in class `Entity<FrameGrabberRecognizer.Result>`
    Parameters:
      `other` - Entity from which result should be consumed.