I've been playing about with Microsoft Kinect using the OpenNI SDK, and it has mostly been going well. I have managed to implement a user tracker to remove the background and replace it with a bitmap image. Only problem is I'm new to textures so I don't think I have been doing it very efficiently, hence my program becomes very jittery.
I have been trying to use glBindTexture() as I was previously usng glTexImage2D() each time in display which was causing the jittery display, but all I get at run time is a white screen.
In main just before I call glutDisplayFunc:
Then in display:
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGB, image->width, image->height, 0, GL_RGB, GL_UNSIGNED_BYTE, image->pixels);
Thanks in advance,
if(g_nViewState != DISPLAY_MODE_IMAGE)
// upper left
// upper right
// bottom right
// bottom left