siniarskimar / zglgen

OpenGL bindings generator written in Zig
zlib License
2 stars 1 forks source link

Iterate on and improve zglgen #37

Open siniarskimar opened 1 month ago

siniarskimar commented 1 month ago

Since zglgen somewhat works now, it's time to clean up the mess. There are multiple problems I would like to address:

  1. Loading multiple GL versions is possible but the dispatch table will hold all of function pointers to the latest generated version. This is not particullary great, as it's possible to invoke a call to a function that is not loaded and it's wastefull usage of bytes.

  2. The preffered method of checking for extension support changed since OpenGL Core. This makes it tricky to check and load extensions across all generated versions.

  3. loadGLXX is clunky, it would be much better to specify a version or a feature as a parameter

  4. Generation depends on creating temporary XmlTree's. It's possible to get rid of them, speed up registry load times and enforce registry schema.

siniarskimar commented 1 month ago

In the mean time I've created https://github.com/siniarskimar/zxml and would like to use it here but that requires siniarskimar/zxml#3