This commit is contained in:
Бранимир Караџић 2019-01-24 20:28:26 -08:00
parent 75bb36d0fb
commit 916d159965

View File

@ -3007,10 +3007,14 @@ BX_TRACE("%d, %d, %d, %s", _array, _srgb, _mipAutogen, getName(_format) );
case Handle::Texture:
{
GLint id = m_textures[_handle.idx].m_id;
if (0 != id /* write only texture */)
if (0 != id)
{
GL_CHECK(glObjectLabel(GL_TEXTURE, id, len, _name) );
}
else
{
GL_CHECK(glObjectLabel(GL_RENDERBUFFER, m_textures[_handle.idx].m_rbo, len, _name) );
}
}
break;