public override void ViewDidLoad()
        {
            base.ViewDidLoad();
            // Perform any additional setup after loading the view, typically from a nib.

            customDelegate = new CustomDelegate(this);

            // set license key for iOS with bundle ID com.microblink.xamarin.blinkid
            MBMicroblinkSDK.SharedInstance.SetLicenseKey("sRwAAAEeY29tLm1pY3JvYmxpbmsueGFtYXJpbi5ibGlua2lks3unDF2B9jpa6FeAxSjaWUg1ROYBfuTUj5ciQyp9KpRtdClsjclAqYTT1BA7QMj6tUv6yIwdGZNSUhiR253O9Zugyv6tsc8hB9XvpMvDAHOiAmgzkj5SacPTjp5C4xZwKCmER2NUf4YSDddznrI7btd5cNnr0Bc5lT0wNHzlN7Z6r04dqoI+jzrCW65IgF8DrA/t4C6O0/lxthm+IfAmobL0kfI0ui6/fy3m8OZ31AacLKO1qb4T0A==");

            mrtdRecognizer = new MBMrtdRecognizer();
            usdlRecognizer = new MBUsdlRecognizer();
            eudlRecognizer = new MBEudlRecognizer();
        }
        public override void ViewDidLoad()
        {
            base.ViewDidLoad();
            // Perform any additional setup after loading the view, typically from a nib.

            customDelegate = new CustomDelegate(this);

            // set license key for iOS with bundle ID com.microblink.xamarin.blinkid
            MBMicroblinkSDK.SharedInstance.SetLicenseKey("sRwAAAEeY29tLm1pY3JvYmxpbmsueGFtYXJpbi5ibGlua2lks3unDF2B9jpa6FeAx5h89osjSFXqQRtWjes0WSEXe3rubgFApHsFdSF2oJZL0MhSL18AgbaLmPiOT3RFu+lqtKtpsjqRfxEVmc9cU98GnjciEeAOC331OUeT5R1p7zKqsenX/3IytQJuMG4ruEaRXc5746y/Kv8ch0XDgv/nRu4siNlvpkjsUjkeyokbUUwi+uzL6t2G4V/sX0SXTMWPjG7zjtW4ovwpGs6fct/dpBJQfzRQNCn9kg==");

            mrtdRecognizer = new MBMrtdRecognizer();
            usdlRecognizer = new MBUsdlRecognizer();
            eudlRecognizer = new MBEudlRecognizer();
        }
Esempio n. 3
0
        partial void StartScanningButton_TouchUpInside(UIButton sender)
        {
            mrtdRecognizer = new MBMrtdRecognizer();
            usdlRecognizer = new MBUsdlRecognizer();
            eudlRecognizer = new MBEudlRecognizer();

            // create a collection of recognizers that will be used for scanning
            var recognizerCollection = new MBRecognizerCollection(new MBRecognizer[] { mrtdRecognizer, eudlRecognizer, usdlRecognizer });

            // create a settings object for overlay that will be used. For ID it's best to use DocumentOverlayViewController
            // there are also other overlays available - check iOS documentation
            var documentOverlaySettings = new MBDocumentOverlaySettings();
            var documentOverlay         = new MBDocumentOverlayViewController(documentOverlaySettings, recognizerCollection, customDelegate);

            // finally, create a recognizerRunnerViewController
            var recognizerRunnerViewController = MBViewControllerFactory.RecognizerRunnerViewControllerWithOverlayViewController(documentOverlay);

            // in ObjC recognizerRunnerViewController would actually be of type UIViewController<MBRecognizerRunnerViewController>*, but this construct
            // is not supported in C#, so we need to use Runtime.GetINativeObject to cast obtained IMBReocognizerRunnerViewController into UIViewController
            // that can be presented
            this.PresentViewController(ObjCRuntime.Runtime.GetINativeObject <UIViewController>(recognizerRunnerViewController.Handle, false), true, null);
        }
Esempio n. 4
0
 public MrtdRecognizer() : base(new MBMrtdRecognizer())
 {
     nativeRecognizer = NativeRecognizer as MBMrtdRecognizer;
     result           = new MrtdRecognizerResult(nativeRecognizer.Result);
 }