OpenGL Programming Guide: The Official Guide to Learning OpenGL, Version 4.3, Eighth Edition
by Dave Shreiner, Graham Sellers, John M. Kessenich, Bill M. Licea-Kane
Naming Objects
When OpenGL generates debugging messages, it will sometimes make reference to objects such as textures, buffers, or framebuffers. In a complex application, there may be hundreds or thousands of textures and buffers in existence at any given time. Each of these objects has a unique identifier that was assigned by OpenGL’s glGenTextures(), glGenBuffers(), or other name-generation functions and those names may have no bearing on what the application intends to use them for. It is possible to name the objects by giving them labels. If you give an object a label, then when a reference to it appears in a debug message, OpenGL will use the object’s label rather than (or as well as) its number. To give an object a label, use glObjectLabel() ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access