Hello, i wanted to create a billard-ball with a texture,
thats the code:
GLUquadricObj* quadric;
sf::Image img;
img.LoadFromFile("10ball.jpg");
img.Bind();
while (App.IsOpened())
{
// Process events
sf::Event Event;
while (App.GetEvent(Event))
{
}
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
quadric = gluNewQuadric();
//gluQuadricNormals(quadric, GLU_SMOOTH);
gluQuadricTexture(quadric, GL_TRUE);
gluSphere(quadric, 30.0, 1000, 500);
App.Display();
}
but i can see the border of the texture.
Someone told me that cube-mapping might help.
I didnt really find out how i could do this, can someone help me?
It seems that Bind() decides the way it is mapped, what is standard and how can i change it?