public bool HandleKeyPress(char key)
        {
            var handled       = true;
            var captureConfig = new CaptureConfig();

            switch (key)
            {
            case '7':
                captureConfig.Framerate  = 40;
                captureConfig.Resolution = new Resolution(128, 96);
                _serverToCameraBus.InvokeUpdateCapture(captureConfig);
                break;

            case '8':
                captureConfig.Framerate  = 60;
                captureConfig.Resolution = new Resolution(160, 120);
                _serverToCameraBus.InvokeUpdateCapture(captureConfig);
                break;

            case 'a':
                ForceMode(ProcessingMode.Autonomous);
                break;

            case 'f':
                ForceMode(ProcessingMode.FaceDetection);
                break;

            case 'c':
                ForceMode(ProcessingMode.ColourTrackFromFileSettings);
                break;

            case 'q':
                _screen.WriteLine($"P/T={CurrentSetting},M={State}");
                break;

            case 'r':
                var command = new PanTiltSettingCommand();
                command.Type        = PanTiltSettingCommandType.MoveAbsolute;
                command.PanPercent  = 50;
                command.TiltPercent = 50;
                HandleCommand(this, command);
                break;

            default:
                handled = false;
                break;
            }
            return(handled);
        }
        public bool HandleKeyPress(char key)
        {
            var handled       = true;
            var captureConfig = new CaptureConfig();

            switch (key)
            {
            case '7':
                captureConfig.Framerate  = 40;
                captureConfig.Resolution = new Resolution(128, 96);
                _serverToCameraBus.InvokeUpdateCapture(captureConfig);
                break;

            case '8':
                captureConfig.Framerate  = 40;
                captureConfig.Resolution = new Resolution(160, 120);
                _serverToCameraBus.InvokeUpdateCapture(captureConfig);
                break;

            case 'a':
                SetMode(ProcessingMode.Autonomous);
                break;

            case 'r':
                var command = new PanTiltSettingCommand();
                command.Type        = PanTiltSettingCommandType.MoveAbsolute;
                command.PanPercent  = 50;
                command.TiltPercent = 50;
                HandleCommand(this, command);
                break;

            default:
                handled = false;
                break;
            }
            return(handled);
        }