be added independently and ad hoc to any application.
Beyond this interesting modular design, there are three specific pieces of functionality in Kinect
Explorer that should be included in any Kinect application. The first is the way Kinect Explorer
implements sensor discovery. As Listing 1-3 shows, the technique implemented in the reference
application waits for Kinect sensors to be connected to a USB port on the computer. It defers any
initialization of the streams until Kinect has been connected and is able to support multiple Kinects.
This code effectively acts as a gatekeeper that prevents any problems that might occur when there is a
disruption in the data streams caused by tripping over a wire or even simply forgetting to plug in the
Kinect sensor.