public static BarcodeResult[] FindBarcodes(UIImage image)
        {
            if (image == null)
                throw new ArgumentNullException ("image");

            IntPtr result = FindBarcodesInUIImage (image.Handle);
            if (result == IntPtr.Zero)
                return null;

            NSSet aset = new NSSet (result);
            BarcodeResult[] results = aset.ToArray<BarcodeResult> ();
            aset.Dispose ();

            return results;
        }
예제 #2
0
        public static BarcodeResult[] FindBarcodes(UIImage image)
        {
            if (image == null)
            {
                throw new ArgumentNullException("image");
            }

            IntPtr result = FindBarcodesInUIImage(image.Handle);

            if (result == IntPtr.Zero)
            {
                return(null);
            }

            NSSet aset = new NSSet(result);

            BarcodeResult[] results = aset.ToArray <BarcodeResult> ();
            aset.Dispose();

            return(results);
        }