コード例 #1
0
        private void videoSourcePlayer1_NewFrame(object sender, ref Bitmap image)
        {
            _faceDetector.Detecting(ref image);

            if (_faceDetector.BmpFaceBackProjection != null)
            {
                pbFaceBackProj.Image = _faceDetector.BmpFaceBackProjection;
            }
            if (_faceDetector.BmpFilterFace != null)
            {
                pbFace.Image = _faceDetector.BmpFilterFace;
            }
            if (_faceDetector.BmpRightPupil != null)
            {
                pbPubilRight.Image = _faceDetector.BmpRightPupil;
            }

            if (_faceDetector.BmpLeftPupil != null)
            {
                pbPupilleft.Image = _faceDetector.BmpLeftPupil;
            }

            if (_faceDetector.BmpLeftEye != null)
            {
                pbLeftEye.Image = _faceDetector.BmpLeftEye;
            }

            if (_faceDetector.BmpRightEye != null)
            {
                pbRightEye.Image = _faceDetector.BmpRightEye;
            }
        }