Skip to main content

Crate codec

Crate codec 

Source
Expand description

Snapshot and delta encoding/decoding for the sdec codec.

This is the main codec crate that ties together bitstream, wire, and schema to provide full snapshot and delta encoding/decoding capabilities.

§Features

  • Full snapshot encoding/decoding
  • Delta encoding relative to a baseline
  • Baseline history management
  • Entity create/update/destroy operations
  • Per-component and per-field change masks

§Design Principles

  • Correctness first - All invariants are documented and tested.
  • No steady-state allocations - Uses caller-provided buffers.
  • Deterministic - Same inputs produce same outputs.

Structs§

EntityId
A stable entity identifier.
Limits
Limits for packet decoding.
SnapshotTick
A simulation tick number.

Enums§

CodecError
Errors that can occur during snapshot/delta encoding/decoding.

Type Aliases§

CodecResult
Result type for codec operations.