Fixed texture info.

This commit is contained in:
Branimir Karadžić 2015-02-02 20:42:59 -08:00
parent 8942628ec1
commit f0f0d08417

View file

@ -2318,11 +2318,14 @@ again:
const uint32_t minBlockX = blockInfo.minBlockX; const uint32_t minBlockX = blockInfo.minBlockX;
const uint32_t minBlockY = blockInfo.minBlockY; const uint32_t minBlockY = blockInfo.minBlockY;
_width = bx::uint32_max(blockWidth * minBlockX, ( (_width + blockWidth - 1) / blockWidth)*blockWidth);
_height = bx::uint32_max(blockHeight * minBlockY, ( (_height + blockHeight - 1) / blockHeight)*blockHeight);
_depth = bx::uint32_max(1, _depth);
_numMips = bx::uint32_max(1, _numMips); _numMips = bx::uint32_max(1, _numMips);
uint32_t width = bx::uint32_max(1, _width); uint32_t width = _width;
uint32_t height = bx::uint32_max(1, _height); uint32_t height = _height;
uint32_t depth = bx::uint32_max(1, _depth); uint32_t depth = _depth;
uint32_t size = 0; uint32_t size = 0;
for (uint32_t lod = 0; lod < _numMips; ++lod) for (uint32_t lod = 0; lod < _numMips; ++lod)