GL 1.1 raster pixels — 2026-11-02
glDrawPixels, glCopyPixels, glPixelZoom and glPixelStoref now have native stdcall implementations. The availability fixture removes exactly these four observed MDK2 rejections, leaving 60 mandatory misses. Original MDK2 was not run.
The contract references are the OpenGL 1.1 specification, sections 2.12, 3.6, 4.1–4.3 and 5.4. Draw captures unpacked client data at issue/compilation time; transfer, raster attributes and zoom apply at execution. Copies snapshot their complete source before drawing overlapping destinations. Signed zoom uses fragment-center coverage with bottom/left inclusion. Stencil writes use ownership, scissor and the stencil write mask, bypassing other fragment operations. PixelStoref rounds numeric parameters and converts Boolean parameters by zero/nonzero comparison.
The native capture validates all source rows before drawing, handles sparse guest memory, alignment, row length, skips, byte swapping and bitmap bit order, and owns display-list image payloads. Color, depth and stencil inputs use the supported scalar types; bitmap indices work for color-index input into an RGBA context and for stencil input. Zoom belongs to each context and PIXEL_MODE attribute state. Begin/End and invalid argument errors precede image access.
Color/depth fragments reuse the bitmap fragment path, including raster texture coordinates and fog distance. A conditional GL RGBA blender fixes alpha and destination-alpha factors in software GL spans; legacy D3D blending remains on its existing path. Software storage remains eight-bit color/stencil and sixteen-bit depth. WebGL1/2 consumers write stencil through masked, scissored clears and read the owned shared depth/stencil attachment through comparison probes with temporary color storage, restoring the affected state. Depth probes resolve the attachment to 24-bit precision. This is a synchronous correctness path and is more expensive than color copying.
No color-index framebuffer, logic-operation, selection/feedback, layer-context or other remaining unsupported export is claimed. Existing unsupported depth/stencil glReadPixels exports/format paths are not enabled by the private copy read barrier. Texture copy/readback and bitmap paths retain regression coverage.
Validation evidence is in gitignored scratch/runs/20261102-gl-raster-pixels-next/. Tests resolve actual guest imports and check stdcall stack/register preservation. Direct and real queued software runs each pass 92 literal checks: scalar color/depth/stencil conversion, maps and transfer, signed/fractional zoom, invalid raster positions, overlap, clipping, fragment operations, front/back selection, sparse input, rejected-call atomicity, context/attribute state and list capture/execution. WebGL1/2 tests cover attachment pixels, preserved state and actual stream consumers. Ten compiled semantic mutations fail their expected pixel/state oracles; the saved predecessor compiles and rejects the unavailable DrawPixels import. Focused regressions and flock /tmp/wine-build.lock bash tools/build.sh run on one finite-TTL test boat. Final evidence includes source hashes, logs, terminal results and recovery instructions.
Reproduce with node test/test-opengl-raster-pixels.js, the same command with --worker, and node test/test-opengl-raster-pixels-web.js using installed Chrome. No original game or browser download is required.