Kinect not connected

396 views
Skip to first unread message

Saraigate .gmail

unread,
Apr 12, 2014, 7:53:35 PM4/12/14
to simple-ope...@googlegroups.com
Hey,

I am trying to run a sketch:

// import library
import SimpleOpenNI.*;
// declare SimpleOpenNI object
SimpleOpenNI context;

// PImage to hold incoming imagery
PImage cam;

void setup() {
// same as Kinect dimensions
size(640, 480);
// initialize SimpleOpenNI object
context = new SimpleOpenNI(this);
if (!context.enableUser()) {
// if context.enableScene() returns false
// then the Kinect is not working correctly
// make sure the green light is blinking
println("Kinect not connected!");
exit();
} else {
// mirror the image to be more intuitive
context.setMirror(true);
}
}

void draw() {
// update the SimpleOpenNI object
context.update();
// put the image into a PImage
cam = context.userImage().get();
// display the image
image(cam, 0, 0);
}


I keep getting the error "Kinect not connected"
and SimpleOpenNI Error: Can't open device

I have the kinect connected and it works fine on other sketches. I am using Processing 2.1.1 and SimpleOpenNI version 1.96.
Can anyone help? Thanks!

Saraigate .gmail

unread,
Apr 27, 2014, 9:56:00 PM4/27/14
to simple-ope...@googlegroups.com
Problem solved. It was missing context.enable()

Yan Nan

unread,
Dec 11, 2014, 1:19:05 AM12/11/14
to simple-ope...@googlegroups.com
hello, I am wondering what do you mean that it was missing context.enable().
Reply all
Reply to author
Forward
0 new messages