FrameDraw help...
Moderator: InsideQC Admins
1 post
• Page 1 of 1
FrameDraw help...
Hey guys i will add an frameDraw to my quake here my code bit:

Thats the image i will use as texture where to take each frame like:
# # #
# # #
# # #
- Code: Select all
void Draw_FramePic (int n, int x, int y, int w, int h, int posx, int posy) {
float coordx = (float)posx, coordy = (float)posy;
glBindTexture (GL_TEXTURE_2D, texture[n]);
glBegin (GL_QUADS);
glTexCoord2f (coordx, coordy);
glVertex2f (x + posx, y + posy);
glTexCoord2f (0.5, coordy);
glVertex2f (x + w + posx, y + posy);
glTexCoord2f (0.5, 0.5);
glVertex2f (x + w + posx, y + h + posy);
glTexCoord2f (coordx, 0.5);
glVertex2f (x, y + h + posy);
glEnd();
}

Thats the image i will use as texture where to take each frame like:
# # #
# # #
# # #
I am sorry for my English...
-

Rikku2000 - Posts: 49
- Joined: Wed Oct 20, 2010 6:33 pm
- Location: Germany
1 post
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 1 guest