GL: Wrap extension support inside GLContext

This makes it possible to disable all the extensions when forcing
workarounds.

Also it will allow future options to selectively disable each extension
to know which one is buggy.
This commit is contained in:
2020-09-10 14:18:19 +02:00
parent 9d5977f5e1
commit 8d59f060ca
8 changed files with 76 additions and 44 deletions

View File

@@ -307,7 +307,7 @@ void GLBatch::bind(int i_first)
#if GPU_TRACK_INDEX_RANGE
/* Can be removed if GL 4.3 is required. */
if (!GLEW_ARB_ES3_compatibility && (elem != NULL)) {
if (!GLContext::fixed_restart_index_support && (elem != NULL)) {
glPrimitiveRestartIndex(this->elem_()->restart_index());
}
#endif