deathcap/voxel-texture-shader — pull request #1 by deathcap (2014-01-19 20:41:56+00:00)
Title: Manual mipmaps instead of tilepad

From http://0fps.wordpress.com/2013/07/09/texture-atlases-wrapping-and-mip-mapping/

> Using an automatic mipmap generator like glGenerateMipmaps will cause blurring across texture atlas boundaries, creating visible texture seams at a distance.

> …

> At least the first of these problems is pretty easy to solve. The simple fix is that instead of generating a mipmap for all the tiles simultaneously, we generate a mipmap for each tile independently using periodic boundary conditions and pack the result into a texture map. This can be done efficiently using sinc interpolation and an FFT (for an example of how this works, [check out this repository](https://github.com/mikolalysenko/ndarray-downsample2x)). Applying this to each tile in the texture atlas separately prevents any accidental smearing across boundaries.

Ref https://github.com/deathcap/voxpopuli/issues/32 - instead adding tilepad reduced the distant seams, but also increased texture sizes in the atlas to quadruple. Using manual mipmaps where each tile is scaled individually may be a better fix, though with my initial per-tile scaling attempts (e853e12) it did not show any difference (seams still visible); would need further investigation