// Use this for initialization void Start() { // Find a Kinect sensor KinectSensorCollection kinectSensors = KinectSensor.KinectSensors; if (kinectSensors.Count == 0) { this.sensor = null; throw new UnityException("Could not find a Kinect sensor."); } // Enable the skeleton stream this.sensor = kinectSensors[0]; this.sensor.SkeletonStream.Enable(); if (!this.sensor.SkeletonStream.IsEnabled) { throw new UnityException("Sensor could not be enabled."); } // Create the input processor inputProcessor = new InputProcessor(this.sensor.CoordinateMapper, DepthImageFormat.Resolution320x240Fps30); this.InputInfo = inputProcessor.GameInputInfo; this.seatedInputProcessor = new SeatedInfoProcessor(); Debug.Log("Hello"); return; }
// Use this for initialization void Start() { // Find a Kinect sensor KinectSensorCollection kinectSensors = KinectSensor.KinectSensors; if(kinectSensors.Count == 0) { this.sensor = null; throw new UnityException("Could not find a Kinect sensor."); } // Enable the skeleton stream this.sensor = kinectSensors[0]; this.sensor.SkeletonStream.Enable(); if(!this.sensor.SkeletonStream.IsEnabled) { throw new UnityException("Sensor could not be enabled."); } // Create the input processor this.inputProcessor = new SeatedInfoProcessor(); //inputProcessor = new InputProcessor(this.sensor.CoordinateMapper, DepthImageFormat.Resolution320x240Fps30); this.InputInfo = null; Debug.Log("Hello"); return; }
// Input processor //InputProcessor inputProcessor; // Use this for initialization void Start() { // Find a Kinect sensor KinectSensorCollection kinectSensors = KinectSensor.KinectSensors; if (kinectSensors.Count == 0) { this.sensor = null; throw new UnityException("Could not find a Kinect sensor."); } // Enable the skeleton stream this.sensor = kinectSensors[0]; this.sensor.SkeletonStream.Enable(); if (!this.sensor.SkeletonStream.IsEnabled) { throw new UnityException("Sensor could not be enabled."); } // Create the input processor seatedInfoProcessor = new SeatedInfoProcessor(); seatedInfo = null; Debug.Log("Hello"); return; }