joshmarinacci / voxeljs-next

The next generation of Voxel JS
https://vr.josh.earth/voxeljs-next/examples/ecsy.html
BSD 3-Clause "New" or "Revised" License
147 stars 20 forks source link

create a new texture manager api #26

Open joshmarinacci opened 5 years ago

joshmarinacci commented 5 years ago

currently it's not clear how textures are loaded and how they are mapped onto blocks. we need a new api.

joshmarinacci commented 5 years ago

this new api should let you

drBenway commented 5 years ago

Hi Josh, I was looking at your code and noticed this issue. Would it be beneficial for speed if textures are grouped in sprite sheets and injected in the code(build) via base64 encoding? If you then serve your code via gzipped file I guess the download would be faster.

joshmarinacci commented 5 years ago

Yep. It definitely should support loading tile textures from a spritesheet. I don't know if base64 encoding would help, though. PNG is pretty compact already.