java.lang.Object
com.microblink.blinkid.entities.recognizers.templating.DewarpPolicy
com.microblink.blinkid.entities.recognizers.templating.dewarpPolicies.DPIBasedDewarpPolicy

public final class DPIBasedDewarpPolicy extends DewarpPolicy
DPI based dewarp policy. Dewarp height will be calculated based on actual physical size provided by the com.microblink.blinkid.entities.detectors.quad.QuadWithSizeDetector and requested DPI (dots per inch). This policy is usually best for processor groups that prepare image for output (e.g. ImageReturnProcessor).
  • Field Details

    • DEFAULT_DPI

      public static final int DEFAULT_DPI
      Default DPI that will be used with default constructor
      See Also:
  • Constructor Details

    • DPIBasedDewarpPolicy

      public DPIBasedDewarpPolicy()
    • DPIBasedDewarpPolicy

      public DPIBasedDewarpPolicy(@IntRange(from=100L,to=400L) int desiredDPI)
      Parameters:
      desiredDPI - Desired DPI (dots per inch
  • Method Details

    • setNativePolicy

      protected void setNativePolicy(long nativeProcessorContext)
      Specified by:
      setNativePolicy in class DewarpPolicy
    • getDPI

      public int getDPI()
      Returns the desired DPI as defined by this policy.
      Returns:
      the desired DPI