Skip to content

Limitations

Timeouts

Use the parameter to set the time limit (in seconds) for the document recognition, beyond which the recognition does not continue regardless of its result.

You can define the moment for the countdown to start.

  • Start the countdown from the moment the scenario starts:
DocReader.shared.processParams.timeout = 20
[RGLDocReader shared].processParams.timeout = @20;
DocumentReader.Instance().processParams().timeout = 20.0
DocumentReader.Instance().processParams().timeout = 20.0;
DocumentReader.instance.processParams.timeout = 20;
DocumentReader.setProcessParams({
    timeout: 20.0
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    timeout: 20.0
});
DocumentReader.setProcessParams({
    timeout: 20.0
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().Timeout = (Java.Lang.Double)20.0;

// iOS
RGLDocReader.Shared.ProcessParams.Timeout = 20.0;
  • Start the countdown from the moment the document is detected:
DocReader.shared.processParams.timeoutFromFirstDetect = 5
[RGLDocReader shared].processParams.timeoutFromFirstDetect = @5;
DocumentReader.Instance().processParams().timeoutFromFirstDetect = 5.0
DocumentReader.Instance().processParams().timeoutFromFirstDetect = 5.0;
DocumentReader.instance.processParams.timeoutFromFirstDetect = 5;
DocumentReader.setProcessParams({
    timeoutFromFirstDetect: 5.0
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    timeoutFromFirstDetect: 5.0
});
DocumentReader.setProcessParams({
    timeoutFromFirstDetect: 5.0
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().TimeoutFromFirstDetect = (Java.Lang.Double)5.0;

// iOS
RGLDocReader.Shared.ProcessParams.TimeoutFromFirstDetect = 5.0;
  • Start the countdown from the moment the document type is recognized:
DocReader.shared.processParams.timeoutFromFirstDocType = 3
[RGLDocReader shared].processParams.timeoutFromFirstDocType = @3;
DocumentReader.Instance().processParams().timeoutFromFirstDocType = 3.0
DocumentReader.Instance().processParams().timeoutFromFirstDocType = 3.0;
DocumentReader.instance.processParams.timeoutFromFirstDocType = 3;
DocumentReader.setProcessParams({
    timeoutFromFirstDocType: 3.0
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    timeoutFromFirstDocType: 3.0
});
DocumentReader.setProcessParams({
    timeoutFromFirstDocType: 3.0
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().TimeoutFromFirstDocType = (Java.Lang.Double)3.0;

// iOS
RGLDocReader.Shared.ProcessParams.TimeoutFromFirstDocType = 3.0;
  • Start the countdown (in seconds) from the moment the document liveness authenticity check starts:
DocReader.shared.processParams.timeoutLiveness = 10
[RGLDocReader shared].processParams.timeoutLiveness = @10;
DocumentReader.Instance().processParams().timeoutLiveness = 10.0
DocumentReader.Instance().processParams().timeoutLiveness = 10.0;
DocumentReader.instance.processParams.timeoutLiveness = 10;
DocumentReader.setProcessParams({
    timeoutLiveness: 10.0
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    timeoutLiveness: 10.0
});
DocumentReader.setProcessParams({
    timeoutLiveness: 10.0
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().TimeoutLiveness = (Java.Lang.Double)10.0;

// iOS
RGLDocReader.Shared.ProcessParams.TimeoutLiveness = 10.0;

Barcode recognition

  • Set the types of barcodes to process:
DocReader.shared.processParams.barcodeTypes = [BarcodeType.QRCODE.rawValue as NSNumber, BarcodeType.AZTEC.rawValue as NSNumber]
[RGLDocReader shared].processParams.barcodeTypes = @[@(RGLBarcodeTypeQRCODE), @(RGLBarcodeTypeAZTEC)];
DocumentReader.Instance().processParams().doBarcodes = arrayOf(BarcodeType.valueOf(BarcodeType.PDF417), BarcodeType.valueOf(BarcodeType.QRCODE))
DocumentReader.Instance().processParams().doBarcodes = new String[]{BarcodeType.valueOf(BarcodeType.PDF417), BarcodeType.valueOf(BarcodeType.QRCODE)};
DocumentReader.instance.processParams.barcodeTypes = [
  BarcodeType.PDF417,
  BarcodeType.QRCODE
];
DocumentReader.setProcessParams({
    barcodeTypes: [BarcodeType.PDF417, BarcodeType.QRCODE]
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    barcodeTypes: [Enum.BarcodeType.PDF417, Enum.BarcodeType.QRCODE]
});
DocumentReader.setProcessParams({
    barcodeTypes: [DocumentReader.Enum.BarcodeType.PDF417, DocumentReader.Enum.BarcodeType.QRCODE]
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().DoBarcodes = new String[] { BarcodeType.ValueOf(BarcodeType.Pdf417), BarcodeType.ValueOf(BarcodeType.Qrcode) };

// iOS
RGLDocReader.Shared.ProcessParams.BarcodeTypes = new NSNumber[] { (int)RGLBarcodeType.Pdf417, (int)RGLBarcodeType.Qrcode };
  • Enable the following parameter to force the Barcode Format check failing if the certificates required for performing the Digital Signature check are missing:
DocReader.shared.processParams.strictBarcodeDigitalSignatureCheck = true
[RGLDocReader shared].processParams.strictBarcodeDigitalSignatureCheck = @YES;
DocumentReader.Instance().processParams().strictBarcodeDigitalSignatureCheck = false
DocumentReader.Instance().processParams().strictBarcodeDigitalSignatureCheck = false;
DocumentReader.instance.processParams.strictBarcodeDigitalSignatureCheck = true;
DocumentReader.setProcessParams({
    strictBarcodeDigitalSignatureCheck: true
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    strictBarcodeDigitalSignatureCheck: true
});
DocumentReader.setProcessParams({
    strictBarcodeDigitalSignatureCheck: true
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().StrictBarcodeDigitalSignatureCheck = (Java.Lang.Boolean)true;

// iOS
RGLDocReader.Shared.ProcessParams.StrictBarcodeDigitalSignatureCheck = true;

Document recognition

DocReader.shared.processParams.documentIDList = [-274257313, -2004898043]
[RGLDocReader shared].processParams.documentIDList = @[@(-274257313), @(-2004898043)];
DocumentReader.Instance().processParams().documentIDList = intArrayOf(-274257313, -2004898043)
DocumentReader.Instance().processParams().documentIDList = new int[]{-274257313, -2004898043};
DocumentReader.instance.processParams.documentIDList = [
  -274257313,
  -2004898043
];
DocumentReader.setProcessParams({
    documentIDList: [-274257313, -2004898043]
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    documentIDList: [-274257313, -2004898043]
});
DocumentReader.setProcessParams({
    documentIDList: [-274257313, -2004898043]
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().DocumentIDList = new int[] { -274257313, -2004898043 };

// iOS
RGLDocReader.Shared.ProcessParams.DocumentIDList = new NSNumber[] { -274257313, -2004898043 };
  • Set the minimum acceptable DPI value:
DocReader.shared.processParams.minDPI = 100
[RGLDocReader shared].processParams.minDPI = @100;
DocumentReader.Instance().processParams().minDPI = 100
DocumentReader.Instance().processParams().minDPI = 100;
DocumentReader.instance.processParams.minDPI = 100;
DocumentReader.setProcessParams({
    minDPI: 100
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    minDPI: 100
});
DocumentReader.setProcessParams({
    minDPI: 100
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().MinDPI = (Java.Lang.Integer)100;

// iOS
RGLDocReader.Shared.ProcessParams.MinDPI = 100;
  • Use a specific template ID and skip the document type identification step:
DocReader.shared.processParams.forceDocID = 123
RGLDocReader.shared.processParams.forceDocID = @123;
DocumentReader.Instance().processParams().forceDocID = 123
DocumentReader.Instance().processParams().forceDocID = 123;
DocumentReader.instance.processParams.forceDocID = 123;
DocumentReader.setProcessParams({
    forceDocID: 123
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    forceDocID: 123
});
DocumentReader.setProcessParams({
    forceDocID: 123
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().ForceDocID = (Java.Lang.Integer)123;

// iOS
RGLDocReader.Shared.ProcessParams.ForceDocID = 123;
  • Ignore assumptions based on the field mask in the template:
DocReader.shared.processParams.matchTextFieldMask = true
RGLDocReader.shared.processParams.matchTextFieldMask = @YES;
DocumentReader.Instance().processParams().matchTextFieldMask = true
DocumentReader.Instance().processParams().matchTextFieldMask = true;
DocumentReader.instance.processParams.matchTextFieldMask = true;
DocumentReader.setProcessParams({
    matchTextFieldMask: true
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    matchTextFieldMask: true
});
DocumentReader.setProcessParams({
    matchTextFieldMask: true
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().MatchTextFieldMask = (Java.Lang.Boolean)true;

// iOS
RGLDocReader.Shared.ProcessParams.MatchTextFieldMask = true;
  • Guarantee that an output image contains the correct MRZ on it in the series process mode:
DocReader.shared.processParams.forceReadMrzBeforeLocate = true
RGLDocReader.shared.processParams.forceReadMrzBeforeLocate = @YES;
DocumentReader.Instance().processParams().forceReadMrzBeforeLocate = true
DocumentReader.Instance().processParams().forceReadMrzBeforeLocate = true;
DocumentReader.instance.processParams.forceReadMrzBeforeLocate = true;
DocumentReader.setProcessParams({
    forceReadMrzBeforeLocate: true
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    forceReadMrzBeforeLocate: true
});
DocumentReader.setProcessParams({
    forceReadMrzBeforeLocate: true
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().ForceReadMrzBeforeLocate = (Java.Lang.Boolean)true;

// iOS
RGLDocReader.Shared.ProcessParams.ForceReadMrzBeforeLocate = true;
  • Limit MRZ formats to be recognized by specifying them in array:
DocReader.shared.processParams.mrzFormatsFilter = [MRZFormat.ID2.rawValue as NSNumber, MRZFormat.ID1.rawValue as NSNumber]
RGLDocReader.shared.processParams.mrzFormatsFilter = @[@(RGLMRZFormatID2), @(RGLMRZFormatID1)];
DocumentReader.Instance().processParams().mrzFormatsFilter = arrayOf(MRZFormat.FORMAT_2X44, MRZFormat.FORMAT_3X30)
DocumentReader.Instance().processParams().mrzFormatsFilter = new String[]{MRZFormat.FORMAT_2X44, MRZFormat.FORMAT_3X30};
DocumentReader.instance.processParams.mrzFormatsFilter = [
  MRZFormat.FORMAT_2X44,
  MRZFormat.FORMAT_3X30
];
DocumentReader.setProcessParams({
    mrzFormatsFilter: [MRZFormat.ID2, MRZFormat.ID1]
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
    mrzFormatsFilter: [MRZFormat.ID2, MRZFormat.ID1]
});
DocumentReader.setProcessParams({
    mrzFormatsFilter: [MRZFormat.ID2, MRZFormat.ID1]
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().MrzFormatsFilter = new string[] { MRZFormat.Format2x44, MRZFormat.Format3x30 };

// iOS
RGLDocReader.Shared.ProcessParams.MrzFormatsFilter = new NSNumber[] { (int)RGLMRZFormat.Id2, (int)RGLMRZFormat.Id1 };

Next Steps