View Full Version : library to load a video as a texture

03-17-2010, 11:02 AM

I'd like to use a video (avi, mpeg, etc) as a texture in opengl. Do you know a good lib I can use?

Besides, do you have an idea of the reasonable number of videos I can load simultaneously on a resonable computer, without being under the 30fps??? I read that the transfer of surface from the CPU memory to the GPU memory costs a lot of time!!! :(


03-17-2010, 11:06 AM
I recommend Ogg Theora!
Here's nice library that will do lowlevel decoding for you: http://code.google.com/p/liboggplayer/
It also includes OpenGL renderer example that uses GLSL shader to accelerate yuv->rgb conversion.

03-17-2010, 12:23 PM
About the number of streams : it will depend of the resolution (standard or HD etc). Streaming texture data from CPU to GPU using async PBO is not that costly. I heard of a dozen simultaneous video streams around these forums.

03-24-2010, 11:32 AM
@ ZbuffeR: thanks!

@ martinsm: liboggplayer seems very easy to use! Great! However, it only works with ogg videos, isn't it? I haven't see any documentation.