Package org.openkinect

Examples of org.openkinect.Freenect


}


public class FreenectTest {
  public static void main(String[] args) {
    Freenect kinect = new Freenect();
    TestInterface gui;
   
    try {
      System.out.println("Devices: " + kinect.devices());
      System.out.println("Subdevices: " + kinect.subdevices());

      Device dev = kinect.open(0);
      dev.setLED(Device.LED_GREEN);

      gui = new TestInterface(dev);

      dev.setCallback(gui);

      dev.startVideo();
      dev.startDepth();

      gui.show();
   
      //dev.stopVideo();
      //dev.stopDepth();
      dev.setLED(Device.LED_RED);


    } finally {
      kinect.shutdown();
      System.out.println("DONE");
    }
  }
View Full Code Here


}

public class FreenectAudio
{
  public static void main(String[] args) {
    Freenect kinect = new Freenect();

    try {
      Device dev = kinect.open(0);
      dev.setLED(Device.LED_GREEN);

      dev.setAudioCallback(new Audio());

      dev.startAudio();

      try {
      Thread.sleep(5000);
      } catch(Exception e) {
      }


    } finally {
      kinect.shutdown();
    }
  }
View Full Code Here

TOP

Related Classes of org.openkinect.Freenect

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.