Playign AVI

Hey I am trying to use a class for playing a avi file and I am geting errors that have to do with pointers. I am RELLY NEW to programing in c++ and was wondering if someone would be nice enough to email the debuged code to me or put it somewhere I could get to it.

My email address is: bobertperry@hotmail.com

I got it from: http://ourworld.compuserve.com/homepages/leseb/

Thanks so

This has nothing to do with OpenGL.
MSDN has documentation and code samples. (GDI, Video for Windows)

I fixed it up for MSVC++ 6.0 (I assume that’s what you wanted?) http://personal.lig.bellsouth.net/~dfrey/glvid.zip

Thanks SO MUCH!!! Now the code works, but it is so fliping slow. I mean with a geforce 2mx and 192 mgs of ram i am geting around 2 or 3 frames per sec. while it is playing. Her demo worked. Is it the way i am drawing the rectangle?

heres some code.

glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);		// Clear Screen And Depth Buffer


Vidio1.glGetFrameRGBA(floorl((clock()-timeBeginning)/CLK_TCK*1000),**texturearray,256,256);
glEnable(GL_TEXTURE_2D); 
glBegin(GL_QUADS);
	glTexCoord2d(0,0);		glVertex2d(Width/2-200,Height/2-200);
	glTexCoord2d(1,0);		glVertex2d(Width/2+200,Height/2-200);
	glTexCoord2d(1,1);		glVertex2d(Width/2+200,Height/2+200);
	glTexCoord2d(0,1);		glVertex2d(Width/2-200,Height/2+200);
glEnd();

I am to the point where i am thinking to my self “Should I just forget about openGL and start learning DirectX insted?” I mean it semes like if its not one thing it another.

If the demo of that class (from the same page you originally got the class) runs fine, then I would tend to think your app is using Microsoft’s software OpenGL implementation. Check the vendor string. If it says Microsoft, then you aren’t using the hardware accelerated OpenGL implementation.

when i call glGetString(GL_VENDOR)); it returns wiht somthing along the lines of “Nivia Corp.”, is that what you wanted me to check?

Yes, also, check the renderer string. Also ensure that you are in at least 16 bit color mode or higher.

I figured it out!!! :slight_smile:

i was geting good fps but it neaded a cast.

(I think its called a cast - when you do this - (float) - to convert it to somthing)