- The texture loader you use makes the resulting texture dimensions a power of two.
- The lines are due to filtering. The standard wrap setting is GL_REPEAT which means that if you were to send in a texture coordinate that is higher than 1.0 or lower than 0.0 then it would simply repeat the texture multiple times over the triangle. This combined with linear filtering causes the right edge to possible get mixed together with the left edge even if you have texture coordinates that are NOT over 1.0 or under 0.0 due to bilinear filtering catching the closest 4 texture samples and mixing them. In your case simply changing the wrap mode to GL_CLAMP_TO_EDGE (in GL12) which is a special wrap mode that disallows any wrapping between the texture edges.
You're using a non power of two texture, which isn't supported by opengl like you are using it.
Wrong since 2003. Support for NPOT textures is even integrated in core in OpenGL 2.0.
Just use textures which are power of two sizes is the simplest solution. A bit more fiddling is needed to support non power of two textures but it is possible.
No fiddling at all if you do manual loading. Just don't calculate power of two dimensions and supply the data just like normal to glTex2D. Where's the fiddling? Okay, you do have to keep your dimension sizes to multiples of 4 unless you write a single line to change unpack alignment to 1. -_- This also saves memory.