stackgl / headless-gl

🎃 Windowless WebGL for node.js
1.73k stars 166 forks source link

Print something when `WebGLRenderingContext` fails #255

Open remorses opened 1 year ago

remorses commented 1 year ago

gl currently silently returns null if WebGLRenderingContext fails (i assume because of missing dynamic libraries or undefined symbols)

Why not print the error in the console? debugging is very difficult this way

https://github.com/stackgl/headless-gl/blob/f1ed92fef1688bd9e9b8206516d1083a186f7ce3/src/javascript/node-index.js#L38-L53