Monday, September 9, 2013

[android help] opengl es 2.0 mysterious white lines at textures left side


opengl es 2.0 mysterious white lines at textures left side



I am working on an Android platformer game using opengl es 2.0. I created an "engine," or more like a frame that handles most of the opengl stuff. Similar to Unity, the game elements are game objects - there are components like animations, images, route finding etc.


The problem is that I draw out squares that represents the ground with red and another element with blue which is the player. I moved the squares up on y axis so you can see them. Each square is a simple flat built up from two triangles and each has a plain red texture using from a .png file.


You can view a screenshot here: http://www.themobius.hu/white_line.png


So the problem is that white line at the left side of the 6th square. If I move the player in any direction it disappears and appears for "random" other squares.


If I remove the textures and only color the squares than the lines disappear so it has to do something with the texture.


Tried other textures and for this exact float position it always appears.


Now the squares are overlapping each other but only to reproduce the error. If I place them perfectly it only happens when the float value accuracy makes them overlapping a bit.


The line is always white. I changed the background to a different color to be sure.


I haven't added any code here because there is lot of code involved and for now I assume that this is an common opengl engine problem and I don't know what it's called.



Read more

stackoverflow.comm



No comments:

Post a Comment

Google Voice on T-Mobile? [General]

Google Voice on T-Mobile? So I recently switched from a GNex on Verizon to a Moto X DE on T-Mobile. I had always used Google Voice for my v...