aorecomp

Anarchy Online classic in the browser

git clone https://aorecomp.ubeagle.com/code/aorecomp.git


commit 7dd896f308b191861f58ad499e2a2e0e108a0607
parent 86ef32e79653bdb8af707af9cbe25de24085abfb
Author: anon <anon@example.com>
Date:   Tue, 13 Oct 2026 08:47:53 +0000

Present windowed primary surfaces and translate BBR dirty rectangle callback

Diffstat:
Mdocs/browser-porting.md | 11+++++++++++
1 file changed, 11 insertions(+), 0 deletions(-)

diff --git a/docs/browser-porting.md b/docs/browser-porting.md @@ -911,6 +911,17 @@ See [DirectDraw7 Lock](https://learn.microsoft.com/en-us/windows/win32/api/ddraw [Unlock](https://learn.microsoft.com/en-us/windows/win32/api/ddraw/nf-ddraw-idirectdrawsurface7-unlock) and the compatible descriptor behavior in [Wine surface_lock](https://github.com/wine-mirror/wine/blob/master/dlls/ddraw/surface.c). +BBR RVA `0x3e90` is another indirect display method: a thiscall routine with +no stack arguments that obtains Randy's back buffer and restores queued +dirty rectangles from a saved surface through Surface7 Blt, slot 5, +with DDBLT_WAIT (`0x1000000`). It then advances the rectangle queue and clears +the next entry. This behavior is observed in the pinned function's assembly +and decompilation (REA evidence +`ev_c01344caef95bd6c77f03cef6d9b2c4e940049b029a87c223f271ac71a4a1a3b`). +The windowed renderer copies its separate back buffer into the primary surface +with Blt. Presentation must therefore work when the primary surface has no +attached flip buffer; an attachment-only presentation path silently drops +these frames. The browser bridge renders in a worker-owned WebGL2 OffscreenCanvas. D3D row vector matrices upload as transposes; clip depth 0..w becomes -w..w. Readback