Skip to content

feat(render): implement bitty-render crate skeleton (wgpu + crossfont wrapper) #18

Closed

Description

@Xuepoo

Implements the bitty-render crate skeleton per accepted ADR-0003 (crate graph row: render snapshots from damage, glyph cache, renderer abstraction, software fallback; dependency edge reserved for bitty-term-state snapshot wiring) and ADR-0004 (ADOPT wgpu ~25.x, WRAP crossfont, REJECT skia-safe).

CarryCtx task: CTX-0015 (team core-foundation).

Scope

  • New crate crates/bitty-render with fully owned public API; no wgpu/crossfont types escape.
  • Owned RenderError; upstream failures flattened to owned data.
  • GlyphRasterizer trait + CrossFontRasterizer wrapper returning owned GlyphBitmap.
  • Damage-aware frame-plan hook accepting a generic damage descriptor (real grid wiring lands in a later slice).
  • Glyph atlas math + bounded glyph cache as pure logic.
  • GPU context (instance/adapter/device/queue) behind owned error type; window-surface attachment deferred to the bitty-platform integration slice.
  • Headless-friendly: GPU-dependent integration tests gated behind BITTY_RENDER_GPU_TESTS=1; atlas math, rect/frame-plan algebra, and rasterizer trait contract (vs fake rasterizer) unit-tested in plain CI.
  • Software fallback seed (CPU alpha-blit of glyph bitmaps) behind a feature flag, documented.
  • Shaping/HarfBuzz OUT of scope (deferred to text RFC per ADR-0004).

Constraints

  • \#![forbid(unsafe_code)] unless wgpu/bytemuck forces exceptions; any exception documented precisely.
  • Manifest edits kept minimal (workspace members list only) for commander union-merge with CTX-0014.
  • Gates: fmt, clippy -D warnings, tests green locally; CI green before merge.

Acceptance

  • PR links this issue and CTX-0015; independent review + required CI pass.

Activity

  1. added a commit that references this issue on Aug 26, 2026
    23edbb4
  2. added
    feat
    area:package
    on Aug 29, 2026
  3. added this to the v0.0.1 milestone on Aug 29, 2026
  4. added
    area:render
    P0
    on Aug 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P0area:packagearea:renderfeat

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions