Exemplo n.º 1
0
        /// <summary>
        /// Loads the correct procesor based on the selected radio button
        /// </summary>
        private void LoadProcessor()
        {
            if (this.viewModel.ProcessorType == ProcessorTypes.FaceModel)
            {
                this.activeProcessor = new FaceModelRecognitionProcessor();
            }
            else
            {
                this.activeProcessor = new EigenObjectRecognitionProcessor();
            }

            this.LoadAllTargetFaces();
            this.UpdateTargetFaces();

            if (this.engine == null)
            {
                this.engine = new KinectFacialRecognitionEngine(this.kinectSensor, this.activeProcessor);
                this.engine.RecognitionComplete += this.Engine_RecognitionComplete;
            }

            this.engine.Processors = new List <IRecognitionProcessor> {
                this.activeProcessor
            };
        }
Exemplo n.º 2
0
        /// <summary>
        /// Loads the correct procesor based on the selected radio button (currently only EigenObject)
        /// </summary>
        private void LoadProcessor()
        {
            this.activeProcessor = new EigenObjectRecognitionProcessor();

            this.LoadAllTargetFaces();
            this.UpdateTargetFaces();

            if (this.engine == null)
            {
                this.engine = new KinectFacialRecognitionEngine(this.kinectSensor, this.activeProcessor);
                this.engine.RecognitionComplete += this.Engine_RecognitionComplete;
            }

            this.engine.Processors = new List<IRecognitionProcessor> { this.activeProcessor };
        }