Class Recognizer.CppProxy

java.lang.Object
com.banuba.sdk.recognizer.Recognizer.CppProxy
All Implemented Interfaces:
Recognizer
Enclosing interface:
Recognizer

public static final class Recognizer.CppProxy
extends java.lang.Object
implements Recognizer
  • Method Details

    • _djinni_private_destroy

      public void _djinni_private_destroy()
    • finalize

      protected void finalize() throws java.lang.Throwable
      Overrides:
      finalize in class java.lang.Object
      Throws:
      java.lang.Throwable
    • getFeature

      public Feature getFeature​(FeatureId feature)
      Specified by:
      getFeature in interface Recognizer
    • setFeatures

      public void setFeatures​(java.util.HashSet<FeatureId> features)
      Specified by:
      setFeatures in interface Recognizer
    • addFeature

      public void addFeature​(Feature feature, java.util.HashSet<FeatureId> dependencies, boolean needsGpu)
      Specified by:
      addFeature in interface Recognizer
    • removeFeature

      public void removeFeature​(Feature feature)
      Specified by:
      removeFeature in interface Recognizer
    • setMaxFaces

      public void setMaxFaces​(int num)
      Description copied from interface: Recognizer
      sets maximum allowed face results, if face tracking feature is present
      Specified by:
      setMaxFaces in interface Recognizer
    • setOfflineMode

      public void setOfflineMode​(boolean on)
      Specified by:
      setOfflineMode in interface Recognizer
    • setNnEnable

      public void setNnEnable​(boolean enable)
      Description copied from interface: Recognizer
      Set flag which enable NN's features. True by default, if device compatible with NN player When this flag is false, recognizer will skip NN-dependent features during set_features call. In case when device have no NN player support (is_device_nn_compatible return false), setting enable to true have no any effect
      Specified by:
      setNnEnable in interface Recognizer
    • getNnEnable

      public boolean getNnEnable()
      Specified by:
      getNnEnable in interface Recognizer
    • setEyesCorrection

      public void setEyesCorrection​(boolean on)
      Description copied from interface: Recognizer
      sets eyes correction
      Specified by:
      setEyesCorrection in interface Recognizer
    • setLipsCorrection

      public void setLipsCorrection​(boolean on)
      Description copied from interface: Recognizer
      sets lips correction
      Specified by:
      setLipsCorrection in interface Recognizer
    • isDeviceNnCompatible

      public boolean isDeviceNnCompatible()
      Description copied from interface: Recognizer
      Check if device compatible with NN player.
      Specified by:
      isDeviceNnCompatible in interface Recognizer
    • setFaceSearchMode

      public void setFaceSearchMode​(FaceSearchMode mode)
      Description copied from interface: Recognizer
      Clear pipeline state and set face search mode
      Specified by:
      setFaceSearchMode in interface Recognizer
    • process

      public void process​(FrameData frameData)
      Specified by:
      process in interface Recognizer
    • pushCameraFrame

      public void pushCameraFrame​(FrameData inputFrameData)
      Specified by:
      pushCameraFrame in interface Recognizer
    • popFrameData

      public boolean popFrameData​(FrameData outputFrameData)
      Specified by:
      popFrameData in interface Recognizer
    • start

      public void start()
      Description copied from interface: Recognizer
      start the recognizer
      Specified by:
      start in interface Recognizer
    • pause

      public void pause()
      Description copied from interface: Recognizer
      pause the recognizer
      Specified by:
      pause in interface Recognizer
    • stop

      public void stop()
      Description copied from interface: Recognizer
      pause + clear
      Specified by:
      stop in interface Recognizer
    • clear

      public void clear()
      Description copied from interface: Recognizer
      clear input and output buffers and pipeline state, also clean cached features
      Specified by:
      clear in interface Recognizer
    • create

      @Nullable public static Recognizer create​(@NonNull RecognizerMode mode, @Nullable java.lang.Integer maxTokens)
      maxTokens - If greater than 0: recognizer will run processing on push-ed() frame only if it can "consume" a token - and will wait for the token to become available if all maxTokens tokens have been used up. Consumed tokens are "produced" again one-by-one when pop-ping() processed frame(s). This mode prevents processing frames more often than a consumer(e.g. renderer) can use: potentially reducing energy consumption at the cost of higher latency. Only for asynchronous mode.
    • getFeatureId

      public static long getFeatureId​(@NonNull FeatureId feature)