Hello,
opengl 4.5 was released recently with a very interesting extension Direct State Access (aka DSA). Basically this extension replaces the bind to edit (aka B2E) method with a direct access to the object.
I know that severals Dev didn't like B2E. Besides let's be honest DSA is better suited to object oriented code. I also guess that any future GL api will likely based on DSA. So it times to upgrade the codebase
I have already started to port the code to the new extension. But everything isn't perfect.
* DSA replaces lots of opengl function so I'm currently having ifdef all over the place (~50 ifdef). It doesn't help to make code readable and nice.
* Except Nvidia (beta driver), no one support yet DSA. Catalyst can take its time to support it (1 year). I hope Mesa will support it on next release (6 months) but nobody know.
* GLES3.1 doesn't support at all DSA. I hope dev will push for it, but hardware vendor will likely push against it (to keep driver as easy as possible).
I'm mitigate how to handle this situation
1/ keep the ifdef.
+ support everyone
- code readability
2/ Copy GSdx into a legacy gsdx-ogl for linux user. That will be dropped when the 3 drivers implement the extension
+ cleanest code
- drop GLES3.1 (of the future GSdx, legacy will stay for refence). Note situation could be temporary.
3/ Add compatibility layer to emulate the new function.
+ additional work...
- slow
+ clearner code but not yet perfect
Any opinion is welcome..
opengl 4.5 was released recently with a very interesting extension Direct State Access (aka DSA). Basically this extension replaces the bind to edit (aka B2E) method with a direct access to the object.
I know that severals Dev didn't like B2E. Besides let's be honest DSA is better suited to object oriented code. I also guess that any future GL api will likely based on DSA. So it times to upgrade the codebase
I have already started to port the code to the new extension. But everything isn't perfect.
* DSA replaces lots of opengl function so I'm currently having ifdef all over the place (~50 ifdef). It doesn't help to make code readable and nice.
* Except Nvidia (beta driver), no one support yet DSA. Catalyst can take its time to support it (1 year). I hope Mesa will support it on next release (6 months) but nobody know.
* GLES3.1 doesn't support at all DSA. I hope dev will push for it, but hardware vendor will likely push against it (to keep driver as easy as possible).
I'm mitigate how to handle this situation
1/ keep the ifdef.
+ support everyone
- code readability
2/ Copy GSdx into a legacy gsdx-ogl for linux user. That will be dropped when the 3 drivers implement the extension
+ cleanest code
- drop GLES3.1 (of the future GSdx, legacy will stay for refence). Note situation could be temporary.
3/ Add compatibility layer to emulate the new function.
+ additional work...
- slow
+ clearner code but not yet perfect
Any opinion is welcome..