A packed cubemap will be a single giant image packing all faces within. The orientation is the same as the image above, that is, 3x4 (3 rows of 4 columns) grid. The leftmost image on middle row is the -X, the one in the middle is -Z, the right nearby is +X, the rightmost one is +Z, the one at top is +Y and the one at bottom is -Y.
Context
We can load textures (as Texture) but we lack a way to unify them into cubemaps. That is, we need a way to load a
Cubemap
that gathers six textures.Cubemaps
First we need to introduce a new type into
Core
. Something like this:Some cubemaps use the old and pretty stupid way to make cubemaps by wasting a lot of space, like this one:
I guess artists are used to that, so we need to support it as well. Then, the JSON should be something like this:
Or like this:
A packed cubemap will be a single giant image packing all faces within. The orientation is the same as the image above, that is, 3x4 (3 rows of 4 columns) grid. The leftmost image on middle row is the -X, the one in the middle is -Z, the right nearby is +X, the rightmost one is +Z, the one at top is +Y and the one at bottom is -Y.