Kinect Sensor Chooser Always Visible? RRS feed

  • Question

  • Hi guys,

    I'm looking to make the KinectSensorChooserUI component from the SDK always stay visible.

    The component flashes whenever a change in the Kinect is detected, but in my application 

    I have an info page that I would like to constantly include this component on.

    Anybody know of a way to stop it fading out?

    Cheers in advance

    Wednesday, March 27, 2013 12:35 PM


  • The code for Microsoft.Kinect.Toolkit.KinectSensorChooserUI is part of the Toolkit project. If you are using the microphone, setting the IsListening="True" property should show the control with a Microphone icon. Since this is just a WPF user control, changing its behavior would be a matter of changing its code to meet your needs. You should make a copy of the project from the Toolkit browser by clicking the "Install" button. Once you build your new control, add that reference .dll to your application to use it. 

    Microsoft.Kinect.Toolkit Component

    The fade in/out is going to be controlled on the bound properties of the control's VisualState. If you are not familiar with WPF this can get a bit complicated. If the control is in a "Started" state, you will need to add a new state so this can be set by the UI(<VisualStateGroup.Transitions>)

    The UpdateState() method of the KinectSensorChooseUiViewModel.cs class is where the states are set based on this.Status property. Setting the IsListening properites, you can see where AllSetListening state would be set:

                if ((this.Status & ChooserStatus.SensorStarted) != 0)
                    if (this.IsListening)
                        newVisualState = "AllSetListening";
                        message = Resources.MessageAllSetListening;
                        newVisualState = "AllSetNotListening";
                        message = Resources.MessageAllSet;

    Friday, March 29, 2013 9:19 PM