if (tc2 == null) throw new IllegalArgumentException("Texture coordinate for triangle must not be null");
Vector2f tc3 = t.getTextureCoordinate(2);
if (tc3 == null) throw new IllegalArgumentException("Texture coordinate for triangle must not be null");
p = t.getPoint(0);
float texX = coords.left() + (coords.right() - coords.left()) / joglImage.texture.getImageWidth() * tc1.x;
float texY = coords.top() + (coords.bottom() - coords.top()) / joglImage.texture.getImageHeight() * tc1.y;
gl.glTexCoord2f(texX, texY);
gl.glVertex2f(p.x, p.y);
p = t.getPoint(1);