tags:

views:

62

answers:

1

how to create API development for openGL texture from live cameras

+1  A: 

I think I understood what you tried to say. First, let's identify a few tasks:

  • You need to find a way to retrieve the video frames from the camera:

This can be done very easily with OpenCV. It is possible to find several examples of this on StackOverflow.

  • Store the pixels from the frames as 2D textures of OpenGL:

This is a very well known technique called texture mapping. You'll probably use a similar sequence of calls to do it: glGenTextures(), glBindTexture(), and finally glTexImage2D() to attach the pixels to the texture.

  • What to do with it?

You forgot to mention what you would like to do with it, but my guess is that you want to display the images on the screen. This means you'll have to create a window using GLUT. You will certainly find dozens of thousands of examples on Google showing how to achieve this.

Please note that the libraries I suggested are all cross-platform, and they will work on Windows/Linux/Mac OS X.

karlphillip