Question about glDeleteBuffer unbinding rules

Greetings,

if a buffer is deleted, it is automatically unbound from the active vao, right? Does a similar rule exist for index buffers and default vao 0 ?

regards

Right. But attachments to unbound objects aren’t affected. So if it’s bound to other VAOs, those bindings remain.

Buffers are buffers. They don’t have types.

The core profile doesn’t have a VAO 0. In the compatibility profile, VAO 0 can’t be deleted. glDeleteVertexArrays silently ignores unused names and the value zero. Automatic unbinding only applies to buffers, textures and renderbuffers; deleting a VAO doesn’t unbind it.

What I meant is if there is any rule where deleted buffers are automatically unbound from VAO 0.

Deleted buffers are unbound from the active (bound) VAO. If VAO 0 exists and is bound, then deleted buffers are unbound from it. If VAO 0 isn’t bound, then deleted buffers won’t be unbound from it.

That’s what I meant thank you-