Esempio n. 1
0
 public override void OnNewItem(int id, Java.Lang.Object item)
 {
     mFaceGraphic.SetId(id);
     if (mCameraSource != null && !isProcessing)
     {
         mCameraSource.TakePicture(null, this);
     }
 }
Esempio n. 2
0
        public override void OnNewItem(int id, Java.Lang.Object item)
        {
            mFaceGraphic.SetId(id);
            try
            {
                Task.Run(async() =>
                {
                    await Task.Delay(200);
                    if (mCameraSource != null && !isProcessing)
                    {
                        mCameraSource.TakePicture(null, this);
                    }
                });


                _face = item as Face;
                Console.WriteLine($"position x: {_face.Position.X} position y: {_face.Position.Y} width: {_face.Width} height: {_face.Height}");
            }
            catch (System.Exception e)
            {
                Console.WriteLine("==================================================");
                Console.WriteLine(e);
            }
        }