mirror of
https://github.com/bkaradzic/bgfx.git
synced 2026-02-19 21:42:59 +01:00
GL: Implemented setName.
This commit is contained in:
@@ -2984,7 +2984,20 @@ namespace bgfx { namespace gl
|
||||
|
||||
virtual void setName(Handle _handle, const char* _name) override
|
||||
{
|
||||
BX_UNUSED(_handle, _name)
|
||||
switch (_handle.type)
|
||||
{
|
||||
case Handle::Shader:
|
||||
GL_CHECK(glObjectLabel(GL_SHADER, m_shaders[_handle.idx].m_id, -1, _name) );
|
||||
break;
|
||||
|
||||
case Handle::Texture:
|
||||
GL_CHECK(glObjectLabel(GL_TEXTURE, m_textures[_handle.idx].m_id, -1, _name) );
|
||||
break;
|
||||
|
||||
default:
|
||||
BX_CHECK(false, "Invalid handle type?! %d", _handle.type);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void submitBlit(BlitState& _bs, uint16_t _view);
|
||||
|
||||
Reference in New Issue
Block a user