emscripten-core/emscripten

missing informative way of extracting WebGL context creation failures

开放

#12,355 创建于 2020年9月28日

 (3 条评论) (1 个反应) (0 位负责人)C++ (3,519 个派生)batch import
help wantedwontfix

仓库指标

星标
 (27,361 个星标)
PR 合并指标
 (平均合并 19天 10小时) (30 天内合并 147 个 PR)

描述

as discussed here, today the only information that emscripten returns about WebGL context creation failures appears in logs, if the GL_DEBUG or ASSERTIONS flags are set during the build process. There's no programatic way of receiving the source of failure in GL.createContext or emscripten_webgl_create_context, which means that these failures can't be handled in real time, and any logs must be extracted from the console - both of which are problematic when shipping code for production. Something like the proposed emscripten_webgl_create_context_ex should be created, preferably with the ability to extract error information from also from the internal call to GL.createContext.

贡献者指南