Open rreusser opened 4 years ago
I'll take a shot at it
@mikolalysenko I think it's almost entirely a non-issue since reusing a canvas element for different webgl contexts is a bit of a strange thing to do, though it's maybe not invalid. The place where it jumped out was in the test scripts, which almost exclusively do that. See:
I discovered while debugging strange test interactions in #474 that regl may perform incorrectly in the somewhat obscure corner case in which you:
ANGLE_instanced_arrays
extensionANGLE_instanced_arrays
The second regl instance knows nothing about the extension since you did not ask for it but still is subject to needing to maintain (or at least just unset) instanced rendering for the attributes.
This is pretty obscure and unlikely to cause real-world problems, but perhaps regl should query and register previously loaded extensions as available even if you did not ask for them.