コード例 #1
0
        public void UpdateKinectTilt(int degrees)
        {
            kinectProxy.UpdateTiltRequest request = new kinectProxy.UpdateTiltRequest();
            request.Tilt = degrees;

            Activate(
                Arbiter.Choice(
                    this.kinectPort.UpdateTilt(request),
                    success =>
            {
                // nothing to do
            },
                    fault =>
            {
                // the fault handler is outside the WPF dispatcher
                // to perfom any UI related operation we need to go through the WPF adapter

                // show an error message
                this.wpfServicePort.Invoke(() => this.userInterface.ShowFault(fault));
            }));
        }
コード例 #2
0
        public void UpdateKinectTilt(int degrees)
        {
            kinectProxy.UpdateTiltRequest request = new kinectProxy.UpdateTiltRequest();
            request.Tilt = degrees;

            Activate(
                Arbiter.Choice(
                    this.kinectPort.UpdateTilt(request),
                    success =>
                    {
                        // nothing to do
                    },
                    fault =>
                    {
                        // the fault handler is outside the WPF dispatcher
                        // to perfom any UI related operation we need to go through the WPF adapter

                        // show an error message
                        this.wpfServicePort.Invoke(() => this.userInterface.ShowFault(fault));
                    }));
        }