Class BasicScanUISettings
java.lang.Object
com.microblink.photopay.uisettings.UISettings<BasicOverlayController>
com.microblink.photopay.uisettings.BasicScanUISettings
- All Implemented Interfaces:
BeepSoundUIOptions
,DebugImageListenerUIOptions
,HelpIntentUIOptions
,HighResSuccessFrameCaptureUIOptions
,SplashScreenUIOptions
- Direct Known Subclasses:
BarcodeUISettings
,PhotopayUISettings
public abstract class BasicScanUISettings
extends UISettings<BasicOverlayController>
implements DebugImageListenerUIOptions, SplashScreenUIOptions, BeepSoundUIOptions, HighResSuccessFrameCaptureUIOptions, HelpIntentUIOptions
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
BasicScanUISettings
(android.content.Intent intent) protected
BasicScanUISettings
(RecognizerBundle recognizerBundle) -
Method Summary
Modifier and TypeMethodDescriptioncreateOverlayController
(android.app.Activity activity, ScanResultListener scanResultListener) Creates overlay controller and configures it using set values.protected abstract BasicOverlaySettings.Builder
void
enableHighResSuccessFrameCapture
(boolean enabled) Sets whether to enable capturing high res frames on recognition success.Returns theRecognizerBundle
containing recognizers that will be used for processing.final void
saveToIntent
(android.content.Intent intent) Saves this scan activity settings toIntent
so it can be passed to the corresponding scan activity.final void
setBeepSoundResourceID
(int beepSoundResourceID) Defines the resource ID of the sound to be played when recognition is successful.final void
setDebugImageListener
(DebugImageListener debugImageListener) Sets implementation ofDebugImageListener
interface that will obtain images that are being processed.void
setForcedOrientation
(OverlayOrientation orientation) Defines forced overlay orientation.final void
setHelpIntent
(android.content.Intent helpIntent) Defines intent for help activity called when help should be shown.final void
setRegionOfInterestRotatable
(boolean regionOfInterestRotatable) Defines whether ROI (Region of Interest) will be rotated with user interface.final void
setScanRegionOfInterest
(Rectangle scanRegionOfInterest) Sets the scanning ROI (Region of Interest) that will be scanned.final void
setSplashScreenLayoutResourceID
(int splashScreenLayoutResourceID) Defines the ID of the layout resource that will be used as camera splash screen displayed while camera is being initialized.Methods inherited from class com.microblink.photopay.uisettings.UISettings
getActivityTheme, getFilterTouchesWhenObscured, getTargetActivity, getUsingFlagSecure, setActivityTheme, setCameraSettings, setFilterTouchesWhenObscured, setUsingFlagSecure
-
Constructor Details
-
BasicScanUISettings
-
BasicScanUISettings
protected BasicScanUISettings(@NonNull android.content.Intent intent)
-
-
Method Details
-
getRecognizerBundle
Returns theRecognizerBundle
containing recognizers that will be used for processing.- Returns:
- the
RecognizerBundle
containing recognizers that will be used for processing.
-
saveToIntent
public final void saveToIntent(@NonNull android.content.Intent intent) Description copied from class:UISettings
Saves this scan activity settings toIntent
so it can be passed to the corresponding scan activity. Intent target activity must be set before calling this method, and target activity must be compatible with this settings. DO NOT USE THIS METHOD UNLESS YOU KNOW WHAT YOU ARE DOING. Improper usage will crash your app.- Overrides:
saveToIntent
in classUISettings<BasicOverlayController>
- Parameters:
intent
- Intent to which this scan activity settings should be saved.
-
setScanRegionOfInterest
Sets the scanning ROI (Region of Interest) that will be scanned.- Parameters:
scanRegionOfInterest
- scanning ROI.- See Also:
-
setRegionOfInterestRotatable
public final void setRegionOfInterestRotatable(boolean regionOfInterestRotatable) Defines whether ROI (Region of Interest) will be rotated with user interface. Default isfalse
.- Parameters:
regionOfInterestRotatable
- whether ROI (Region of Interest) will be rotated with user interface.- See Also:
-
setBeepSoundResourceID
public final void setBeepSoundResourceID(int beepSoundResourceID) Description copied from interface:BeepSoundUIOptions
Defines the resource ID of the sound to be played when recognition is successful.- Specified by:
setBeepSoundResourceID
in interfaceBeepSoundUIOptions
- Parameters:
beepSoundResourceID
- resource ID of the sound to be played when recognition is successful.
-
setSplashScreenLayoutResourceID
public final void setSplashScreenLayoutResourceID(@LayoutRes int splashScreenLayoutResourceID) Description copied from interface:SplashScreenUIOptions
Defines the ID of the layout resource that will be used as camera splash screen displayed while camera is being initialized. If not set, default splash screen will be used.- Specified by:
setSplashScreenLayoutResourceID
in interfaceSplashScreenUIOptions
- Parameters:
splashScreenLayoutResourceID
- ID of the layout resource that will be used as camera splash screen displayed while camera is being initialized.
-
setDebugImageListener
Description copied from interface:DebugImageListenerUIOptions
Sets implementation ofDebugImageListener
interface that will obtain images that are being processed. DebugImageListener will receive all possible debug images that become available during recognition process.- Specified by:
setDebugImageListener
in interfaceDebugImageListenerUIOptions
- Parameters:
debugImageListener
- Implementation of debug image listener ornull
to clear listener that has been set previously.
-
enableHighResSuccessFrameCapture
public void enableHighResSuccessFrameCapture(boolean enabled) Description copied from interface:HighResSuccessFrameCaptureUIOptions
Sets whether to enable capturing high res frames on recognition success. Default isfalse
.- Specified by:
enableHighResSuccessFrameCapture
in interfaceHighResSuccessFrameCaptureUIOptions
- Parameters:
enabled
-true
if you wish to enable high res success frame capture
-
setForcedOrientation
Defines forced overlay orientation.- Parameters:
orientation
- forced overlay orientation.- See Also:
-
setHelpIntent
public final void setHelpIntent(@Nullable android.content.Intent helpIntent) Description copied from interface:HelpIntentUIOptions
Defines intent for help activity called when help should be shown. If not set or set to null, help button will not be shown in the scanning UI.- Specified by:
setHelpIntent
in interfaceHelpIntentUIOptions
- Parameters:
helpIntent
- intent for help activity called when help should be shown.
-
createOverlayController
@NonNull public BasicOverlayController createOverlayController(@NonNull android.app.Activity activity, @NonNull ScanResultListener scanResultListener) Description copied from class:UISettings
Creates overlay controller and configures it using set values.- Specified by:
createOverlayController
in classUISettings<BasicOverlayController>
-
createOverlaySettingsBuilder
-