Currently Chrome uses one global RealGLApi object holding all entry points and filtered extensions, initialized when the first GL context is created. This causes problems if Chrome creates more than one context with different versions or extensions exposed, functionality will either be hidden or used when it is not available. This issue currently manifests with the Passthrough command buffer which creates webgl compatibility contexts but cannot detect that they are enabled.
In the future, this will only get worse if we attempt to create an ES2 or ES3 context based on what was requested.
Refactor the gl bindings:
* All entry points are loaded without extension or version checks when the first context is created.
* When a new context is created, create a new GLApi object and assign entry points to it based on the native context's extensions.
* Store the GLApi object in GLContext and set it when MakeCurrent is called.
Comment 1 by bugdroid1@chromium.org
, Jan 13 2017