   How to clear bleeding edge of texture atlases?
  I've read several articles on texture atlases, but I could not find any other topics posted here that related to the subject so I'm posting my code.I created a 1024x1024 texture with 16 subtextures in it, each 256x256 for Ogre terrain.Disabling mipmaps.In the vertex shader I take the incoming uv coordinate and multiply it by 500. This puts it in the upper left corner of the image. So here's the vertex shader:void main(){...oUV.xy = uv.xy * 500;...}And here's the fragment shader for sampling the subtexture in the upper left of the image.void main(){...uv = mod(uv, 0.25);uv.x = clamp(uv.x, 0.0, 0.24903);uv.y = clamp(uv.y, 0.0, 0.24903);vec4 color = texture2D(texture, uv);...}I found that this is useless for clearing bleeding edge.I think that It seems to corrected only adding "VertexData" in OgreTerrain when clear bleeding edge?Or is a way changing fragment shader?Any idea?thx.
  I spent weeks fiddling and tweaking texture atlases in order to tile a terrain and gave up after not finding a suitable solution (this was after a huge amount of research).  My suggestion would be to try a different approach.  There are lots of threads on gamedev.net relating to texture bleeding on atlases (some of them mine I would imagine), so have a read through to get an idea of the inherent problems.If I were you, and also based on the code you supplied on your initial attempt, I'd forget terrain tiling with texture atlases and try something else (unless you're using DX10 in which case you can use texture arrays, or 3d textures).  I'm not familiar with OpenGL if that's what you're using.   ;  IIRC, you have to offset (more or less ??) a little your texture coordinates.   ;  I'm sorry for replying later.thank a ton for RobMaddison.Your Suggestion let me save time.   