Hi all, I have 3 questions.
1- I want to map a texture only to the inside of a cylinder? how do I?
2- And I want to move and fix my camera to center of the cylinder both horizontally and vertically!(I have already rotated the cylinder -90 degrees so now it is standing:D)? how should I?
Thanks,
I’m totally new to OpenGL and do not understand what you mean, what do I want is a cylinder aligned to Y-axis(standing)[I think I’ve done it correctly]:
glRotatef(-90.0, 1.0, 0.0, 0.0); // make cylinder stand up
gluCylinder(pObj, 5.0, 5.0, 4.0, 128, 64);
Then I want to place my camera in the center of it. And look at the texture that has just been mapped to the inside of my cylinder.
In the 3rd question I want to know that is there any relation with the number of stacks and slices and the quality of mapped texture?