PDA

View Full Version : how can i put texture on several objects?...



Kondrat
03-14-2001, 12:04 PM
Why it is't work?

glBegin(GL_QUADS);
glTexCoord2d(0,0); glVertex3d(-10,1,-10);
glTexCoord2d(0,1/2); glVertex3d(-10,1,0);
glTexCoord2d(1/2,1/2); glVertex3d(0,1,0);
glTexCoord2d(1/2,0); glVertex3d(0,1,-10);

glTexCoord2d(0,1/2); glVertex3d(-10,1,0);
glTexCoord2d(0,1); glVertex3d(-10,1,10);
glTexCoord2d(1/2,1); glVertex3d(0,1,10);
glTexCoord2d(1/2,1/2); glVertex3d(0,1,0);

glTexCoord2d(1/2,1/2); glVertex3d(0,1,0);
glTexCoord2d(1/2,1); glVertex3d(0,1,10);
glTexCoord2d(1,1); glVertex3d(10,1,10);
glTexCoord2d(1,1/2); glVertex3d(10,1,0);

glTexCoord2d(0,1/2); glVertex3d(0,1,-10);
glTexCoord2d(1/2,1/2); glVertex3d(0,1,0);
glTexCoord2d(1/2,1); glVertex3d(10,1,0);
glTexCoord2d(0,1); glVertex3d(10,1,-10);
glEnd();

Fredy
03-14-2001, 12:12 PM
Are u using glBindTex?

Kondrat
03-15-2001, 12:27 AM
Originally posted by Fredy:
Are u using glBindTex?

Yes, i see full texture only on the last square,another three are empty. Why?...