PDA

View Full Version : GLUI rotate and texture problem



fcoutel
10-31-2002, 05:02 AM
Hi!

I have the following problem: every time I click on the GLUI trackball to rotate the scene if I have textured my surface it becomes like a checked-board like the texture on the tracball itself, any ideas why?

Thanks for your help!

Relic
10-31-2002, 05:20 AM
Sounds like you don't bind your own texture before drawing your object and the one from the GLUI manipulator is still effective.

fcoutel
10-31-2002, 05:25 AM
Yes I do because the texture appears fine I can translate the scene etc it's just when I click on the trackball, it's like it's taking its texture instead. Very strange!

Any ideas how to cure this?

nexusone
10-31-2002, 08:05 AM
Are you applying the texture before you draw the object?



Originally posted by fcoutel:
Yes I do because the texture appears fine I can translate the scene etc it's just when I click on the trackball, it's like it's taking its texture instead. Very strange!

Any ideas how to cure this?

fcoutel
11-01-2002, 12:11 AM
Yes I did. If I had not then the texture would not appear at all right?

glNewList(terrainDL,GL_COMPILE);
glEnable(GL_TEXTURE_2D);

// Bind the terrain texture to our terrain
glBindTexture(GL_TEXTURE_2D,teximage->texID );


drawterrain();

glDisable(GL_TEXTURE_2D);

glEndList();