Skip to content

Implement versioned resource providers and revisioned GPU caches #6

Description

@zoeyrose

Outcome

Load, validate, upload, cache, and invalidate graphics/font/material resources from packaged, authenticated client, editor-local, and test sources without giving renderer filesystem/network ownership.

Scope and invariants

  • Define stable resource IDs, content digests, revisions, type/size/dimension/format limits, dependencies, and missing/error diagnostics.
  • Providers supply verified immutable bytes/decoded CPU assets asynchronously; renderer owns bounded decode/upload queues and GPU lifetime.
  • Separate CPU cache, GPU cache, transient staging, and consumer manifests with explicit budgets/eviction.
  • Track dependencies so one changed editor asset invalidates only affected decoded/GPU/material/scene data.
  • Use placeholder/failure presentation that is deterministic and never treats corrupt bytes as a partially valid resource.

Acceptance criteria

  • Tests cover missing/corrupt/oversized/wrong-type assets, revision races, provider cancellation, cache eviction, device recreation, hot reload, and duplicate requests.
  • Authenticated client cache data is verified before provider publication; editor-local data cannot enter connected-client trust scope.
  • Metrics expose hit/miss, bytes, uploads, evictions, revisions, and queue latency with bounded labels.
  • Whole-corpus resource manifests fit explicit CPU/GPU/disk budgets.
  • No parser for legacy map/content syntax enters renderer crates.

Dependencies and parallelization

Depends on #2/#5. Client resource download and editor project watching can develop separate providers concurrently.

Licensing

Rendering code, shaders, tests, and newly authored fixtures are MIT. Reuse from atrinik/classic sources is allowed only through the audited approved-grantor grant; all other behavior is independently implemented. Bundled assets require exact compatible licenses and notices.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Fields

    Priority

    None yet

    Effort

    None yet

    Projects

    Status
    Backlog

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions