mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-11-25 00:58:30 -05:00
Added texture size check.
This commit is contained in:
parent
0c78fe8073
commit
d58d62401e
1 changed files with 1 additions and 0 deletions
|
@ -2508,6 +2508,7 @@ again:
|
|||
|
||||
TextureHandle createTexture2D(uint16_t _width, uint16_t _height, uint8_t _numMips, TextureFormat::Enum _format, uint32_t _flags, const Memory* _mem)
|
||||
{
|
||||
BX_CHECK(_width > 0 && _height > 0, "Invalid texture size (width %d, height %d).", _width, _height);
|
||||
return createTexture2D(BackbufferRatio::Count, _width, _height, _numMips, _format, _flags, _mem);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue