Status
MacSurf has an existing webgl/SCOPE.md research plan, status pre-Stage 0, for a software WebGL 1.0 implementation. The old umbrella #130 incorrectly grouped WebGL under a permanent won't-fix decision; that no longer reflects the project's documented direction.
Goal
Make canvas.getContext('webgl') return a real context capable of compiling/linking GLSL ES 1.00 and drawing a hardware-verified hello triangle on Classic Mac OS. Performance beyond proof-of-life is secondary.
Architecture baseline
The scope document proposes:
- canvas-backed offscreen bitmap/GWorld
- WebGL state machine in C
- GLSL ES lexer/parser/type checker
- software vertex/fragment execution (AST walker first, bytecode later)
- software triangle rasterization and page compositing through the existing bitmap plotter
OS 9 OpenGL is fixed-function and cannot execute WebGL shaders, so programmable shader execution must be software-first.
Staging
Treat webgl/SCOPE.md as the detailed research seed, but re-audit it for the current QuickJS architecture before implementation because it predates the Duktape → QuickJS migration.
Acceptance — first meaningful milestone
<canvas> can acquire a WebGL context.
- Typed-array inputs marshal correctly from QuickJS.
- Minimal vertex + fragment shaders compile/link.
drawArrays(TRIANGLES, ...) produces the expected pixels.
- Result is visible in normal page paint on the G3.
- C89/CodeWarrior compatibility and bounded memory limits are documented.
Related: #109 Canvas 2D; historical umbrella #130.
Status
MacSurf has an existing
webgl/SCOPE.mdresearch plan, status pre-Stage 0, for a software WebGL 1.0 implementation. The old umbrella #130 incorrectly grouped WebGL under a permanent won't-fix decision; that no longer reflects the project's documented direction.Goal
Make
canvas.getContext('webgl')return a real context capable of compiling/linking GLSL ES 1.00 and drawing a hardware-verified hello triangle on Classic Mac OS. Performance beyond proof-of-life is secondary.Architecture baseline
The scope document proposes:
OS 9 OpenGL is fixed-function and cannot execute WebGL shaders, so programmable shader execution must be software-first.
Staging
Treat
webgl/SCOPE.mdas the detailed research seed, but re-audit it for the current QuickJS architecture before implementation because it predates the Duktape → QuickJS migration.Acceptance — first meaningful milestone
<canvas>can acquire a WebGL context.drawArrays(TRIANGLES, ...)produces the expected pixels.Related: #109 Canvas 2D; historical umbrella #130.