private void SetPTZSpeed(double panSpeed, double tiltSpeed)
        {
            PTZControlModel ptzModel = this.DataContext as PTZControlModel;

            if (ptzModel != null)
            {
                ptzModel.PanTiltMove(panSpeed, tiltSpeed);
            }
            _count++;
            Console.WriteLine(DateTime.Now.TimeOfDay + " Count: " + _count + " " + panSpeed + "  " + tiltSpeed);
            //Console.WriteLine("X:" + panSpeed + "__Y:" + tiltSpeed);
        }
 public RealTimeControlModel()
 {
     StreamType                   = new CollectionViewSource();
     SelectedStreamType           = DefaultStreamType;
     VideoInfoMessage             = new VideoInfoMessageViewModel();
     PTZControl                   = new PTZControlModel();
     PresetModel                  = new PresetViewModel();
     SwitchModel                  = new SwitchPanelViewModel();
     TrackSource                  = new VideoTrackViewModel(VideoId);
     PropertyChanged             += onPropertyChanged;
     PTZControl.PropertyChanged  += PTZControl_PropertyChanged;
     TrackSource.PropertyChanged += TrackSource_PropertyChanged;
 }