joshuajnoble / ofxKinectV2

of addon for Kinect V2
47 stars 22 forks source link

No color values #11

Open paolo-scoppola opened 9 years ago

paolo-scoppola commented 9 years ago

Hi, I can't se any rgb image. I removed any call to methods for other kind of images, but there is no way to have colors. I have also a crash if I don't initialize the depth frame....

setup() {

kinect.initSensor(); kinect.initColorStream();

}

update() {

kinect.update();

}

draw() {

kinect.draw(0,0); }

chriship commented 9 years ago

I also am having this issue. Everything else works fine (depth, skeleton) but I cannot get the normal colour image back.

EDIT:

I realised that it is because of line 147 in ofxKinectCommonBridge.cpp

I changed:

videoTex.loadData(pColorFrame->Buffer, colorFrameDescription.width, colorFrameDescription.height, GL_RG16);

to:

videoTex.loadData(pColorFrame->Buffer, colorFrameDescription.width, colorFrameDescription.height, GL_RGBA);

And it works fine.