KhronosGroup / KhronosGroup/WebGL
Slimmed down WEBGL_debug with just object labels and debug groups
- Dominant language
- HTML
- Stars
- 2.9k
- Forks
- 703
- Avg merge
- 2d 9h
- Merged PRs (30d)
- 4
Description
The WEBGL_debug extension exists, however it is not supported among any implementors right now. I have heard through conversation that this is because the debug message infrastructure is relatively painful to support.
In my experience with debugging a lot of WebGL projects, the message infrastructure is not important for my use case.
Maybe it makes sense to spec a version of WEBGL_debug with only these endpoints:
* `pushDebugGroupKHR(DOMString name)`
* `popDebugGroup()`
* `objectLabelKHR(WebGLObject? object, DOMString label)`
* Optional: `getObjectLabelKHR(WebGLObject? object)` (this is easy enough to stash on the application side)
What I would really want is for these debug groups and labels to be passed through to the underlying API. Currently, the most effective technique for debugging WebGL is to use a native API debugger (e.g. RenderDoc), and try to correlate the GL commands to the frame in some other way.
Also: this also isn't in the current version of WEBGL_debug, but another big bonus would be some ability to turn on "debug" shader support, e.g. running fxc.exe with `/Od /Zi`. This will put the shader text and debuginfo inside the generated DXBC, which helps a lot when doing detailed shader debugging.
Contributor guide
Research direction
Start by reading the current WEBGL_debug extension specification and compare it with the proposed pushDebugGroupKHR, popDebugGroup, objectLabelKHR, and optional getObjectLabelKHR endpoints. Review whether implementors can pass labels and groups through to native debugging APIs; the work is done when the reduced extension scope and any shader-debug support are specified and accepted.
Written by the indexing model from the issue text.
Assessment
- Domain
- api, computer-graphics, web-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100