LWJGL GL_QUADS texture artifact

Posted by Dajgoro Labinac on Game Development See other posts from Game Development or by Dajgoro Labinac
Published on 2012-08-28T01:45:10Z Indexed on 2012/08/28 3:53 UTC
Read the original article Hit count: 220

Filed under:
|

I managed to get working lwjgl in Java, and i loaded a test image(tv test card), but i keep getting weird artifacts outside the image.

Image link: http://tinypic.com/r/vhv9g/6

Code:

glBegin(GL_QUADS);

glTexCoord2f(0, 0);

glVertex2i(10, 10);

glTexCoord2f(1, 0);

glVertex2i(500, 10);

glTexCoord2f(1, 1);

glVertex2i(500, 500);

glTexCoord2f(0, 1);

glVertex2i(10, 500);

glEnd();

What could be the cause?

© Game Development or respective owner

Related posts about java

Related posts about lwjgl