View Full Version : Do you recommend playing AVI files with OpenGL?
Is it good to texture map AVI frames to playback an AVI stream or I should use a more appropriate solution? My OpenGL program needs to playback AVIs and I am wondering if it is a common task to texture map AVI frames for the sake of video playback? On the other side the primary goal of the program is to playback AVIs but it should have some basic drawing capabilities like showing bitmaps - nothing 3D is required. Put this way isn't it better to throw away OpenGL or there is nothing wrong with playing AVIs in OpenGL. I am asking with the hope that I can save some time of useless research for playing AVIs in OpenGL. Thanks.
07-06-2005, 06:52 AM
If you are only 2D based and don't need fancy transparency, the only use for GL would be hardware scaling, and even that can be done without GL on hardware 2D surfaces (but I don't know much about it).
Anyway, it is doable, at least since Quake2 the intro/outro movies where done in GL, with glTexSubImages calls to update the texture. You can even have a look at the Quake 2 GPL'ed sources : http://www.idsoftware.com/business/techdownloads/
I have heard of OpenGL AVI players out there, don't remember more details.
In fact mplayer can use GL as the video out driver but results are very unsatisfactory. I chose to use SDL for video playback. Thanks for answering.
07-07-2005, 08:25 AM
Just for reference, a tutorial about an OpenGL video player : http://www.realityflux.com/abba/html/tutorials/DVTexture.html
There is also a NeHe tutorial on this subject, see
Powered by vBulletin® Version 4.2.3 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.