adamdruppe / arsd

This is a collection of modules that I've released over the years. Most of them stand alone, or have just one or two dependencies in here, so you don't have to download this whole repo.
http://arsd-official.dpldocs.info/arsd.html
530 stars 125 forks source link

fix nanovega tainting the active VAO #419

Closed WebFreak001 closed 5 months ago

WebFreak001 commented 5 months ago

this is both needed for modern opengl because if you are unlucky with your graphics drivers there it won't render anything when the core context is enabled, but also when rendering custom data and having stray VAOs open that you didn't unbind on the start of the nanovega render calls.

stuff like glEnableVertexAttribArray and glVertexAttribPointer, which is called below, is only valid with a VAO bound, which wasn't the case before and was just lucky that it worked at all.

adamdruppe commented 5 months ago

looks like no breakage and ketmar said it looks good enough but warned if you don't manage the arrays right it can be a performance degradation, so we might need to revisit that at some point, but still thx let's merge.