diff --git a/include/renderer_gl/surfaces.hpp b/include/renderer_gl/surfaces.hpp index 88355a8c..043c63d0 100644 --- a/include/renderer_gl/surfaces.hpp +++ b/include/renderer_gl/surfaces.hpp @@ -65,8 +65,10 @@ struct ColourBuffer { texture.setMagFilter(OpenGL::Linear); glBindTexture(GL_TEXTURE_2D, prevTexture); +#ifdef GPU_DEBUG_INFO const auto name = Helpers::format("Surface %dx%d %s from 0x%08X", size.x(), size.y(), PICA::textureFormatToString(format), location); OpenGL::setObjectLabel(GL_TEXTURE, texture.handle(), name.c_str()); +#endif fbo.createWithDrawTexture(texture); fbo.bind(OpenGL::DrawAndReadFramebuffer); diff --git a/src/core/renderer_gl/textures.cpp b/src/core/renderer_gl/textures.cpp index 7a03c97d..7f4c31bf 100644 --- a/src/core/renderer_gl/textures.cpp +++ b/src/core/renderer_gl/textures.cpp @@ -9,8 +9,10 @@ void Texture::allocate() { texture.create(size.u(), size.v(), GL_RGBA8); texture.bind(); +#ifdef GPU_DEBUG_INFO const auto name = Helpers::format("Surface %dx%d %s from 0x%08X", size.x(), size.y(), PICA::textureFormatToString(format), location); OpenGL::setObjectLabel(GL_TEXTURE, texture.handle(), name.c_str()); +#endif setNewConfig(config); }