|
|
@@ -445,18 +445,6 @@ rebuild_bitplanes() {
|
|
|
if (_fbo[layer] == 0) {
|
|
|
glgsg->_glGenFramebuffers(1, &_fbo[layer]);
|
|
|
|
|
|
-#ifndef OPENGLES
|
|
|
- if (glgsg->_use_object_labels) {
|
|
|
- if (num_fbos > 1) {
|
|
|
- GLchar name[128];
|
|
|
- GLsizei len = snprintf(name, 128, "%s[%d]", _name.c_str(), layer);
|
|
|
- glgsg->_glObjectLabel(GL_FRAMEBUFFER, _fbo[layer], len, name);
|
|
|
- } else {
|
|
|
- glgsg->_glObjectLabel(GL_FRAMEBUFFER, _fbo[layer], _name.size(), _name.data());
|
|
|
- }
|
|
|
- }
|
|
|
-#endif
|
|
|
-
|
|
|
if (_fbo[layer] == 0) {
|
|
|
report_my_gl_errors();
|
|
|
return;
|
|
|
@@ -464,6 +452,19 @@ rebuild_bitplanes() {
|
|
|
}
|
|
|
glgsg->bind_fbo(_fbo[layer]);
|
|
|
|
|
|
+#ifndef OPENGLES
|
|
|
+ if (glgsg->_use_object_labels) {
|
|
|
+ // Assign a label for OpenGL to use when displaying debug messages.
|
|
|
+ if (num_fbos > 1) {
|
|
|
+ GLchar name[128];
|
|
|
+ GLsizei len = snprintf(name, 128, "%s[%d]", _name.c_str(), layer);
|
|
|
+ glgsg->_glObjectLabel(GL_FRAMEBUFFER, _fbo[layer], len, name);
|
|
|
+ } else {
|
|
|
+ glgsg->_glObjectLabel(GL_FRAMEBUFFER, _fbo[layer], _name.size(), _name.data());
|
|
|
+ }
|
|
|
+ }
|
|
|
+#endif
|
|
|
+
|
|
|
// For all slots, update the slot.
|
|
|
if (_use_depth_stencil) {
|
|
|
bind_slot(layer, rb_resize, attach, RTP_depth_stencil, GL_DEPTH_ATTACHMENT_EXT);
|