public void Init(FaceCompreaSet faceCompreaSet)
 {
     this._faceCompreaSet = faceCompreaSet;
     this._faceCompreaSet.FaceTemplates = faceCompreaSet.FaceTemplates;
     this._faceCompare1 = FaceFactory.Create(this._faceCompreaSet.FaceCompareType);
     this._faceCompare1.CreateFaceEngne();
     this._faceCompreaThread = new FaceCompreaThread(this._faceCompreaSet, this._faceCompare1);
     this._faceDeteiveThread = new FaceDeteiveThread(this._faceCompreaThread, this._faceCompreaSet);
     this._faceCaller        = new Thread(new ThreadStart(this._faceCompreaThread.Execute));
     this._captureCaller     = new Thread(new ThreadStart(this._faceDeteiveThread.Execute));
     this._captureHelper     = new CaptureHelper(this._faceDeteiveThread, this._faceCompreaSet);
 }
Example #2
0
        public static IFaceCompare Create(FaceCompareType faceCompareType)
        {
            IFaceCompare result = null;

            switch (faceCompareType)
            {
            case FaceCompareType.FaceCompareBase:
                result = new FaceCompareBase();
                break;

            case FaceCompareType.FaceComparePro:
                result = new FaceComparePro();
                break;

            case FaceCompareType.FaceCompareV4:
                result = new FaceCompareV4();
                break;

            case FaceCompareType.FaceCompareV2:
                result = new FaceCompareV2();
                break;
            }
            return(result);
        }
Example #3
0
 public FaceCompreaThread(FaceCompreaSet faceCompreaSet, IFaceCompare faceCompare)
 {
     this._stop             = false;
     this._faceCompreaSet   = faceCompreaSet;
     this._ifaceCompareBase = faceCompare;
 }