Capacitor plugin of Dynamsoft Label Recognizer which brings text recognition ability to your apps.
For Capacitor v6, use v2.x.
For Capacitor v5, use v1.x.
For Capacitor v4, use v0.x.
Product | Android | iOS | Web |
---|---|---|---|
Dynamsoft Label Recognizer | 2.x | 2.x | 2.x |
npm install capacitor-plugin-dynamsoft-label-recognizer
npx cap sync
initialize()
initLicense(...)
recognizeBase64String(...)
recognizeBitmap(...)
updateRuntimeSettings(...)
resetRuntimeSettings()
setEngineResourcesPath(...)
addListener('onResourcesLoadStarted', ...)
addListener('onResourcesLoaded', ...)
removeAllListeners()
- Interfaces
- Type Aliases
initialize() => Promise<void>
initLicense(options: { license: string; }) => Promise<void>
Param | Type |
---|---|
options |
{ license: string; } |
recognizeBase64String(options: { base64: string; }) => Promise<{ results: DLRResult[]; }>
Param | Type |
---|---|
options |
{ base64: string; } |
Returns: Promise<{ results: DLRResult[]; }>
recognizeBitmap(options: { className?: string; methodName?: string; }) => Promise<{ results: DLRResult[]; }>
Android and iOS only method which directly read camera frames from capacitor-plugin-camera
Param | Type |
---|---|
options |
{ className?: string; methodName?: string; } |
Returns: Promise<{ results: DLRResult[]; }>
updateRuntimeSettings(options: { settings: RuntimeSettings; }) => Promise<void>
Param | Type |
---|---|
options |
{ settings: RuntimeSettings; } |
resetRuntimeSettings() => Promise<void>
setEngineResourcesPath(options: { path: string; }) => Promise<void>
Param | Type |
---|---|
options |
{ path: string; } |
addListener(eventName: 'onResourcesLoadStarted', listenerFunc: onResourcesLoadStartedListener) => Promise<PluginListenerHandle>
Param | Type |
---|---|
eventName |
'onResourcesLoadStarted' |
listenerFunc |
onResourcesLoadStartedListener |
Returns: Promise<PluginListenerHandle>
addListener(eventName: 'onResourcesLoaded', listenerFunc: onResourcesLoadedListener) => Promise<PluginListenerHandle>
Param | Type |
---|---|
eventName |
'onResourcesLoaded' |
listenerFunc |
onResourcesLoadedListener |
Returns: Promise<PluginListenerHandle>
removeAllListeners() => Promise<void>
Prop | Type |
---|---|
location |
DLRQuadrilateral |
confidence |
number |
lineResults |
DLRLineResult[] |
Prop | Type |
---|---|
points |
DLRPoint[] |
Prop | Type |
---|---|
x |
number |
y |
number |
Prop | Type |
---|---|
text |
string |
location |
DLRQuadrilateral |
confidence |
number |
isCheckDigitMatched |
boolean |
Prop | Type |
---|---|
template |
string |
customModelConfig |
CustomModelConfig |
Prop | Type |
---|---|
customModelFolder |
string |
customModelFileNames |
string[] |
Prop | Type |
---|---|
remove |
() => Promise<void> |
(resourcePath: string): void
(resourcePath: string): void