Video platform service (SNES backend): commands for PPU registers, VRAM/CGRAM/OAM uploads, HDMA tables #33
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Brief §5 (platform services, "commands, not diffs") and §7.4 (no PPU/DMA register number in core/game). Needed before porting field routines that write PPU registers or start DMA (TfrObjGfxSub, InitMaskHDMAData, UpdateScrollHDMA, UpdateFixedColor, TfrBGAnimGfx, SetTopSpriteMSB...).
core/platform/video.h: operations named for what they do (upload tiles/tilemap/palette/OAM, set scroll, layer/window/colour-math state, HDMA channel tables, brightness/forced blank), game-facing types.core/hw/: performs exactly the register writes and DMA transfers the original does (same order and values), so per-call shadow keeps comparing VRAM/CGRAM/OAM/PPU registers byte for byte.Starting now (branch
video-service), after #32. Order: platform video API, SNES backend reproducing the exact writes, shadow extended to PPU/DMA state, one hardware-touching field leaf as proof.Done in PR (merged). Evidence (release build, routes = the five committed movies, all ports in shadow):
field/UpdateBrightness,field/TfrPal,field/TfrSprites: shadow 0 mismatch, 0 skipped, 0 fallback; US 74 738 calls each, JP 68 636 each. The shadow now also compares PPU and DMA channel registers for these ports.DMA channel 0 indirect byte 0: 01/00; an undeclared PPU write is reported aswrites PPU registers not declared PORT_WRITES_PPU.0649296): the style record covers every per-module choice, undeclared hardware writes and unreachable upload sources are reported, video contracts moved to the header; plus casts, thefield_base_palettesrename and the JP check on rSpritesHi.