Пример #1
0
        /// <summary></summary>
        /// <param name="kinectConnector"></param>
        public KinectBodyDrawer(KinectConnector kinectConnector)
        {
            this.kinectConnector = kinectConnector;

            drawingGroup = new DrawingGroup();
            ImageSource = new DrawingImage(drawingGroup);

            kinectConnector.BodyUpdated += (_, e) => Draw(e.Body);
        }
Пример #2
0
        /// <summary></summary>
        /// <param name="kinectConnector"></param>
        public KinectBodyDrawer(KinectConnector kinectConnector)
        {
            this.kinectConnector = kinectConnector;

            drawingGroup = new DrawingGroup();
            ImageSource  = new DrawingImage(drawingGroup);

            kinectConnector.BodyUpdated += (_, e) => Draw(e.Body);
        }
        public KinectBoneViewerViewModel(KinectConnector connector)
        {
            IsViewerExists = true;

            var drawer = new KinectBodyDrawer(connector);
            this.ImageSource = drawer.ImageSource;
            connector.BodyUpdated += (_, e) => drawer.Draw(e.Body);

            CloseWindowCommand = new RelayCommand(() => IsViewerExists = false);
        }
Пример #4
0
        public KinectBoneViewerViewModel(KinectConnector connector)
        {
            IsViewerExists = true;

            var drawer = new KinectBodyDrawer(connector);

            this.ImageSource       = drawer.ImageSource;
            connector.BodyUpdated += (_, e) => drawer.Draw(e.Body);

            CloseWindowCommand = new RelayCommand(() => IsViewerExists = false);
        }
Пример #5
0
 public void Dispose()
 {
     AngleDataSender.Dispose();
     KinectConnector.Dispose();
 }