Closed jjhembd closed 2 years ago
The problem keys are drawingBufferColorSpace
and unpackColorSpace
. Skipping these keys in the switch
statement mostly fixes the WebGL 2 example.
switch (key) {
case 'canvas':
case 'drawingBufferWidth':
case 'drawingBufferHeight':
case 'drawingBufferColorSpace':
case 'unpackColorSpace':
break;
default: {
let value;
try {
value = WebGL2RenderingContext.prototype[key];
} catch {
throw("Couldn't get context key " + key);
}
The "Instanced Drawing & Vertex Array" pane is still not working, perhaps because of another Illegal invocation
error in twgl related to extensions.
thanks for the bug report!
Updated
https://github.com/greggman/virtual-webgl/commit/66cf2b58e58ccb94963f1fb06e96290363528d62
In Chrome on Windows, I get "Illegal invocation" errors, mostly at this line:
It's enough to break the WebGL 2 examples.