2.2 KiB
2.2 KiB
| id | ticket | title | status | created | ref_decisions | tags | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| PLN-0079 | render-frame-packet-boundary | Gfx2D Primitive Domain | open | 2026-05-25 |
|
|
Briefing
Source decision: DEC-0030.
Replace primitive Game drawing paths with gfx2d.* command buffering while keeping gfx2d limited to primitives only.
Target
Game primitive drawing becomes a Game-mode ABI domain that records commands into a buffer consumed as part of Game 2D rendering.
Scope
- Add
gfx2d.*syscall domain and command buffer. - Migrate primitive Game drawing calls from old
gfx.*behavior togfx2d.*. - Ensure
gfx2dcontains primitives only. - Integrate
gfx2dcommands into the Game 2D packet/render path without taking ownership of scene, camera, sprites, HUD, or frame orchestration.
Out of Scope
- Shell UI primitive domain.
composer.*high-level Game state.- Widget/layout policy.
- Compatibility with old primitive
gfx.*ABI names.
Execution Sequence
- Inventory old primitive
gfx.*syscalls and direct drawing callsites used by Game mode. - Define the
gfx2d.*command enum and mutable command buffer. - Route Game primitive syscalls into the buffer.
- Add app-mode and capability enforcement for Game-only access.
- Integrate buffered primitives into Game 2D packet closure or renderer consumption at the DEC-0030-approved layer.
- Remove or retire old primitive
gfx.*ABI registrations.
Acceptance Criteria
- Game primitive commands are buffered as
gfx2d.*. gfx2ddoes not own scene, camera, sprites, HUD, or frame orchestration.- Shell mode cannot call
gfx2d.*. - No logical primitive path directly mutates framebuffer during production.
Tests / Validation
- Add syscall tests for each migrated primitive.
- Add command buffer ordering tests.
- Add capability rejection tests for Shell mode.
- Run pixel-equivalence tests for unchanged primitive output.
Risks
- The old
gfxnaming may appear in PBS wrappers; distinguish author API names from ABI domain names. - Primitive ordering relative to composer output must be explicit.
Affected Artifacts
- Syscall registry and runtime render domain modules under
crates/ - Game primitive tests