mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Add assertion in CGraphics_Threaded::LoadTextureRawSub
To check for invalid texture handle.
This commit is contained in:
parent
21bbc8be61
commit
b432feb9b0
|
@ -330,6 +330,8 @@ static bool ConvertToRGBA(uint8_t *pDest, const uint8_t *pSrc, size_t SrcWidth,
|
|||
|
||||
int CGraphics_Threaded::LoadTextureRawSub(CTextureHandle TextureID, int x, int y, int Width, int Height, int Format, const void *pData)
|
||||
{
|
||||
dbg_assert(TextureID.IsValid(), "Invalid texture handle used with LoadTextureRawSub.");
|
||||
|
||||
CCommandBuffer::SCommand_Texture_Update Cmd;
|
||||
Cmd.m_Slot = TextureID.Id();
|
||||
Cmd.m_X = x;
|
||||
|
|
Loading…
Reference in a new issue