deathcap / voxel-texture-shader

custom shader for texturing voxels in voxeljs (for three.js-based voxel-engine, no longer needed with voxel-engine-stackgl)
MIT License
8 stars 1 forks source link

Multiple texture atlases? (≈ infinite tiles) #2

Open deathcap opened 10 years ago

deathcap commented 10 years ago

The default atlas size of 512x512 with fourtap 2x repeat + tilepad (=4x4) and 16x16 tiles can fit up to (512/(16*4))^2=64 texture tiles. Atlas size can be increased up to supported GPU texture size limits (2048x2048 is supported by 100% of WebGL users according to http://webglstats.com/), but still is finite. Maybe it would be worthwhile to create another texture atlas if the current one overflows, supporting potentially infinite texture tiles? (within system memory limits, etc.)

deathcap commented 10 years ago

For what its worth, ThinkMap (Java GWT WebGL renderer) just added support for up to 10 texture atlases in: https://github.com/thinkofdeath/ThinkMap/commit/1a2b3b342c929d4de517271bbf2f964ab41f8b25